sts-sponsors team mailing list archive
-
sts-sponsors team
-
Mailing list archive
-
Message #02670
[Bug 1911187] Re: scheduled reboot reboots immediately if dbus or logind is not available
Hello Ioanna, or anyone else affected,
Accepted systemd into groovy-proposed. The package will build now and be
available at
https://launchpad.net/ubuntu/+source/systemd/246.6-1ubuntu1.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, what testing has been
performed on the package and change the tag from verification-needed-
groovy to verification-done-groovy. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-groovy. 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 Groovy)
Status: In Progress => Fix Committed
** Tags added: verification-needed verification-needed-groovy
--
You received this bug notification because you are a member of STS
Sponsors, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1911187
Title:
scheduled reboot reboots immediately if dbus or logind is not
available
Status in systemd package in Ubuntu:
Fix Released
Status in systemd source package in Bionic:
In Progress
Status in systemd source package in Focal:
Fix Committed
Status in systemd source package in Groovy:
Fix Committed
Bug description:
[IMPACT]
When, for whatever reason, logind or dbus is not available scheduled reboot reboots the machine immediately.
From the sources it seems that this is intended :
https://github.com/systemd/systemd/blob/master/src/systemctl/systemctl-logind.c#L318
However, I report this as a bug since this is against the logic of a scheduled reboot; if someone schedules a reboot they want the system to reboot at the specified time not immediately.
There has been a discussion upstream ( https://github.com/systemd/systemd/issues/17575 ) and
a PR ( https://github.com/systemd/systemd/pull/18010 ).
Upstream community is not willing to accept the patch but debian is.
I open this bug to to pull the patch into Ubuntu once it lands in debian.
[TEST PLAN]
The simpler reproducer is to disable dbus to imitate the real world
case.
# systemctl stop dbus.service
# systemctl stop dbus.socket
# shutdown +1140 -r "REBOOT!"
Failed to set wall message, ignoring: Failed to activate service 'org.freedesktop.login1': timed out (service_start_timeout=25000ms)
Failed to call ScheduleShutdown in logind, proceeding with immediate shutdown: Connection timed out
Connection to groovy closed by remote host.
Connection to groovy closed.
[WHERE PROBLEM COULD OCCUR]
This patch changes the behaviour of scheduled reboot in case logind or dbus has failed.
Originally, if logind is not available (call to logind bus fails
https://github.com/systemd/systemd/blob/master/src/systemctl/systemctl-logind.c#L319)
it proceeds with immediate shutdown.
This patch changes this behaviour and instead of shutting down it does nothing.
The actual regression potential is a user asking for a reboot and not getting it, so the largest regression potential is any existing users (human or programmatic) that are requesting a scheduled shutdown but not checking the return value for error.
Any other regression would likely result in the system incorrectly not rebooted, or incorrectly scheduled for reboot.
[OTHER]
This is now fixed in H, currently affects B,G,F.
Debian bug reports :
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=931235
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=960042
Upstream issue : https://github.com/systemd/systemd/issues/17575
PR : https://github.com/systemd/systemd/pull/18010
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1911187/+subscriptions