Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/index.php/Reporting_Bug_Guidelines

Do NOT report bugs when a package is just outdated, or it is in Unsupported. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#47734 - [systemd] Shutdown or reboot from DE lead to the "A stop job is running for Login Service" message

Attached to Project: Arch Linux
Opened by viktor (dviktor) - Wednesday, 13 January 2016, 06:34 GMT
Last edited by Dave Reisner (falconindy) - Saturday, 18 June 2016, 13:08 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Thomas Bächler (brain0)
Architecture x86_64
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 19
Private No

Details

Description: when trying to reboot or power down laptop from DE (XFCE) shutdown process loops with the next message on the screen: "A stop job is running for Login Service" followed by some timer information. Only forced-poweroff via pressing power button helps but after that filesystems are marked unclean and fsck recovery process on next boot will appear. If first to simply log out from DE, switch to the tty2 (or another where no X started after login) and then manually `shutdown` or `reboot` then all works fine.

The problem appeared after installing so long-waited update kernel 4.3.3-2 from `core`.


Additional info:
* package version(s)
Kernel 4.3.3-2, XFCE 4.12, Xorg 1.18.0-4, xf86-video-ati 1:7.6.1-1, xf86-video-intel 1:2.99.917+519+g8229390-1
* config and/or log files etc.
journalctl entries after forced-shutdown are here (http://pastebin.com/DtCxPtY7)

[viktor ~]$ lspci | grep VGA
00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Robson CE [Radeon HD 6370M/7370M] (rev ff)

Steps to reproduce:
1) Boot up your PC/laptop/whatever
2) log in to your xfce session
3) try to shutdown or reboot your computer. You'll receive so annoying "A stop job is running..." message however clean shutdown/reboot should occur.
This task depends upon

Closed by  Dave Reisner (falconindy)
Saturday, 18 June 2016, 13:08 GMT
Reason for closing:  Upstream
Additional comments about closing:  This is probably roughly WAI, but as comments show, mileage varies with DM. The right thing to do is to ensure user processes are killed on logout.
Comment by Cornelius (dude42) - Wednesday, 13 January 2016, 23:40 GMT
I can confirm the same when using gnome without gdm (simply logging into a terminal and then typing startx).

My graphics card configuration is as follows:

00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06)
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Mars XTX [Radeon HD 8790M] (rev ff)
Comment by 甘露(Lu Gan) (ganlu) - Thursday, 14 January 2016, 13:17 GMT
I have similar hardware configuration and run into the same problem with gnome 3.18 and gdm, but system can shut down correctly from gnome menu if I run gnome with wayland.
00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor Graphics Controller (rev 09)
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Thames [Radeon HD 7500M/7600M Series] (rev ff)
Comment by jb (jb.1234abcd) - Thursday, 14 January 2016, 18:58 GMT
I have perhaps related problem with unclean reboot/shutdown from DE menu:
https://bugs.freedesktop.org/show_bug.cgi?id=93592
...
Fatal server error:
[214298.186] (EE) systemd-logind disappeared (stopped/restarted?)
...
Comment by Ricardo Funke Ormieres (ricardofunke) - Friday, 15 January 2016, 14:07 GMT
Same problem, using GDM and Gnome-shell, no problem if wayland

00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor Graphics Controller (rev 09)
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Thames [Radeon HD 7500M/7600M Series] (rev ff)

Perhaps it's related to the graphics driver and the compositing, something that is preventing gdm or session from stop, although the shutdown process seems to stop in the unmount step.
Comment by Ander (anderraso) - Saturday, 16 January 2016, 02:33 GMT
I can confirm the same bug with i3 without a login manager (started with startx).

00:01.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] BeaverCreek [Radeon HD 6620G]
02:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Whistler [Radeon HD 6630M/6650M/6750M/7670M/7690M]
Comment by Santiago Narvaez (cronos) - Sunday, 17 January 2016, 16:46 GMT
I can confirm the sabe bug, I am using GDM and Gnome-shell.

