Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#1025349: gdm3: should define the display-manager alias for start dependencies

59 views
Skip to first unread message

Samuel Thibault

unread,
Dec 2, 2022, 7:10:03 PM12/2/22
to
Package: gdm3
Version: 43.0-1
Severity: normal

Hello,

If gdm happens to manage to start quicker than console-setup,
console-setup's setupcon call will fail. So we need a dependency between
the two, to make console-setup start "Before" display managers. This can
be set with

Before=display-manager.service

since display managers usually set this alias. But gdm3 apparently
explicitly removes this with the debian/patches/92_systemd_unit.patch
patch:

* Don't install the display-manager.service alias, which is managed
jointly by all Debian display managers via a debconf question

but I don't think that's the point of the display-manager.service alias?

At any rate, we need a proper way to make console-setup get started
before display managers (and I don't think making console-setup explicit
a list of display managers is a proper way to do it :) )

Samuel

-- System Information:
Debian Release: bookworm/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable-debug'), (500, 'testing-debug'), (500, 'stable-security'), (500, 'stable-debug'), (500, 'proposed-updates-debug'), (500, 'proposed-updates'), (500, 'oldstable-proposed-updates'), (500, 'oldoldstable'), (500, 'buildd-unstable'), (500, 'unstable'), (500, 'stable'), (500, 'oldstable'), (1, 'experimental-debug'), (1, 'buildd-experimental'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386, arm64

