I’ve just installed ArchLabs under QEMU/KVM using the
archlabs-2019.10.29.iso and terminals open & close again with this error printed:
/usr/lib/xorg/Xorg.wrap: Only console users are allowed to run the X server
This happens because
~/.profile has this line:
[ $XDG_VTNR -eq 1 ] && exec startx
$XDG_VTNR is also “1” in the X session.
To fix it I changed the line to:
[ $(tty) = /dev/tty1 ] && exec startx
Which allows terminals in X to run normallly (
tty in X returns
To reproduce this problem install with a console login and mksh as the default shell.