Display manager

Related articles
Start X at login
A
display manager
, or login manager, is typically a graphical user interface that is displayed at the end of the boot process in place of the default shell. There are various implementations of display managers, just as there are various types of
window managers
and
desktop environments
. There is usually a certain amount of customization and themeability available with each one.
List of display managers
Console
CDM
— Login manager written in Bash.
https://github.com/evertiro/cdm
||
cdm
AUR
Console TDM
— Extension for
xinit
written in pure Bash.
https://github.com/dopsi/console-tdm
||
console-tdm
AUR
emptty
— Simple CLI Display Manager on TTY with X and Wayland support written in Go.
https://github.com/tvrzna/emptty/
||
emptty
Lemurs
— TUI display manager for Linux, written in Rust. Supports X, Wayland and TTY shell sessions.
https://github.com/coastalwhite/lemurs
||
lemurs
lidm
— A fully colorful customizable TUI display manager made in C
https://github.com/javalsai/lidm
||
lidm
AUR
loginx
— A getty/login/xinit combination with a friendly curses ui.
https://sourceforge.net/projects/loginx/
||
loginx
AUR
Ly
— TUI (ncurses-like) display manager for Linux and BSD. Supports X and Wayland sessions.
https://codeberg.org/fairyglade/ly
||
ly
nodm
— Display manager for automatic logins. Discontinued since 2017.
https://github.com/spanezz/nodm
||
nodm
tbsm
— A Bash session or application launcher. Supports X and Wayland sessions.
https://loh-tar.github.io/tbsm/
||
tbsm
AUR
Graphical
Entrance
—
Enlightenment
display manager. Highly experimental. Development is currently semi-active.
https://github.com/wltjr/entrance
||
entrance-git
AUR
GDM
—
GNOME
display manager.
https://wiki.gnome.org/Projects/GDM
||
gdm
LightDM
— Cross-desktop display manager, can use various front-ends written in any toolkit.
https://github.com/ubuntu/lightdm/
||
lightdm
LXDM
—
LXDE
display manager. Can be used independent of the LXDE desktop environment.
https://sourceforge.net/projects/lxdm/
||
lxdm
Plasma Login Manager
— The preferred
KDE Plasma
display manager; designed to be a successor to SDDM.
https://invent.kde.org/plasma/plasma-login-manager/
||
plasma-login-manager
SDDM
— QML-based display manager and successor to KDM; recommended for
LXQt
.
https://github.com/sddm/sddm
||
sddm
SLiM
— Lightweight and elegant graphical login solution. Resurrected in 2022, not fully compatible with systemd.
https://slim-fork.sourceforge.io/
||
slim
XDM
— X display manager with support for XDMCP, host chooser.
xdm(8)
||
xorg-xdm
WDM
— WINGs Display Manager, hasn't been updated since 2012.
https://github.com/raorn/wdm
||
wdm-crm-git
AUR
Login daemons
greetd
— Login daemon which supports both console and graphical greeters.
https://git.sr.ht/~kennylevinsen/greetd
||
greetd
Loading the display manager
To enable graphical login at boot,
enable
the appropriate systemd service:
GDM —
gdm.service
LightDM —
lightdm.service
LXDM —
lxdm.service
Plasma Login Manager —
plasmalogin.service
SDDM —
sddm.service
SLiM —
slim.service
XDM —
xdm.service
If
xdm-archlinux
is installed, enable
xdm-archlinux.service
instead.
If the default target to boot into is
graphical.target
then this should work out of the box. If not, you might have to reset a custom
default.target
symlink to point to the default
graphical.target
. See
systemd#Change default target to boot into
.
After enabling the display manager's service a symlink
display-manager.service
should be set in
/etc/systemd/system/
. You may need to use
--force
to override old symlinks.
$ file /etc/systemd/system/display-manager.service
/etc/systemd/system/display-manager.service: symbolic link to /usr/lib/systemd/system/sddm.service
Using systemd-logind
In order to check the status of your user session, you can use
loginctl
. All
polkit
actions like suspending the system or mounting external drives will work out of the box.
$ loginctl show-session $XDG_SESSION_ID
Session configuration
Many display managers read available sessions from
/usr/share/xsessions/
directory. It contains standard
desktop entry files
for each desktop environment or window manager. Some display managers use a separate
/usr/share/wayland-sessions/
to list
Wayland
-specific sessions.
To add/remove entries to your display manager's session list, create/remove the
.desktop
files in
/usr/share/xsessions/
as desired. A typical
.desktop
file will look something like:
[Desktop Entry]
Name=Openbox
Comment=Log in using the Openbox window manager (without a session manager)
Exec=/usr/bin/openbox-session
TryExec=/usr/bin/openbox-session
Icon=openbox.png
Type=Application
Run ~/.xinitrc as a session
Installing
xinit-xsession
AUR
will provide an option to run your
xinitrc
as a session. Simply set
xinitrc
as the session in your display manager's settings and make sure that the
~/.xinitrc
file is executable.
Starting applications without a window manager
You can also launch an application without any decoration, desktop, or window management. For example, to launch
google-chrome
AUR
, create a
web-browser.desktop
file in
/usr/share/xsessions/
like this:
[Desktop Entry]
Name=Web Browser
Comment=Use a web browser as your session
Exec=/usr/bin/google-chrome --auto-launch-at-startup
TryExec=/usr/bin/google-chrome --auto-launch-at-startup
Icon=google-chrome
Type=Application
In this case, once you login, the application set with
Exec
will be launched immediately. When you close the application, you will be taken back to the login manager (same as logging out of a normal desktop environment or window manager).
It is important to remember that most graphical applications are not intended to be launched this way and you might have manual tweaking to do or limitations to live with (there is no window manager, so do not expect to be able to move or resize
any
windows, including dialogs; nonetheless, you might be able to set the window geometry in the application's configuration files).
See also
xinitrc#Starting applications without a window manager
.
Tips and tricks
Autostarting
Most display managers source
/etc/xprofile
,
~/.xprofile
and
/etc/X11/xinit/xinitrc.d/
. For more details, see
xprofile
.
Set language for user session
For display managers that use
AccountsService
the
locale
for the user session can be set by editing:
/var/lib/AccountsService/users/$USER
[User]
Language=
your_locale
where
your_locale
is a value such as
en_GB.UTF-8
.
Alternatively, you can achieve this using
D-Bus
:
busctl call org.freedesktop.Accounts /org/freedesktop/Accounts/User$UID org.freedesktop.Accounts.User SetLanguage s
your_locale
GNOME and KDE users can also set languages in GNOME or KDE settings.
Log out and then back in again for the changes to take effect.
Unlock Gnome Keyring / KDE KWallet automatically on autologin with LUKS
This article or section needs expansion.
Reason:
Does this feature apply to
sd-encrypt
only? (Discuss in
Talk:Display manager
)
Since systemd version 255,
pam_systemd_loadkey
can be used to unlock a GNOME/Kwallet keyring, if the user password matches the LUKS passphrase of the system. For this to work, you need to enable autologin in the display manager.
See also
Login managers: An introduction
- Discusses implementation of a login manager