Kernel: Linux 6.0.0-4-amd64 (SMP w/8 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages gdm3 depends on:
ii accountsservice 22.08.8-1+b1
ii adduser 3.129
ii cdebconf [debconf-2.0] 0.265
ii cinnamon [x-window-manager] 5.4.12-2
ii cinnamon-session [x-session-manager] 5.6.0-1
ii dbus [default-dbus-system-bus] 1.14.4-1
ii dbus-bin 1.14.4-1
ii dbus-broker [dbus-system-bus] 32-1+b1
ii dbus-daemon 1.14.4-1
ii dconf-cli 0.40.0-3
ii dconf-gsettings-backend 0.40.0-3
ii debconf [debconf-2.0] 1.5.79
ii eterm [x-terminal-emulator] 0.9.6-6.1
ii fvwm [x-window-manager] 1:2.7.0-1
ii fvwm3 [x-window-manager] 1.0.5+ds-2
ii gir1.2-gdm-1.0 43.0-1
ii gnome-session [x-session-manager] 43.0-1
ii gnome-session-bin 43.0-1
ii gnome-session-common 43.0-1
ii gnome-settings-daemon 43.0-3
ii gnome-shell 43.1-2
ii gnome-terminal [x-terminal-emulator] 3.46.2-1
ii gsettings-desktop-schemas 43.0-1
ii icewm [x-window-manager] 3.1.0-1
ii konsole [x-terminal-emulator] 4:22.08.1-1
ii libaccountsservice0 22.08.8-1+b1
ii libaudit1 1:3.0.7-1.1+b2
ii libc6 2.36-5
ii libcanberra-gtk3-0 0.30-10
ii libcanberra0 0.30-10
ii libgdk-pixbuf-2.0-0 2.42.10+dfsg-1
ii libgdm1 43.0-1
ii libglib2.0-0 2.74.1-2
ii libglib2.0-bin 2.74.1-2
ii libgtk-3-0 3.24.35-1
ii libgudev-1.0-0 237-2
ii libkeyutils1 1.6.3-1
ii libpam-modules 1.5.2-5
ii libpam-runtime 1.5.2-5
ii libpam-systemd [logind] 252.1-1
ii libpam0g 1.5.2-5
ii librsvg2-common 2.54.5+dfsg-1
ii libselinux1 3.4-1+b3
ii libsystemd0 252.1-1
ii libx11-6 2:1.8.1-2
ii libxau6 1:1.0.9-1
ii libxcb1 1.15-1
ii libxdmcp6 1:1.1.2-3
ii lsb-base 11.5
ii lxsession [x-session-manager] 0.5.5-2+b1
ii lxterminal [x-terminal-emulator] 0.4.0-2
ii marco [x-window-manager] 1.26.1-1
ii mate-session-manager [x-session-manager] 1.26.0-1
ii mate-terminal [x-terminal-emulator] 1.26.0-1
ii metacity [x-window-manager] 1:3.46.0-1
ii mlterm [x-terminal-emulator] 3.9.0-1+b1
ii muffin [x-window-manager] 5.4.7-1
ii mutter [x-window-manager] 43.0-2
ii olwm [x-window-manager] 3.2p1.4-28.1
ii openbox [x-window-manager] 3.6.1-10
ii openbox-lxde-session [x-session-manager] 0.99.2-4
ii polkitd 122-1
ii procps 2:3.3.17-7.1
ii pterm [x-terminal-emulator] 0.78-1
ii rxvt-unicode [x-terminal-emulator] 9.30-2+b3
ii stterm [x-terminal-emulator] 0.9-1
ii systemd-sysv 252.1-1
ii sysvinit-utils [lsb-base] 3.05-7
ii twm [x-window-manager] 1:1.0.10-1
ii ucf 3.0043
ii x11-common 1:7.7+23
ii x11-xserver-utils 7.7+9+b1
ii xfce4-session [x-session-manager] 4.16.0-2
ii xfce4-terminal [x-terminal-emulator] 1.0.4-1
ii xfwm4 [x-window-manager] 4.16.1-1
ii xterm [x-terminal-emulator] 376-1

Versions of packages gdm3 recommends:
ii at-spi2-core 2.46.0-4
ii cinnamon-session [x-session-manager] 5.6.0-1
ii desktop-base 11.0.3
ii gnome-session [x-session-manager] 43.0-1
ii lxsession [x-session-manager] 0.5.5-2+b1
ii mate-session-manager [x-session-manager] 1.26.0-1
ii openbox [x-session-manager] 3.6.1-10
ii openbox-lxde-session [x-session-manager] 0.99.2-4
ii x11-xkb-utils 7.7+7
ii xfce4-session [x-session-manager] 4.16.0-2
ii xserver-xephyr 2:21.1.4-3
ii xserver-xorg 1:7.7+23
ii zenity 3.43.0-1

Versions of packages gdm3 suggests:
pn libpam-fprintd <none>
ii libpam-gnome-keyring 42.1-1+b1
pn libpam-pkcs11 <none>
pn libpam-sss <none>
ii orca 43.0-1

-- debconf information:
* gdm3/daemon_name: /usr/sbin/gdm3
* shared/default-x-display-manager: lightdm

--
Samuel
---
Pour une évaluation indépendante, transparente et rigoureuse !
Je soutiens la Commission d'Évaluation de l'Inria.

Simon McVittie

unread,
Dec 4, 2022, 7:20:03 PM12/4/22
to
On Sat, 03 Dec 2022 at 01:03:38 +0100, Samuel Thibault wrote:
> If gdm happens to manage to start quicker than console-setup,
> console-setup's setupcon call will fail. So we need a dependency between
> the two, to make console-setup start "Before" display managers. This can
> be set with
>
> Before=display-manager.service
>
> since display managers usually set this alias. But gdm3 apparently
> explicitly removes this with the debian/patches/92_systemd_unit.patch
> patch:
>
> * Don't install the display-manager.service alias, which is managed
> jointly by all Debian display managers via a debconf question

Upstream gdm3.service (or possibly gdm.service, I think we do some renaming
for historical reasons) has

[Install]
Alias=display-manager.service

so that `systemctl enable gdm3.service` will create a symlink
/etc/systemd/system/display-manager.service -> /lib/systemd/system/gdm3.service.
This assumes that only one display manager can be enabled at a time, and
preferably only one *installed* at a time: if both gdm3 and lightdm try
to do that, if I understand correctly, the result will be unpredictable.

In Debian, instead of gdm3.service having that, the debconf question
creates that symlink programmatically if and only if gdm3 is the selected
display manager (in particular, the symlink isn't created if you have
installed both gdm3 and lightdm, and chosen to use lightdm instead).

If I understand correctly, any mechanism that makes the symlink exist
should be enough for "Before=display-manager.service" to do what you want
it to do. Please try it?

systemd maintainers: Am I getting this right?

smcv

Samuel Thibault

unread,
Dec 4, 2022, 7:30:04 PM12/4/22
to
Simon McVittie, le lun. 05 déc. 2022 00:15:01 +0000, a ecrit:
> Upstream gdm3.service (or possibly gdm.service, I think we do some renaming
> for historical reasons) has
>
> [Install]
> Alias=display-manager.service
>
> so that `systemctl enable gdm3.service` will create a symlink
> /etc/systemd/system/display-manager.service -> /lib/systemd/system/gdm3.service.
> This assumes that only one display manager can be enabled at a time, and
> preferably only one *installed* at a time: if both gdm3 and lightdm try
> to do that, if I understand correctly, the result will be unpredictable.
>
> In Debian, instead of gdm3.service having that, the debconf question
> creates that symlink programmatically if and only if gdm3 is the selected
> display manager (in particular, the symlink isn't created if you have
> installed both gdm3 and lightdm, and chosen to use lightdm instead).
>
> If I understand correctly, any mechanism that makes the symlink exist
> should be enough for "Before=display-manager.service" to do what you want
> it to do. Please try it?

Ah, indeed, that works, sorry for not having actually tried, because
lightdm does have these two lines. But then, with this reasoning,
lightdm is bogus by having these two lines?

Samuel

Simon McVittie

unread,
Dec 5, 2022, 11:20:04 AM12/5/22
to
I honestly don't know. Maybe this is wrong in lightdm (and possibly
other *dm implementations), or maybe removing those lines in gdm3 is
unnecessary delta and we don't really need that part of the patch?

We need a small amount of delta in the source file gdm.service.in *anyway*,
so if this is an unnecessary patch, it's not a particularly expensive one.

Note that both gdm3 and lightdm override dh_installsystemd to do nothing,
so probably it doesn't matter very much in practice unless a sysadmin
explicitly runs `systemctl enable gdm3.service` or
`systemctl enable lightdm.service` themselves.

smcv
0 new messages