FS#32206 - [xorg-xinit] default xserverrc is broken with systemd/logind

Attached to Project: Arch Linux
Opened by Daniel Micay (thestinger) - Wednesday, 24 October 2012, 22:48 GMT
Last edited by Andreas Radke (AndyRTR) - Wednesday, 31 October 2012, 06:44 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Jan de Groot (JGC)
Andreas Radke (AndyRTR)
Dave Reisner (falconindy)
Architecture All
Severity High
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 7
Private No

Details

In order to avoid breaking the session, consolekit required that X be run on the same TTY where the session was registered. The ck-launch-session command could be used as a workaround, to move the permissions over to a new TTY.

However, logind does not come with an equivalent to ck-launch-session, so it is always broken to use xorg-xinit to start X on a different TTY.

The current xserverrc (provided by the package, not upstream) has this snippet:

exec /usr/bin/X -nolisten tcp "$@"

It could be changed to the following:

#!/bin/bash

if [[ -z $XDG_VTNR ]]; then
exec /usr/bin/X -nolisten tcp "$@"
else
exec /usr/bin/X -nolisten tcp "$@" vt$XDG_VTNR
fi

This will check if there is currently a session, and avoid breaking it. It can still be overriden in ~/.xserverrc, so it's just about providing a working default.

Right now every user using systemd and xorg-xinit has to work around the issue themselves, which results in a lot of boilerplate instructions on the wiki, and an endless stream of issues in irc (which can be non-obvious to diagnose - broken sound, 3D acceleration, etc.).
This task depends upon

Closed by  Andreas Radke (AndyRTR)
Wednesday, 31 October 2012, 06:44 GMT
Reason for closing:  Fixed
Comment by Daniel Micay (thestinger) - Wednesday, 24 October 2012, 22:49 GMT
Silly bug tracker ate the indents... oh well.
Comment by Greg (dolby) - Wednesday, 24 October 2012, 22:58 GMT
There is already at least one bug report about this: FS#32096 
Comment by Daniel Wallace (gtmanfred) - Tuesday, 30 October 2012, 04:02 GMT
+1 this should be fixed especially for #archlinux, the forums, and the mailing list, so it doesn't have to be explained that you need to go ahead and do this for audio to work, since references to the audio group have been removed from the beginners guide

Loading...