Skip to content

i3 Login with ly on Arch

Configure ly as a terminal-style login manager for an i3 setup on Arch. This workflow covers installing ly, switching from a graphical display manager, enabling the correct ly systemd service, selecting the i3 session, fixing remembered Plasma sessions through dmrc and AccountsService, and switching back if needed.

Install ly from the Arch repositories. ly provides a terminal-style display manager that can launch X11 sessions such as i3.

Terminal window
sudo pacman -S ly

ly reads X11 sessions from /usr/share/xsessions. Confirm that the i3 session file exists before switching display managers.

Terminal window
ls /usr/share/xsessions

Expected available sessions on this setup include i3, i3-with-shmlog, and plasmax11. Use i3 for normal login.

Terminal window
i3.desktop
i3-with-shmlog.desktop
plasmax11.desktop

Disable the current graphical display manager and enable ly on tty2. The Arch ly package uses the tty-specific ly@tty2.service style rather than ly.service.

Terminal window
sudo systemctl disable lightdm
sudo systemctl enable ly@tty2.service
sudo systemctl disable getty@tty2.service
sudo reboot
  • After reboot, ly should appear as a terminal-style login screen.
  • Select i3 from the session field before logging in.
  • If ly opens Plasma, change the selected session to i3 and log in again.

Confirm ly is configured to use the standard X command and X session directory.

Terminal window
grep -n "xsessions\|x_cmd\|session" /etc/ly/config.ini

The important values are:

Terminal window
x_cmd = /usr/bin/X
xsessions = /usr/share/xsessions

Use the filename without .desktop when referring to a session name. For i3.desktop, the session name is i3.

Set the user’s dmrc session to i3. This helps display managers remember the intended X11 session.

Terminal window
nano ~/.dmrc
Terminal window
[Desktop]
Session=i3
Terminal window
cat ~/.dmrc

If the system keeps opening Plasma even after selecting i3, check the per-user AccountsService session. In this setup, AccountsService remembered Plasma and had to be changed to i3.

Terminal window
sudo cat /var/lib/AccountsService/users/$USER

If the file contains XSession=plasma, edit it and change the remembered X session to i3. Replace $USER with the target username on another machine.

Terminal window
sudo nano /var/lib/AccountsService/users/$USER
Terminal window
[User]
Session=
XSession=i3
Icon=/home/$USER/.face
SystemAccount=false
  • The important value is XSession=i3.
  • If XSession=plasma is present, the login manager can keep opening Plasma.
  • After changing the file, reboot and choose i3 in ly once.

Use these commands after logging in to confirm that ly is active and the i3 session files are available.

Terminal window
systemctl status display-manager --no-pager
systemctl status ly@tty2.service --no-pager
ls /usr/share/xsessions
cat ~/.dmrc
sudo cat /var/lib/AccountsService/users/$USER

If ly does not work as expected or a graphical login screen is preferred again, disable ly and restore LightDM.

Terminal window
sudo systemctl disable ly@tty2.service
sudo systemctl enable getty@tty2.service
sudo systemctl enable lightdm
sudo reboot
  • ly config: /etc/ly/config.ini
  • ly systemd service: ly@tty2.service
  • LightDM service: lightdm.service
  • User dmrc session file: ~/.dmrc
  • AccountsService user session file: /var/lib/AccountsService/users/$USER
  • X11 session files: /usr/share/xsessions