On Fri, 22 Dec 2023 at 03:23:21 +0100, Olivier Mehani wrote:
> GDM3 doesn't seem to be able to start a Wayland session (nor a fallback Xorg 
> session, but I'm less concerned about this, and this seems to be a 
> separate permission issue).

That's a valid bug, let's leave your report open for that.

If neither Wayland nor Xorg works, that would suggest (to me, at least)
that this is a lower-level issue, indeed perhaps involving permissions
as you say.

> This seems to be related to 
> org.freedesktop.systemd1 failing to activate (and triggering the 
> fallback to Xorg).

I don't think this is necessarily the root cause, though.

> The smoking gun implicating org.freedesktop.systemd1 is
> 
>   déc. 22 03:17:17 desktop gdm-launch-environment][28769]: 
> pam_unix(gdm-launch-environment:session): session opened for user 
> Debian-gdm(uid=113) by (uid=0)
>   déc. 22 03:17:17 desktop /usr/libexec/gdm-wayland-session[28792]: 
> dbus-daemon[28792]: [session uid=113 pid=28792] Activating service 
> name='org.freedesktop.systemd1' requested by ':1.0' (uid=113 pid=28785 
> comm="/usr/libexec/gdm-wayland-session dbus-run-session ")
>   déc. 22 03:17:17 desktop /usr/libexec/gdm-wayland-session[28792]: 
> dbus-daemon[28792]: [session uid=113 pid=28792] Activated service 
> 'org.freedesktop.systemd1' failed: Process org.freedesktop.systemd1 exited 
> with status 1

Even though it looks bad at first glance, this could actually be fine. gdm
can run more than one "greeter" (login prompt) under the same uid, so it
intentionally avoids the mechanism that would normally result in having
one `dbus-daemon --session` per uid. Instead, it uses dbus-run-session(1)
to launch one `dbus-daemon --session` per greeter.

The result is that gdm-wayland-session tries to contact `systemd --user`,
which fails with exit status 1, because
/usr/share/dbus-1/system-services/org.freedesktop.systemd1.service
contains:

    Exec=/bin/false

(it is not possible to start a `systemd --user` when already inside a
session that does not already have one).

I get similar messages on a fully-working system, in this case a virtual
machine running bookworm and GNOME, without anything being obviously broken:

Dec 22 14:38:53 d12gnome /usr/libexec/gdm-wayland-session[691]: 
dbus-daemon[691]: [session uid=113 pid=691] Activating
 service name='org.freedesktop.systemd1' requested by ':1.10' (uid=113 pid=851 
comm="/usr/libexec/gsd-sharing")
Dec 22 14:38:53 d12gnome /usr/libexec/gdm-wayland-session[691]: 
dbus-daemon[691]: [session uid=113 pid=691] Activated service 
'org.freedesktop.systemd1' failed: Process org.freedesktop.systemd1 exited with 
status 1
Dec 22 14:38:53 d12gnome gsd-sharing[851]: Failed to StopUnit service: 
GDBus.Error:org.freedesktop.DBus.Error.Spawn.ChildExited: Process 
org.freedesktop.systemd1 exited with status 1
Dec 22 14:38:53 d12gnome gsd-sharing[851]: Failed to StopUnit service: 
GDBus.Error:org.freedesktop.DBus.Error.Spawn.ChildExited: Process 
org.freedesktop.systemd1 exited with status 1
Dec 22 14:38:53 d12gnome gnome-shell[727]: Error looking up permission: 
GDBus.Error:org.freedesktop.portal.Error.NotFound: No entry for geolocation
Dec 22 14:38:53 d12gnome org.gnome.Shell.desktop[783]: Failed to initialize 
glamor, falling back to sw
Dec 22 14:38:53 d12gnome /usr/libexec/gdm-wayland-session[691]: 
dbus-daemon[691]: [session uid=113 pid=691] Activating service 
name='org.gtk.vfs.Daemon' requested by ':1.25' (uid=113 pid=885 
comm="ibus-daemon --panel disable")

So I think you might need to look elsewhere for the root cause of the gdm
session not starting successfully.

    smcv

Reply via email to