Subject: bug#65992: readutmp should check for sd_booted() and not if /run/utmp exists

From: Bruno Haible <[email-masked]>
Date: Fri, 15 Sep 2023 15:37:33 +0200

Thorsten Kukuk wrote:
> Who creates an additional line for "seat0", which no other tools creates
> and which it did not create before. Since some display manager writes
> wrongly multiple utmp entries

To me, that's a feature, not a bug. Systemd has introduced the concept of
seats [1], and the concept of tty is not so adequate any more for
identifying a session (because some terminal emulators / desktops put
a line into /var/run/utmp for each open terminal emulator window [2]).
It is thus natural and useful to show the association between user and seat.

Bruno

[1] https://www.freedesktop.org/wiki/Software/systemd/multiseat/
[2] https://www.thkukuk.de/blog/Y2038_glibc_utmp_64bit/