00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor Graphics Controller (rev 09)
02:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Thames [Radeon HD 7550M/7570M/7650M] (rev ff)
Comment by V.I.S. (BytEvil) - Wednesday, 20 January 2016, 10:24 GMT
I can confirm the same bug. I`m using multiseat system, gnome shell and kdm. This bug persist since systemd ver.226 and kernel 4.1+

01:00.0 VGA compatible controller: NVIDIA Corporation GK107 [GeForce GT 640] (rev a1)
05:00.0 VGA compatible controller: NVIDIA Corporation GK107 [GeForce GT 640] (rev a1)
06:00.0 VGA compatible controller: NVIDIA Corporation GK107 [GeForce GT 640] (rev a1)
Comment by Alexandre Garnier (agarnier) - Friday, 22 January 2016, 10:29 GMT
Same problem here, with GDM and Gnome-Shell.

For what it’s worth:
00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06)
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Mars XTX [Radeon HD 8790M] (rev ff)
Comment by Debadatta Bose (DebadattaBose) - Saturday, 30 January 2016, 05:43 GMT
Same problem persisting with Kernel 4.3.3-3-ARCH. VGA configuration as follows:

00:02.0 VGA compatible controller: Intel Corporation Haswell-ULT Integrated Graphics Controller (rev 09)
03:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Venus PRO [Radeon HD 8850M / R9 M265X] (rev ff)
Comment by viktor (dviktor) - Tuesday, 02 February 2016, 08:47 GMT
There is no problem with 4.1.16-1-lts kernel. So, will wait for 4.4...
Comment by V.I.S. (BytEvil) - Tuesday, 02 February 2016, 08:56 GMT
Kernel 4.3.3-3-ARCH #1 SMP PREEMPT Wed Jan 20 08:12:23 CET 2016 x86_64 GNU/Linux, same problem with "A stop job is running for Login..." & "A stop job is running for User Manager..."
Comment by viktor (dviktor) - Tuesday, 02 February 2016, 08:58 GMT
try to fallback to the LTS kernel. Seems like mainline issue
Comment by V.I.S. (BytEvil) - Tuesday, 02 February 2016, 09:22 GMT
@Viktor, no reboot/shutdown problem with LTS kernel?
Comment by Alexandre Garnier (agarnier) - Tuesday, 02 February 2016, 10:03 GMT
I confirm the problem disappears with LTS kernel.
Comment by viktor (dviktor) - Tuesday, 02 February 2016, 10:52 GMT
Yes, there is no shutdown/reboot issue when using LTS kernel
Comment by V.I.S. (BytEvil) - Tuesday, 02 February 2016, 10:56 GMT
Yes, there is no shutdown/reboot issue with 4.1.16-1-lts. Thanks, friends! :)
Comment by Debadatta Bose (DebadattaBose) - Tuesday, 02 February 2016, 11:21 GMT
As an alternative to downgrading to 4.1.16, you can try simply logging out first, and then shutdown/restart. Always works for me!
Comment by viktor (dviktor) - Tuesday, 02 February 2016, 12:12 GMT
Yes, this works too, but it's a bit annoying.
Comment by V.I.S. (BytEvil) - Wednesday, 03 February 2016, 08:14 GMT
Sorry, freinds! Problem not solved with kernel 4.1.16-1-lts. After 4-5 reboots same problem with "A stop job is running for User Manager..." :(
http://i74.fastpic.ru/big/2016/0203/3a/f1f16cebec8d4190ea27270bdf86db3a.jpg
Comment by viktor (dviktor) - Wednesday, 03 February 2016, 09:15 GMT
@V.I.S., look at this: https://bbs.archlinux.org/viewtopic.php?id=203112
Seems like you're experiencing another kind of problem but similar to the current

Also try to decrease stop limit timer in /etc/systemd/system.conf
DefaultTimeoutStopSec=15s
Comment by viktor (dviktor) - Wednesday, 03 February 2016, 10:13 GMT
Kernel 4.4.1-1 also solves problem
Comment by Yaroslav Zenin (kiotoze) - Wednesday, 03 February 2016, 16:08 GMT
> Kernel 4.4.1-1 also solves problem
for me not
please anyone else check on Kernel 4.4.1-1
Comment by Ricardo Funke Ormieres (ricardofunke) - Wednesday, 03 February 2016, 18:19 GMT
Kernel 4.4.1-1 here but the problem persists

Comment by V.I.S. (BytEvil) - Wednesday, 03 February 2016, 20:43 GMT
4.4.1-2-ARCH #1 SMP PREEMPT Wed Feb 3 13:12:33 UTC 2016 x86_64 GNU/Linux - problem persists.
Comment by Ricardo Funke Ormieres (ricardofunke) - Wednesday, 03 February 2016, 21:44 GMT
Here's the messages when trying to shutdown:

http://postimg.org/image/myyfvqxn3/
Comment by viktor (dviktor) - Wednesday, 03 February 2016, 22:25 GMT
Very strange, I've tried several times and all seems good.
Comment by Rorschach (Rorschach) - Sunday, 07 February 2016, 11:48 GMT Comment by Alexandre Garnier (agarnier) - Wednesday, 10 February 2016, 15:36 GMT
Problem disappeared with 4.4.1-1, and went back with 4.4.1-2…
Considering that, it clearly seems to be packaging-related, as the first 4.4.1 version packaged worked, and the sources haven’t changed since.

No problem with LTS 4.1.17-1 though.
Comment by Rorschach (Rorschach) - Thursday, 11 February 2016, 12:17 GMT
I went back to 4.4.1-1-ARCH but the problem is still here. Maybe here are different problems occuring. Some people say the problem disappears with a different kernel, other say it doesnt.
Comment by Marcelo Garlet Millani (mgmillani) - Sunday, 14 February 2016, 12:22 GMT
I am using kernel 4.4.1-2, and without a login manager the problem persists. Installing lightdm solved the issue for me.
Comment by Mike Cloaked (mcloaked) - Friday, 19 February 2016, 16:11 GMT
I seem to have a similar issue - running plasma desktop and after recent updates to systemd I am also now getting a 90 second delay on shutdown/reboot on several machines. The console gives a message "A stop job is running for Session c2 for user...." In the journal I see:

Feb 18 20:13:24 home1 systemd[1]: Stopped target Network.
Feb 18 20:14:53 home1 systemd[589]: dbus.service: State 'stop-final-sigterm' timed out. Killing.
Feb 18 20:14:53 home1 systemd[1]: user@1000.service: State 'stop-sigterm' timed out. Killing.
Feb 18 20:14:53 home1 systemd[1]: Stopped User Manager for UID 1000.
Feb 18 20:14:53 home1 systemd[1]: user@1000.service: Unit entered failed state.
Feb 18 20:14:53 home1 systemd[1]: user@1000.service: Failed with result 'timeout'.
Feb 18 20:14:53 home1 systemd[1]: Removed slice User Slice of mike.
Feb 18 20:14:53 home1 systemd[1]: Stopping Login Service...
Feb 18 20:14:53 home1 systemd[1]: Stopping Permit User Sessions...
Feb 18 20:14:53 home1 systemd[1]: Stopped Permit User Sessions.
Feb 18 20:14:53 home1 systemd[1]: Stopped target Remote File Systems.
Feb 18 20:14:53 home1 systemd[1]: Stopped Login Service.
Feb 18 20:14:53 home1 systemd[1]: Stopped target Basic System.

and again from today:

Feb 19 15:45:36 home1 systemd[1]: Stopped Simple Desktop Display Manager.
Feb 19 15:47:01 home1 systemd[599]: dbus.service: State 'stop-final-sigterm' timed out. Killing.
Feb 19 15:47:01 home1 systemd[1]: user@1000.service: State 'stop-sigterm' timed out. Killing.
Feb 19 15:47:01 home1 systemd[1]: Stopped User Manager for UID 1000.
Feb 19 15:47:01 home1 systemd[1]: user@1000.service: Unit entered failed state.
Feb 19 15:47:01 home1 systemd[1]: user@1000.service: Failed with result 'timeout'.
Feb 19 15:47:01 home1 systemd[1]: Removed slice User Slice of mike.
Feb 19 15:47:01 home1 systemd[1]: Stopping Login Service...
Feb 19 15:47:01 home1 systemd[1]: Stopping Permit User Sessions...
Feb 19 15:47:01 home1 systemd[1]: Stopped Permit User Sessions.

Once the shutdown stop job delay has ended the shutdown then completes rapidly.

which seems to be a dbus related shutdown delay with the 90 seconds wait period seen in the timestamps above. I also installed systemd 229-3 from testing but this does not help the issue.

Possibly these reports are related:
https://github.com/systemd/systemd/issues/1615
https://lists.freedesktop.org/archives/systemd-devel/2016-January/035619.html

Can anyone else quote journal log lines showing what the systemd unit that forcibly closed after the delay on shutdown? In my case it is dbus.service and user@1000.service.

In my case if I log out of the plasma desktop, then click the reboot icon at the top right of the sddm greeter screen, then the reboot/shutdown delay does not occur. The 90 second stop job delay only occurs if I reboot by right clicking the plasma desktop and selecting "Leave" and choosing to shutdown or reboot.
Comment by V.I.S. (BytEvil) - Saturday, 20 February 2016, 05:22 GMT
Kernel 4.4.1-2, systemd 229-2 but the problem persists.
Comment by Mike Cloaked (mcloaked) - Saturday, 20 February 2016, 09:29 GMT
Also related is the upstream report at https://bugs.freedesktop.org/show_bug.cgi?id=70593
Comment by meda (meda) - Saturday, 20 February 2016, 12:33 GMT
I have same problem also with 4.4.1 and 4.1 LTS
Comment by V.I.S. (BytEvil) - Saturday, 20 February 2016, 19:10 GMT
Systemd 229-2 writes lots of GiB dump files from segfault application during reboot/shutdown. With systemd 228 no such this problem.
Comment by Vizitor (Vizitor) - Wednesday, 24 February 2016, 08:35 GMT
Kernel 4.4.1-2, systemd 229-3 problem persist.
(I'm using startx+Fluxbox+nVidia on two computers)
Reverted to systemd 228-4 for now.
Comment by Yaroslav Zenin (kiotoze) - Wednesday, 24 February 2016, 13:26 GMT
I switch from gdm to lightdm and problem gone. Now it works fine with 4.4.1-2-ARCH.
With gdm I had success only with linux-lts 4.1.18-1
also I do not found any dependency on systemd version
Comment by Dave Reisner (falconindy) - Saturday, 18 June 2016, 13:07 GMT
This is likely fixed if you set KillUserProcesses=yes in /etc/systemd/logind.conf (which is why upstream changed the default in v230, though Arch did not follow this).

Loading...