KDE Plasma 5.12.5 :Very long time (> 2 min) to logout

Hi,

I recently installed openSUSE Leap 15 (KDE Plasma: 5.12.5, Frameworks: 5.45, Qt version: 5.9.4, OS: 64 bit, Kernel: 4.12.14-lp150.12.7-default) on my desktop. It takes very long time (more than 2 minutes) to logout and get to the SDDM login screen. The startup time is good (~30 seconds). I have openSUSE 43.3 (KDE Plasma: 5.12.4, Frameworks: 5.45, Qt version: 5.10) installed in a laptop and I don’t experience such long logout times with my login screen as SDDM. Any help in troubleshooting this problem is very much appreciated. Thanks.

I’m not experiencing that problem here.

However, there are two options for login to Plasma. You can login with X11, or you can login with Wayland. You have not indicated which of those you are using.

I mostly use X11, because Plasma-wayland doesn’t seem quite ready for use. However, when I have tried Wayland, the logout time is noticeably longer.

Same story here.

You can login with X11, or you can login with Wayland. You have not indicated which of those you are using

I am using X11 and I used IceWM too, no difference. The login time with X11 and IceWM is fast (~25 s), it is the logout time that is too long. Here is my desktop specifications: Dell Optiplex 7060 with an i7-8700 4.6GHz, 16GB 2666MHz DDR4, M.2 256GB SSD, 1TB HD, Nvidia GeForce GTX 1050 2GB. The 256 SSD is for windows virtual environment. The linux system is in 1TD HDD. I have dual monitors and the graphics card is nouveau (I had trouble installing NVIDIA card and I gave up.).

Is there a way to figure out what is causing this long logout times ? Thanks.

Here’s an experiment for you to try.

While booting, hit ‘e’ on the grub menu. That should put you in an edit window.

Scroll down until you find a line beginning with “linux” (or it might be “linuxefi”)

Scroll to the right on that line. And append " plymouth.enable=0" to the end of the line.
Hit CTRL-X to resume booting.

This disable plymouth. So your boot up might see lots of on-screen message. Ignore those for now. The idea is to see the effect on shutdown. My experience is that, without plymouth, shutdown is faster.

It might not work out that way for you. But watch the screen during shutdown. Maybe you will notice something that is taking a lot of time.

Note if you use a database or other programs that may require cleanup or special shutdown routines it can take a bit to shut it down but you should see this in the shutdown screen minus plymouth

Observe the behaviour if you terminate the user session with

loginctl terminate-user <username>

Does that get you back to a login screen faster? (Note that will also kill all applications running in your desktop session.)

No, the login screen still takes a while to appear, however I think I may found the reason…

While booting, hit ‘e’ on the grub menu. That should put you in an edit window.

Scroll down until you find a line beginning with “linux” (or it might be “linuxefi”)

Scroll to the right on that line. And append " plymouth.enable=0" to the end of the line.
Hit CTRL-X to resume booting.

This disable plymouth. So your boot up might see lots of on-screen message. Ignore those for now. The idea is to see the effect on shutdown. My experience is that, without plymouth, shutdown is faster.

It might not work out that way for you. But watch the screen during shutdown. Maybe you will notice something that is taking a lot of time.

Thanks for the tip ! When I logout and see the on-screen messages, it takes a long time at [OK] started locale service. I looked in opensuse forums and I came across this thread
https://forums.opensuse.org/showthread.php/532640-after-update-leap-15-hangs-at-started-locale-service
The problem posted in the above thread is different from mine, the user has problems booting while being stuck in [OK] started locale service . Whereas for me, after I press logout, the on-screen message gets stuck at [OK] started locale service but eventually (after 2 min or so) I get the login screen again. I did update my desktop system 4 days back.

You might try displaying your syslog while you’re logging out… If it’s taking over 2 minutes, I doubt that running a window displaying your syslog events in real time would affect your logout much…

Recommend…
Before you logout, open a console and run the following command to read your syslog in real time

journalctl -f

While the window is open, try to logout.
Note what displays in the window, if there are long pauses and what comes immediately before and after any pauses.

Am speculating that there is something running on your machine that is preventing your system from logging out, if it can be identified then you might manually terminate it before logging out.

