(In reply to Fabian Vogt from comment #16) > I tried to debug this further, the issue is that sddm doesn't actually > create a session and set a controlling tty. That's currently done by the X > server. > This explains why -keeptty does not work and also why loginctl doesn't show > vt7. > > sddm only calls setsid for the user session, but as there's no X server in > the user session it doesn't get a controlling terminal either. > > While looking at lightdm to check how it's done properly I noticed that it > has the exact same issue. > > What does sddm need to do to work with -keeptty? How does gdm solve this problem? AFAICR the -keeptty option should avoid deteaching the controlling terminal by the X server. But here it is not connectted to the tty7 anymore: ps aux | grep bin/ root 2176 0.5 0.8 499472 70108 ? Sl Jul02 60:21 /usr/bin/X -nolisten tcp -keeptty -auth /run/sddm/{ac43390f-4fcf-4711-b111-99f6c749eb82} -background none -noreset -displayfd 17 -seat seat0 vt7 somehow strange. It seems that the option -keeptty does not work here. The question rises if this is how sddm/lightdm are starting the X server and how this differs from the method used by gdm.