Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Set TTYPath for user-session@.service

In order for a login session (managed by systemd-logind) to become fully
active, it must be assigned to both a seat and a VT.  Without using a
display manager, two options are available for ensuring these
assignments are made: (a) set XDG_SEAT and XDG_VTNR in the PAM session,
or (b) set PAM_TTY in the PAM session.

This commit implements the second option by setting TTYPath to
"/dev/tty1" for user-session@.service, thereby forcing systemd to set
PAM_TTY in the PAM session, which then sets XDG_SEAT to "seat0" and
XDG_VTNR to "1" for the user session.  "/dev/tty1" is the TTY of choice
because xorg-launch-helper spawns Xorg on tty1.
  • Loading branch information...
commit 9f61e0753d67d8424d70a6c41456ddbb969ffc3b 1 parent 9a7c498
@phmccarty phmccarty authored
Showing with 1 addition and 0 deletions.
  1. +1 −0  units/system/
1  units/system/
@@ -15,6 +15,7 @@ PAMName=login
ControlGroup=%R/user/%I/shared cpu:/
ExecStart=-@SYSTEMDUTILDIR@/systemd --user
Please sign in to comment.
Something went wrong with that request. Please try again.