TSU

I did what you suggested. When I press logout, the window goes blank and stays blank for a while. I have uploaded a video (https://youtu.be/T2gH39fn--g) to show what is going on. Please have a look.

Can’t see what is on your screen and not sure what your video is supposed to be displaying.
I’m guessing that you clicked on the panel application launch > logout menu selection just before you video started.
At about 20 seconds you see some activity on the screen.
Then at about 40 seconds you see some additional activity leading to the actual KDE logout/shutdown/hibernate/suspend screen and then you can click on your chosen selection.
After that, I can’t tell if your machine is trying to shut down for the 2 plus minutes after that or something else.

That first stage at the 20 second and 40 second marks display possibly useful information.

Dong an Internet search for diagnosing shutdown issues,
The following article seems to have helped one User, maybe would be helpful for you, too.
https://freedesktop.org/wiki/Software/systemd/Debugging/#index2h1

And, you can always try looking at the last entries of any previous bootlog. The following displays the previous bootlog (you can specify any that might be saved automatically)

journalctl -b -1

The other approach I would take is to simply take inventory of every app you have installed…
There are some types of apps a system can’t know for sure has stopped completely so a general timeout “wait” is implemented to simply guess that all transactions and other critical operations have completed before actually executing the shutdown. Candidates for this type of application include remote share mounts and database applications, some which can be embedded within common apps… eg Amarok which will install mysql or sqlite. If you have apps like these, manually end and if necessary kill the running service process before shutting down. if you have file shares mounted, unmount manually to see if there is a difference. My advice is to simply avoid these kinds of apps if you can, uninstall and replace with an app which runs differently.

HTH,
TSU

Ok logging out only not a shutdown right???

Logout shuts down and restarts the video driver. so what Video??

Thanks for the suggestions. I will look into it.

Yes, only logging out. The video i posted shows the time it took from pressing the logout icon to the appearance of the login screen.

Here is the output


user:/home/user # lspci -vnn | grep VGA -A 12
00:02.0 VGA compatible controller [0300]: Intel Corporation Device [8086:3e92] (prog-if 00 [VGA controller])
        Subsystem: Dell Device [1028:085a]                                                                                                                                                                        
        Flags: bus master, fast devsel, latency 0, IRQ 127                                                                                                                                                        
        Memory at a4000000 (64-bit, non-prefetchable) [size=16]                                                                                                                                                  
        Memory at 80000000 (64-bit, prefetchable) [size=256]                                                                                                                                                     
        I/O ports at 4000 [size=64]                                                                                                                                                                               
        [virtual] Expansion ROM at 000c0000 [disabled] [size=128]                                                                                                                                                
        Capabilities: [40] Vendor Specific Information: Len=0c <?>                                                                                                                                                
        Capabilities: [70] Express Root Complex Integrated Endpoint, MSI 00                                                                                                                                       
        Capabilities: [ac] MSI: Enable+ Count=1/1 Maskable- 64bit-                                                                                                                                                
        Capabilities: [d0] Power Management version 2
        Capabilities: [100] Process Address Space ID (PASID)
        Capabilities: [200] Address Translation Service (ATS)
--
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GP107 [GeForce GTX 1050] [10de:1c81] (rev a1) (prog-if 00 [VGA controller])
        Subsystem: Dell Device [1028:11c0]
        Flags: bus master, fast devsel, latency 0, IRQ 125
        Memory at a2000000 (32-bit, non-prefetchable) [size=16]
        Memory at 90000000 (64-bit, prefetchable) [size=256]
        Memory at a0000000 (64-bit, prefetchable) [size=32]
        I/O ports at 3000 [size=128]
        Expansion ROM at a3000000 [disabled] [size=512]
        Capabilities: [60] Power Management version 3
        Capabilities: [68] MSI: Enable+ Count=1/1 Maskable- 64bit+
        Capabilities: [78] Express Legacy Endpoint, MSI 00
        Capabilities: [100] Virtual Channel
        Capabilities: [250] Latency Tolerance Reporting



user:/home/user # xrandr -q
Screen 0: minimum 320 x 200, current 3840 x 1080, maximum 8192 x 8192
DP-2 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 527mm x 296mm
   1920x1080     60.00*+
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1152x864      75.00  
   1024x768      75.03    60.00  
   800x600       75.00    60.32  
   640x480       75.00    59.94  
   720x400       70.08  
HDMI-2 disconnected (normal left inverted right x axis y axis)
DP-3 connected 1920x1080+1920+0 (normal left inverted right x axis y axis) 527mm x 296mm
   1920x1080     60.00*+
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1152x864      75.00  
   1024x768      75.03    60.00  
   800x600       75.00    60.32  
   640x480       75.00    59.94  
   720x400       70.08  
HDMI-3 disconnected (normal left inverted right x axis y axis)
DP-4 disconnected (normal left inverted right x axis y axis)
HDMI-4 disconnected (normal left inverted right x axis y axis)
DVI-D-1-1 disconnected (normal left inverted right x axis y axis)
HDMI-1-1 disconnected (normal left inverted right x axis y axis)
DP-1-1 disconnected (normal left inverted right x axis y axis)


user:/home/user # lspci -v -s 00:02.0
00:02.0 VGA compatible controller: Intel Corporation Device 3e92 (prog-if 00 [VGA controller])
        Subsystem: Dell Device 085a
        Flags: bus master, fast devsel, latency 0, IRQ 127
        Memory at a4000000 (64-bit, non-prefetchable) [size=16]
        Memory at 80000000 (64-bit, prefetchable) [size=256]
        I/O ports at 4000 [size=64]
        [virtual] Expansion ROM at 000c0000 [disabled] [size=128]
        Capabilities: [40] Vendor Specific Information: Len=0c <?>
        Capabilities: [70] Express Root Complex Integrated Endpoint, MSI 00
        Capabilities: [ac] MSI: Enable+ Count=1/1 Maskable- 64bit-
        Capabilities: [d0] Power Management version 2
        Capabilities: [100] Process Address Space ID (PASID)
        Capabilities: [200] Address Translation Service (ATS)
        Capabilities: [300] Page Request Interface (PRI)
        Kernel driver in use: i915
        Kernel modules: i915

user:/home/user # lspci -v -s 01:00.0   
01:00.0 VGA compatible controller: NVIDIA Corporation GP107 [GeForce GTX 1050] (rev a1) (prog-if 00 [VGA controller])
        Subsystem: Dell Device 11c0
        Flags: bus master, fast devsel, latency 0, IRQ 125
        Memory at a2000000 (32-bit, non-prefetchable) [size=16]
        Memory at 90000000 (64-bit, prefetchable) [size=256]
        Memory at a0000000 (64-bit, prefetchable) [size=32]
        I/O ports at 3000 [size=128]
        Expansion ROM at a3000000 [disabled] [size=512]
        Capabilities: [60] Power Management version 3
        Capabilities: [68] MSI: Enable+ Count=1/1 Maskable- 64bit+
        Capabilities: [78] Express Legacy Endpoint, MSI 00
        Capabilities: [100] Virtual Channel                                                                                                                                                                       
        Capabilities: [250] Latency Tolerance Reporting                                                                                                                                                           
        Capabilities: [128] Power Budgeting <?>                                                                                                                                                                   
        Capabilities: [420] Advanced Error Reporting                                                                                                                                                              
        Capabilities: [600] Vendor Specific Information: ID=0001 Rev=1 Len=024 <?>                                                                                                                                
        Capabilities: [900] #19                                                                                                                                                                                   
        Kernel driver in use: nouveau                                                                                                                                                                             
        Kernel modules: nouveau   

Both monitors are connected to the motherboard (Intel graphics). I tried installing the NVIDIA drivers (the easy way) but it gave a blank screen, so I went with nouveau.[/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size][/size]

Chose one GPU and disable the other one (assuming this is not a laptop) Mixing drivers is probably the problem. If me I’d disable the on-board Intel and use the superior NVIDIA

When got the desktop, I tried to install NVIDIA (easy way). I connected my monitors to NVIDIA and I disabled the on-board Intel, all I got was a blank screen. That is why my monitors are running on Intel. But I guess the “blank screen” problem is for another thread. I will try your suggestion again and I will look at other NVIDIA threads if something goes wrong. Thanks for your help, really appreciate it.:slight_smile: