Skip to content

Graphical User Interface

Linux supports both a Command Line Interface (CLI) and a Graphical User Interface (GUI):

CLIGUI
Best forRepetitive tasks, scripting, remote adminOccasional tasks, visual navigation
SpeedFaster once learnedEasier for infrequent operations
Resource useMinimalHigher (GPU, RAM)
Remote accessSSH works nativelyRequires X forwarding or VNC/RDP

Modern Linux desktop graphics involves several layers of software:

Application
|
v
Display Server (X11 or Wayland)
|
v
Window Manager / Compositor
|
v
Display Manager (login screen: gdm, sddm, lightdm)
|
v
Desktop Environment (GNOME, KDE, XFCE, ...)

Display manager architecture

AspectX Window System (X11)Wayland
ArchitectureClient-server: X server acts as middleman between apps and hardwareClient talks directly to compositor (combined display server + window manager)
PerformanceCan show screen tearing; more overhead from its client-server modelLower latency, smoother, less tearing
SecurityAny app can snoop on other windows’ input; legacy designApps isolated from each other; stronger sandboxing
Hardware supportRequires many extensions for modern high-DPI and multi-head setupsDesigned for modern GPU hardware and HiDPI
CompatibilityNative X11 app support; backward-compatibleLegacy X11 apps run through XWayland compatibility layer
AdoptionLegacy; still widely supportedDefault on Fedora, RHEL 8+, Ubuntu 22.04+, and most modern distros

Wayland is gradually replacing X11 as the default. In practice it’s mostly transparent to users - applications work the same way.

The Display Manager is the graphical login screen. It:

  • Starts the X/Wayland display server
  • Shows the login prompt
  • Launches the chosen desktop environment after authentication
Display ManagerDefault for
gdm (GNOME Display Manager)GNOME, Fedora, RHEL, Ubuntu
sddmKDE Plasma
lightdmXFCE, older Ubuntu (pre-18.04)
xdmMinimal/generic X11
Terminal window
# Check which display manager is active
systemctl status display-manager
# Switch default display manager
sudo dpkg-reconfigure gdm3 # Debian/Ubuntu
sudo systemctl enable gdm --force # Fedora/RHEL

If no display manager is running, start a graphical session manually:

Terminal window
startx # start X session using ~/.xinitrc config

When the system reaches graphical.target, the following happens:

  1. systemd starts the display manager (e.g., gdm)
  2. Display manager initializes the display server (X or Wayland)
  3. Display manager shows the login screen
  4. User authenticates - PAM verifies credentials
  5. Display manager launches the desktop environment (session manager + window manager)
ComponentRole
Session ManagerStarts/maintains graphical session components; restores previous session on login
Window ManagerControls window placement, title bars, borders, resizing, and focus
CompositorHandles rendering effects (transparency, animations); may be integrated with window manager
Panel/TaskbarApplication launcher, clock, system tray, open windows

Desktop EnvironmentDefault ShellPhilosophy
GNOMEGNOME ShellClean, minimal, modern; keyboard-friendly
KDE PlasmaPlasmashellHighly customizable; Windows-like layout
XFCEXfwmLightweight and fast; classic desktop layout
LXDE / LXQtOpenbox / KWinExtremely lightweight; old hardware
MATEMarcoGNOME 2 fork; traditional desktop
CinnamonMuffinGNOME 3 fork; Windows-like; Linux Mint default

Install a desktop environment on a server (Debian/Ubuntu example):

Terminal window
sudo apt install gnome-core # minimal GNOME
sudo apt install kde-plasma-desktop # KDE Plasma
sudo systemctl set-default graphical.target # ensure it starts at boot

ShortcutAction
Ctrl-1 / Ctrl-2Switch between icon and list view in file manager
Ctrl-HShow/hide hidden files (dotfiles)
Ctrl-FOpen search box in file manager
Ctrl-LOpen location bar (type a path directly)
Super (Windows key)Open Activities overview
Super-TabSwitch between running applications
Alt-F4Close current window
Ctrl-Alt-TOpen terminal (most distributions)

On servers, the GUI is typically disabled:

Terminal window
# Check current default
systemctl get-default
# Set to text mode (disable GUI startup)
sudo systemctl set-default multi-user.target
# Re-enable GUI
sudo systemctl set-default graphical.target
# Temporarily start GUI without changing default
sudo systemctl isolate graphical.target
# Check display server and session info
echo $DISPLAY # X11 display (e.g., :0)
echo $WAYLAND_DISPLAY # Wayland socket (e.g., wayland-0)
echo $XDG_SESSION_TYPE # x11 or wayland