Unable to shutdown or restart from log-in screen

Bug #1847896 reported by Paul White on 2019-10-13
This bug affects 24 people
Affects Status Importance Assigned to Milestone
systemd (Ubuntu)
Status tracked in Focal
Balint Reczey

Bug Description


 * Shutdown and restart options don't work from the login screen, when the user is not logged in.

[Test Case]

 * Start the system and don't log in, or log out in case the system is set up with autologin.
 * Restart, then shut down the system using the option in the upper right corner of the login screen.
 * Observe both operations working.

[Regression Potential]

 * The fix is treating treating the greeter as user display sessions by cherry-picking upstream's change released in v243. The fix itself is very small, but there may be non-obvious security implications.

[Original Bug Text]

When selecting the shutdown icon from the log-in screen you are prompted with a dialog that allows you to either cancel, restart or shutdown.

It has been noted that the restart and shutdown options no longer work.

ProblemType: Bug
DistroRelease: Ubuntu 19.10
Package: gnome-shell 3.34.1-1ubuntu1
ProcVersionSignature: Ubuntu 5.3.0-18.19-generic 5.3.1
Uname: Linux 5.3.0-18-generic x86_64
ApportVersion: 2.20.11-0ubuntu8
Architecture: amd64
CurrentDesktop: GNOME
Date: Sun Oct 13 09:08:23 2019
DisplayManager: gdm3
InstallationDate: Installed on 2019-05-17 (148 days ago)
InstallationMedia: Ubuntu 19.10 "Eoan Ermine" - Alpha amd64 (20190517)
RelatedPackageVersions: mutter-common 3.34.1-1ubuntu1
SourcePackage: gnome-shell
UpgradeStatus: No upgrade log present (probably fresh install)

Paul White (paulw2u) wrote :
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:

tags: added: iso-testing
Paul White (paulw2u) wrote :

Marking confirmed as user on forums also seeing issue:

Changed in gnome-shell (Ubuntu):
status: New → Confirmed
Will Cooke (willcooke) on 2019-10-14
tags: added: rls-ee-incoming
Will Cooke (willcooke) wrote :

Oct 14 15:46:09 ubuntu gnome-shell[925]: endSessionDialog: No XDG_SESSION_ID, fetched from logind: c1
Oct 14 15:46:10 ubuntu gnome-session[916]: gnome-session-binary[916]: WARNING: Shutdown failed: GDBus.Error:org.freedesktop.DBus.Error.InteractiveAuthorizationRequired: Interactive authentication required.
Oct 14 15:46:10 ubuntu gnome-session-binary[916]: WARNING: Shutdown failed: GDBus.Error:org.freedesktop.DBus.Error.InteractiveAuthorizationRequired: Interactive authentication required.
Oct 14 15:46:10 ubuntu gnome-session-binary[916]: Entering running state
Oct 14 15:46:10 ubuntu gnome-shell[925]: Ignored exception from dbus method: Gio.IOErrorEnum: GDBus.Error:org.gtk.GDBus.UnmappedGError.Quark._g_2dio_2derror_2dquark.Code19: Operation was cancelled

Changed in gnome-shell (Ubuntu):
importance: Undecided → High
Iain Lane (laney) wrote :

I haven't tested this, but since seb128 pasted the relevant messages in IRC.

I bet you that it's because polkit isn't considering the D-Bus session of the greeter to be 'active', because it's not finding it.

If someone would like to test build a systemd with this commit included:


I suspect the problem would be fixed.

Iain Lane (laney) wrote :

s/D-Bus session/logind session/

Iain Lane (laney) wrote :

yeah ok just checked, that totally fixes it, have asked the systemd maintainer if that patch can be included in the next update

Changed in gnome-shell (Ubuntu):
status: Confirmed → Invalid
Changed in systemd (Ubuntu):
status: New → Triaged
importance: Undecided → High
Sebastien Bacher (seb128) wrote :

I've tested it as well (saw you asking yesterday and kicked a build but I didn't see you tested as well meanwhile), I can confirm it fixes the issue

tags: added: id-5da4c44b2f3bee7a637eb2b0
tags: added: fixed-in-243 fixed-upstream
Balint Reczey (rbalint) on 2019-10-17
Changed in systemd (Ubuntu):
status: Triaged → In Progress
Balint Reczey (rbalint) wrote :

I've pushed the fix to schedule it for the next upload:

I'm waiting a few days to see if there are other fixes showing up to include in the same upload.

Balint Reczey (rbalint) on 2019-10-18
description: updated
Balint Reczey (rbalint) wrote :

Fixed in Focal, to be SRU-d to Eoan.

Changed in systemd (Ubuntu):
status: In Progress → Fix Released
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gnome-shell (Ubuntu Eoan):
status: New → Confirmed
Changed in systemd (Ubuntu Eoan):
status: New → Confirmed
Scott Dennis (sdennis91) wrote :

i got an email about released. I also notice on here that a fix has been released. I don't see it as an update via software updates. How to I get the fix.

Paul White (paulw2u) wrote :

Comment #10 means fixed in focal (20.04) only for now.
Stable Release Update in eoan (19.10) to follow in due course.

no longer affects: gnome-shell (Ubuntu Eoan)
no longer affects: gnome-shell (Ubuntu Focal)
no longer affects: gnome-shell (Ubuntu)
Changed in systemd (Ubuntu Eoan):
importance: Undecided → High
Balint Reczey (rbalint) on 2019-10-31
Changed in systemd (Ubuntu Eoan):
status: Confirmed → Fix Committed
status: Fix Committed → In Progress
assignee: nobody → Balint Reczey (rbalint)

