Commit 1fb40a5
fix(wslg): boot-time X11 socket symlink + start user@1000.service
* usr/lib/tmpfiles.d/mios-wslg.conf (new): `L+ /tmp/.X11-unix - - -
- /mnt/wslg/.X11-unix` -- forces the X11 socket symlink at BOOT
via systemd-tmpfiles, instead of the previous shell-only `ln -sf`
in /usr/lib/profile.d/mios-wsl2.sh which only ran when an
interactive shell sourced profile. System-launched processes
(Quadlets, .desktop launchers, dbus-activated services, GUI apps
spawned by `nautilus &`) start without shell profile and hit:
F: X11 socket /tmp/.X11-unix/X0 does not exist in filesystem.
libportal-CRITICAL: Cannot autolaunch D-Bus without X11 $DISPLAY
`L+` forces the symlink even if /tmp/.X11-unix already exists as
an empty dir (some distro layers pre-create it that way and block
a regular `ln -sf`). No-op on bare-metal hosts because /mnt/wslg
doesn't exist there; tmpfiles silently skips L-rules with absent
source.
* usr/lib/systemd/system/mios-wsl-runtime-dir.service: ExecStart now
also drops /var/lib/systemd/linger/mios (canonical logind linger
marker -- though logind itself is condition-gated off on WSL) and
runs `systemctl start user@1000.service`. systemd-logind would
normally start the user manager from the linger marker, but on WSL
with logind absent we have to kick it ourselves. Without this the
user D-Bus session bus never starts and GTK apps fail with
`Cannot autolaunch D-Bus without X11 $DISPLAY` even when DISPLAY
is correctly set. Failures are non-fatal -- the unit still
succeeds even if user@<uid>.service can't fully come up, so the
/run/user/$uid bit (the original purpose of the service) always
lands.
Pairs with the existing user@1000.service preset entry in
90-mios.preset (added earlier to address the same "no user systemd
manager" issue from the operator's first WSL boot journal).
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>1 parent e5598f3 commit 1fb40a5
2 files changed
Lines changed: 27 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
28 | 30 | | |
29 | 31 | | |
30 | 32 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
0 commit comments