Unable to shutdown or restart from log-in screen

Bug #1847896 reported by Paul White
174
This bug affects 25 people
Affects Status Importance Assigned to Milestone
systemd (Ubuntu)
Fix Released
High
Unassigned
Eoan
Fix Released
High
Balint Reczey
Focal
Fix Released
High
Unassigned

Bug Description

[Impact]

 * 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)

Revision history for this message
Paul White (paulw2u) wrote :
Revision history for this message
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:
http://iso.qa.ubuntu.com/qatracker/reports/bugs/1847896

tags: added: iso-testing
Revision history for this message
Paul White (paulw2u) wrote :

Marking confirmed as user on forums also seeing issue:
https://ubuntuforums.org/showthread.php?t=2429058

Changed in gnome-shell (Ubuntu):
status: New → Confirmed
Will Cooke (willcooke)
tags: added: rls-ee-incoming
Revision history for this message
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
Revision history for this message
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:

https://github.com/systemd/systemd/commit/a2dcb1d78737d3daa301ee63fbdd02837acb71a8

I suspect the problem would be fixed.

Revision history for this message
Iain Lane (laney) wrote :

s/D-Bus session/logind session/

Revision history for this message
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
Revision history for this message
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)
Changed in systemd (Ubuntu):
status: Triaged → In Progress
Revision history for this message
Balint Reczey (rbalint) wrote :

I've pushed the fix to schedule it for the next upload:
https://code.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/+git/systemd/+ref/ubuntu-eoan

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

Balint Reczey (rbalint)
description: updated
Revision history for this message
Balint Reczey (rbalint) wrote :

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

Changed in systemd (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
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
Revision history for this message
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.

Revision history for this message
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)
Mathew Hodson (mhodson)
no longer affects: gnome-shell (Ubuntu)
Changed in systemd (Ubuntu Eoan):
importance: Undecided → High
Balint Reczey (rbalint)
Changed in systemd (Ubuntu Eoan):
status: Confirmed → Fix Committed
status: Fix Committed → In Progress
assignee: nobody → Balint Reczey (rbalint)
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

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
Revision history for this message
Efthimios Chaskaris (echaskaris) wrote :

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

Revision history for this message
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.

Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (systemd/242-7ubuntu3.2)

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].

https://people.canonical.com/~ubuntu-archive/proposed-migration/eoan/update_excuses.html#systemd

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

Thank you!

Revision history for this message
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.

Revision history for this message
Miroslav Zaťko (mirec-z) wrote :

still there with ubuntu 19.10 everything & freshly upgraded

Revision history for this message
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
Revision history for this message
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
Revision history for this message
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.

Revision history for this message
Md Ayquassar (mdayquassar) wrote :

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

Revision history for this message
Md Ayquassar (mdayquassar) wrote :

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

Revision history for this message
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
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=b407dfd8c9dc81594553c27467c35b383333d74c
  * debian/gbp.conf: Set debian-branch to ubuntu-eoan
    File: debian/gbp.conf
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=f399ce2cf4701a2dbb4b3505d2dd17a210d62f5c

  [ Dan Streetman ]
  * Fix bogus routes after DHCP lease change (LP: #1831787)
    Files:
    - 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
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=ced3f5c2f619083f7beb164d94d4ccfe52222fe8
  * Set src address for dhcp 'classless' routes (LP: #1835581)
    File: debian/patches/lp1835581-src-network-networkd-dhcp4.c-set-prefsrc-for-classle.patch
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=6a7ef370fb1335548448920be4ae6176b67044a8
  * 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
    https://git.launchpad.net/~ubuntu-core-dev/ubuntu/+source/systemd/commit/?id=27def26f5b1d1b8ba314c4a925fc1b7c43837f86

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

Changed in systemd (Ubuntu Eoan):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update 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  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.