Hello Paul, or anyone else affected,

Accepted systemd into eoan-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/systemd/242-7ubuntu3.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-eoan to verification-done-eoan. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-eoan. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in systemd (Ubuntu Eoan):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-eoan
tags: added: verification-done verification-done-eoan
removed: verification-needed verification-needed-eoan

The feature works now. You might want to release it earlier than 7 days.

Paul White (paulw2u) wrote :

Looks like I was a little slow in testing and changing the tags but for the record:

Rebooted into Ubuntu 19.10 to confirm Restart and Poweroff options were not working
Logged in, enabled -proposed, updated systemd to version 242-7ubuntu3.2
Logged out and confirmed 'Poweroff' now works
Started PC and without logging in confirmed 'Restart' now works

Thanks for the fix.

All autopkgtests for the newly accepted systemd (242-7ubuntu3.2) for eoan have finished running.
The following regressions have been reported in tests triggered by the package:

gvfs/1.42.1-1ubuntu1 (amd64)
systemd/242-7ubuntu3.2 (ppc64el)
ndctl/unknown (armhf)
casper/1.427 (amd64)
netplan.io/0.98-0ubuntu1 (ppc64el)
munin/unknown (armhf)
linux-oem-osp1/5.0.0-1026.29 (amd64)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].


[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

Scott Dennis (sdennis91) wrote :

Thanks for the fix. I tested it on my end and I confirmed this bug as being fixed. I can now restart and shutdown via gdm.

Miroslav Zaťko (mirec-z) wrote :

still there with ubuntu 19.10 everything & freshly upgraded

Md Ayquassar (mdayquassar) wrote :

Same for me as of this today: logging off, then navigating through the menu in the right upper screen corner till the turn-off button and then clicking it produces no effect in eoan.

Changed in systemd (Ubuntu Eoan):
status: Fix Committed → In Progress
Paul White (paulw2u) wrote :

The fix has not yet been released but is in a period of testing. Did you follow the instructions in comment #15? The updated package is in -proposed and will be for a *minimum* of seven days from the date of comment #15.

If you want to test whether the update works for you then please follow the instructions in comment #15. If that update doesn't work for you then please confirm that you have enabled -proposed and downloaded the updated package.

Changed in systemd (Ubuntu Eoan):
status: In Progress → Fix Committed
Md Ayquassar (mdayquassar) wrote :

@paulw2u My apologies. After double-checking, I found out that (for whatever reason) eoan-proposed were disabled for me. I'll retest and report here if an update doesn't help.

Md Ayquassar (mdayquassar) wrote :

After a few tests, I confirm that the bug looked fixed to me.

Md Ayquassar (mdayquassar) wrote :

After a few tests, I confirm that the bug looks fixed to me.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package systemd - 242-7ubuntu3.2

systemd (242-7ubuntu3.2) eoan; urgency=medium

  [ Dan Streetman ]
  * d/extra/dhclient-enter-resolved-hook:
    - Replace use of bash-only &> with > and 2> (LP: #1849608)
  * d/p/lp1849658-resolved-set-stream-type-during-DnsStream-creation.patch:
    - Fix bug in refcounting TCP stream types (LP: #1849658)
  * d/extra/dhclient-enter-resolved-hook: cleanup temp $newstate file

  [ Rafael David Tinoco ]
  * Add support to KeepConfiguration= fixing behaviour for HA (LP: #1815101)
    - d/p/lp1815101-01-networkd-add-support-to-keep-configuration.patch
    - d/p/lp1815101-02-networkd-stop-clients-when-networkd-shuts-down.patch
    - d/p/lp1815101-03-network-add-KeepConfiguration-dhcp-on-stop.patch
    - d/p/lp1815101-04-network-make-KeepConfiguration-static-drop-DHCP-addr.patch
    - d/p/lp1815101-05-man-add-documentation-about-KeepConfiguration.patch

systemd (242-7ubuntu3.1) eoan; urgency=medium

  [ Balint Reczey ]
  * Fix shutdown and related actions from the login screen (LP: #1847896)
    File: debian/patches/logind-consider-greeter-sessions-suitable-as-display-sess.patch
  * debian/gbp.conf: Set debian-branch to ubuntu-eoan
    File: debian/gbp.conf

  [ Dan Streetman ]
  * Fix bogus routes after DHCP lease change (LP: #1831787)
    - debian/patches/lp1831787/0001-networkd-Add-back-static-routes-after-DHCPv4-lease-e.patch
    - debian/patches/lp1831787/0002-network-set-preferred-source-in-removing-route-entry.patch
    - debian/patches/lp1831787/0003-network-lower-log-level-about-critical-connection.patch
    - debian/patches/lp1831787/0004-network-reset-Link-dhcp4_configured-flag-earlier.patch
    - debian/patches/lp1831787/0005-network-split-dhcp_lease_lost-into-small-pieces.patch
  * Set src address for dhcp 'classless' routes (LP: #1835581)
    File: debian/patches/lp1835581-src-network-networkd-dhcp4.c-set-prefsrc-for-classle.patch
  * Allows cache=no-negative option to be set, ignoring negative answers to
    be cached (LP: #1668771)
    File: debian/patches/lp1668771-resolved-switch-cache-option-to-a-tri-state-option-s.patch

 -- Dan Streetman <email address hidden> Fri, 01 Nov 2019 16:33:08 -0400

Changed in systemd (Ubuntu Eoan):
status: Fix Committed → Fix Released

The verification of the Stable Release Update for systemd has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Related questions