-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Description
systemd version the issue has been seen with
258-rc3
Used distribution
Fedora 44
Linux kernel version used
6.17.0-0.rc2.250821g068a56e56fa8.27.fc44.x86_64
CPU architectures issue was seen on
x86_64
Component
systemd-logind
Expected behaviour you didn't see
Kmscon can't create multiple logind sessions on the same vt. Kmscon can create multiple terminals running on the same vt when used with --session-control. Only the first terminal will create a logind session when a user logs in. All other terminals will be sessionless.
Unexpected behaviour you saw
This check in the manager_create_session function in the file logind-dbus.c prevents multiple sessions from being on the same vt.
if (class != SESSION_GREETER &&
vtnr > 0 &&
vtnr < MALLOC_ELEMENTSOF(m->seat0->positions) &&
m->seat0->positions[vtnr] &&
m->seat0->positions[vtnr]->class != SESSION_GREETER) {
return log_debug_errno(SYNTHETIC_ERRNO(EADDRNOTAVAIL), "VT already occupied by a session.");
Steps to reproduce the problem
Run kmscon with --session-control and --vt=n where n is any vt number in order to run kmscon on a vt. Login to the first terminal session. Create a new terminal session with Ctrl+Super+Enter. Login to that terminal session too. Run loginctl and see that only one logind session is created.