Bug 962667

Summary: processes still running after logout delay shutdown
Product: [openSUSE] openSUSE Distribution Reporter: Andreas Schleth <schleth_es>
Component: BasesystemAssignee: Forgotten User DV81ZEWZkN <forgotten_DV81ZEWZkN>
Status: RESOLVED WONTFIX QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: michael, systemd-maintainers
Version: Leap 42.1   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Andreas Schleth 2016-01-19 20:22:56 UTC
I experience several minutes delay when shutting down my computer.  The setup is:

* openSuSE Leap 42.1 with KDE / sddm on i7-6700 skylake 
* kernel from tumbleweed due to skylake graphics problems
* /home mounted via nfs

After logout there are still 4 processes active, that block unmounting /home.  Top shows this table for user as (after logout of as):

 1977 as   20   0   32120   4224   3396 S 0.000 0.013   0:00.01 systemd
 1978 as   20   0   64352   2904     88 S 0.000 0.009   0:00.00 (sd-pam)
 2181 as   20   0 2798508  60968  47360 S 0.000 0.188   0:01.06 kwin_x11
 2308 as   20   0  221700  21984  19976 S 0.000 0.068   0:00.01 kuiserver5

After killing these processes, shutdown takes a few seconds (as it should).  Thus the delay seems to be the waiting period for some timeout before unmounting /home.

To my untrained eye this seems to be related to systemd or possibly to sddm.  Bug 853619 seems to be similar, but I doubt this should be viewed as a KDE issue.

My laymen's view is: there should be no remaining processes whatsoever after a user logs out.
Comment 1 Michael Hamilton 2016-11-04 01:01:23 UTC
This is just speculation, but I wonder if there is something wrong with session termination in general - not just shutdown.   On Leap 42.2 RC1 and RC2, when I logout and login as someone else, I still see processes belonging to the previous login.  For example, I logged out the leap1 user and logged in as michael:

  michael@kosmos1:~ % ps axuw | grep '[l]eap1' 
  leap1 2154 0.0 0.0 36892 4616 ? Ss 11:04 0:00 /usr/lib/systemd/systemd --user
  leap1 2157 0.0 0.0 86636 2280 ? S 11:04 0:00 (sd-pam)
  leap1 2298 6.4 3.1 3118304 259932 ? Tl 11:04 0:09 plasmashell --shut-up
  leap1 2303 1.3 0.4 398128 37124 ? Tl 11:04 0:02 /usr/lib64/libexec/org_kde_powerdevil -session ...

If these processes are holding files open, maybe that could delay shutdown.
Comment 2 Tomáš Chvátal 2018-04-13 15:09:24 UTC
This is automated batch bugzilla cleanup.

The openSUSE 42.1 changed to end-of-life (EOL [1]) status. As such
it is no longer maintained, which means that it will not receive any
further security or bug fix updates.
As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
openSUSE, or you can still observe it under openSUSE Leap 15.0, please
feel free to reopen this bug against that version (see the "Version"
component in the bug fields), or alternatively open
a new ticket.

Thank you for reporting this bug and we are sorry it could not be fixed
during the lifetime of the release.

[1] https://en.opensuse.org/Lifetime