[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: systemd - excessive session-creation time



On 5/18/14, Tom H <tomh0665@gmail.com> wrote:
> On Sat, May 17, 2014 at 10:49 PM, Zenaan Harkness <zen@freedbms.net> wrote:
>>
>> Although initial tty session (from boot) is quicker than with
>> sysvinit, additional tty sessions are very slow to start, in the order
>> of 5 seconds (which seems like an eternity).
>>
>> Additionally, this slow tty/session creation time is seen when:
>> *) exiting X - ie logout back to terminal (from startx)
>> *) Shutdown from XFCE logout/shutdown dialog
>>
>> When exiting X from a startx at the linux tty, there appears to be a
>> large session tear-down time.
>>
>> In addition, a similarly long duration is seen when (as stated)
>> starting another linux vt.
>
> By default, other than tty1 (via
> "/etc/systemd/system/getty.target.wants/getty@tty1.service"), VTs are
> started dynamically as needed.

Sure.

> If you want tty2 to be available permanently and persistently through
> reboots, run:
>
> systemctl enable getty@tty2.service
> systemctl start getty@tty2.service
>
> The first command will create a
> "/etc/systemd/system/getty.target.wants/getty@tty2.service" symlink to
> "/lib/systemd/system/getty@.service", which is more or less similar
> to, in the case of a hypothetical getty@tty2 sysvinit script, having
> "update-rc.d enable getty@tty2" create
> "/etc/rc{2,3,4,5}.d/Sabgetty@tty2" and "/etc/rc{0,6}.d/Kcdgetty@tty2"
> symlinks to "/etc/init.d/getty@tty2".

That's possibly useful. I've just made use of it thanks.

But it doesn't have anything to do with tty1 having these 5 second (or
more) vt pauses on shutdown and/ or X exiting.

I've used the code that specifies X start on tty1/vt01 (I posted that
in my se() shell function). So we're not dealing with tty2 here, just
tty1.

I've just now confirmed that by running the above commands you
suggest, Ctrl-Alt-F2 to see that yes, the getty login is there, then
Alt-LeftArrow, and yes, back into X!

Thanks,
Zenaan


Reply to: