Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 768834 - sys-auth/elogind-243.7: race with gui-libs/display-manager-init-1.0
Summary: sys-auth/elogind-243.7: race with gui-libs/display-manager-init-1.0
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Andreas Sturmlechner
URL:
Whiteboard:
Keywords: PullRequest
Depends on:
Blocks:
 
Reported: 2021-02-05 09:19 UTC by Arusekk
Modified: 2021-02-05 22:46 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Arusekk 2021-02-05 09:19:14 UTC
The new display-manager init script races with elogind, and if it wins the race, power management buttons (reboot, suspend...) are unavailable in e.g. SDDM.

Possible solution: add display-manager to before in /etc/init.d/elogind, like xdm:

depend() {
 	need dbus

	# Make sure elogind is up before xdm/display-manager starts any dm
	before xdm display-manager
}


Reproducible: Didn't try

Steps to Reproduce:
1. Add an X (X server [elogind,-suid]) display-manager to runlevel default, remove xdm from runlevels.
2. Add elogind to runlevel default.
3. Reboot several times (I had the issue on ca. 20th boot).
Actual Results:  
DM is unable to use PM functions.

Expected Results:  
DM is able to use PM functions.
Comment 1 Ionen Wolkens gentoo-dev 2021-02-05 14:00:12 UTC
I believe should be avoidable by not having elogind in runlevels and letting it get started by dbus.

But old before behavior should be restored nonetheless.
Comment 2 Ionen Wolkens gentoo-dev 2021-02-05 14:31:59 UTC
(In reply to Ionen Wolkens from comment #1)
>should be restored nonetheless.
Well, should is a big word. Maybe having a after in display-manager-init would make more sense so elogind doesn't have to get revbumps for things like this.
Comment 3 Larry the Git Cow gentoo-dev 2021-02-05 22:46:10 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d31814390355efc67e3a9749ac9a945c2eb7bf34

commit d31814390355efc67e3a9749ac9a945c2eb7bf34
Author:     Aisha Tammy <gentoo@aisha.cc>
AuthorDate: 2021-02-05 22:38:23 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2021-02-05 22:45:59 +0000

    gui-libs/display-manager-init: start after elogind
    
    fixes race condition with elogind
    Closes: https://bugs.gentoo.org/768834
    Package-Manager: Portage-3.0.14, Repoman-3.0.2
    Signed-off-by: Aisha Tammy <gentoo@aisha.cc>
    Closes: https://github.com/gentoo/gentoo/pull/19348
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 ...lay-manager-init-1.0.ebuild => display-manager-init-1.0-r1.ebuild} | 2 +-
 .../files/{display-manager.initd => display-manager.initd-r1}         | 4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)