Public bug reported:

## Summary

When GDM 50 is configured to launch an X11 user session (e.g., Cinnamon),
the spawned session inherits XDG_SESSION_TYPE=wayland from GDM's own
greeter environment via the PAM session chain. gdm-x-session then broadcasts
this incorrect value through dbus-update-activation-environment to all
D-Bus-activated session services. Components like cinnamon-screensaver
honor XDG_SESSION_TYPE and exit immediately ("disabled in wayland sessions"),
causing required-component failure for cinnamon-session, and muffin
attempts to initialize a native Wayland backend instead of X11, hitting
EBUSY because GDM's Wayland compositor still holds DRM control.

Net effect: Cinnamon (and presumably other X11-only desktops) cannot be
launched from GDM on Ubuntu 26.04 — every login attempt times out at 30
seconds and returns to the greeter.

## Steps to reproduce

1. Fresh Ubuntu 26.04 install with GDM (default).
2. `sudo apt install cinnamon-desktop-environment`
3. Reboot.
4. At GDM greeter, select user → cog icon → choose "Cinnamon" (Xorg) → log in.

Expected: Cinnamon X11 session loads.
Actual: Black screen for ~30 seconds, then returns to GDM greeter.

## Evidence (from journalctl of the failed boot)

Environment GDM sets for the X session, captured from gdm-x-session's
dbus-update-activation-environment output:

  XDG_SESSION_DESKTOP=cinnamon
  XDG_SESSION_TYPE=wayland       ← incorrect for an X11 session
  XDG_SESSION_EXTRA_DEVICE_ACCESS=render:accel
  GDMSESSION=cinnamon
  DESKTOP_SESSION=cinnamon

Then in the failing session:

  cinnamon[N]: Failed to create backend: Could not take control:
    GDBus.Error:System.Error.EBUSY: Device or resource busy
  org.cinnamon.ScreenSaver: cinnamon-screensaver is disabled in
    wayland sessions. Exiting.
  cinnamon-session-binary: WARNING: t+30s: Application
    'cinnamon.desktop' failed to register before timeout
  cinnamon-session-binary: CRITICAL: Unable to start session: A program
    required by the session failed to start.

## Causal chain (verified)

  GDM greeter (Wayland) ──PAM session──▶ gdm-session-worker
                                            │ inherits XDG_SESSION_TYPE=wayland
                                            ▼
                                       gdm-x-session
                                       (starts Xorg correctly,
                                        but inherited env unchanged)
                                            │
                                            ▼
                                   dbus-update-activation-environment
                                   broadcasts XDG_SESSION_TYPE=wayland
                                   to all D-Bus services in the session
                                            │
                       ┌────────────────────┴────────────────────┐
                       ▼                                         ▼
              cinnamon (muffin)                     cinnamon-screensaver
              tries native Wayland backend          exits: "disabled in
              → DRM EBUSY                            wayland sessions"
              → no compositor                       → required-component
              → no shell, blank X screen              failure cascade

Note: `loginctl show-session $N` reports Type=x11 correctly for the user
session. The bug is specifically in the D-Bus activation environment
gdm-x-session broadcasts, which is inherited up the PAM chain rather
than set fresh based on session type.

## Workaround

Replace GDM with LightDM:

  sudo apt install lightdm lightdm-gtk-greeter slick-greeter
  sudo dpkg-reconfigure lightdm    # choose lightdm
  sudo systemctl reboot

LightDM does not run a Wayland greeter, so XDG_SESSION_TYPE=x11 propagates
correctly and Cinnamon launches normally. Confirmed working on the same
hardware.

WaylandEnable=false in /etc/gdm3/custom.conf does NOT fix the bug. Its
semantics changed in GDM ~44 to only hide Wayland from the user session
chooser; GDM's own greeter still runs Wayland regardless.

## System info

- Ubuntu 26.04 LTS (Resolute Raccoon)
- Kernel 7.0.0-17-generic
- GDM3 50.0-0ubuntu1
- Cinnamon 6.4.13 (universe)
- Hardware: Razer Blade 15 Early 2020 (Intel UHD + GTX 1660 Ti hybrid, PRIME 
on-demand)
- Nvidia driver: 595.58.03

## Notes for triage

- Reproducible: yes, every boot
- The bug likely affects any X11-only desktop (MATE, XFCE may be similar),
  not just Cinnamon — anything whose components check XDG_SESSION_TYPE
  or whose compositor uses the env-var to pick backend.
- Possible upstream fix path: gdm-x-session should override
  XDG_SESSION_TYPE=x11 in the environment it broadcasts via D-Bus,
  rather than inheriting it from the parent greeter session.
- I have additional logs available if useful.

ProblemType: Bug
DistroRelease: Ubuntu 26.04
Package: gdm3 50.0-0ubuntu1
ProcVersionSignature: Ubuntu 7.0.0-17.17-generic 7.0.2
Uname: Linux 7.0.0-17-generic x86_64
ApportVersion: 2.34.0-0ubuntu2
Architecture: amd64
CasperMD5CheckResult: pass
CurrentDesktop: X-Cinnamon
Date: Sun May 17 13:53:27 2026
InstallationDate: Installed on 2025-05-31 (351 days ago)
InstallationMedia: Ubuntu 25.04 "Plucky Puffin" - Release amd64 (20250415.3)
ProcEnviron:
 LANG=en_US.UTF-8
 PATH=(custom, no user)
 SHELL=/bin/bash
 TERM=xterm-256color
 XDG_RUNTIME_DIR=<set>
SourcePackage: gdm3
UpgradeStatus: No upgrade log present (probably fresh install)
mtime.conffile..etc.gdm3.custom.conf: 2026-05-17T03:41:22.118500

** Affects: gdm3 (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug resolute

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2152848

Title:
  GDM 50 leaks XDG_SESSION_TYPE=wayland from Wayland greeter into X11
  user sessions, breaking Cinnamon and other X11-only desktops

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gdm3/+bug/2152848/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to