Linux Graphical Target Won't Start – Fix in 3 Steps
Your Linux desktop won't boot to the GUI. Usually it's a driver issue or a bad config. Here's how to fix it fast.
1. Systemd Default Target Changed to Multi-User
If you see a command line login instead of your desktop, someone or something changed the default target. This happens after a systemd update or if you ran systemctl set-default multi-user.target by accident.
Quick fix:
- Log in with your username and password.
- Run this command to check the current default target:
You'll probably seesystemctl get-defaultmulti-user.targetinstead ofgraphical.target. - Switch it back:
After you hit Enter, you should see a message like Created symlink .... No error means it worked.sudo systemctl set-default graphical.target - Reboot:
This time the GUI should start.sudo reboot
If the GUI still doesn't appear after reboot, move to the next step.
2. Display Manager Service Won't Start (gdm3, lightdm, sddm)
Your graphical target might be set correctly, but the display manager itself crashed. This is common after a system update or after installing a new desktop environment.
Check which display manager you have:
systemctl status display-manager
You'll see something like gdm3.service (GNOME), lightdm.service (XFCE, Cinnamon), or sddm.service (KDE). If the status shows inactive (dead) or failed, do this:
- Look at the logs to see why it failed:
Look for lines that say failed to start or error. Common reasons: missing config files, permission issues, or a broken Xorg.journalctl -u display-manager -b | tail -50 - Try to start it manually:
If it says Job failed, check the logs again.sudo systemctl start display-manager - If the logs show something like Can't open /dev/dri/card0 or No screens found, your GPU driver is the problem (see step 3).
- Sometimes the fix is reinstalling the display manager. On Ubuntu/Debian:
Replacesudo apt install --reinstall gdm3gdm3with your display manager.
My personal opinion: If you have multiple display managers installed, they sometimes fight. Stick with one. Remove the others with sudo apt remove lightdm sddm (adjust to what you have). Then reinstall your main one.
3. Xorg or NVIDIA Driver Crashed
This is the most annoying one. Your display manager starts, then crashes immediately because Xorg can't talk to your graphics hardware.
How to spot it:
- You see the login screen for a second, then it goes black and kicks you back to the login screen.
- Or you just get a blinking cursor on a black screen.
- Run this to see Xorg errors:
Lines starting with (EE) are errors. Common ones: No devices detected, Failed to load module nvidia.cat /var/log/Xorg.0.log | grep EE
Fix for NVIDIA cards (most common culprit):
- Boot into recovery mode or use Ctrl+Alt+F2 to get a terminal.
- Purge the NVIDIA driver completely:
sudo apt purge nvidia-* - Reinstall the recommended driver:
Or on other distros:sudo ubuntu-drivers autoinstallsudo apt install nvidia-driver-545(check what's current). - Reboot:
sudo reboot
Fix for integrated Intel or AMD graphics:
- Check if the modesetting driver is loaded:
You should seels /usr/lib/xorg/modules/drivers/modesetting_drv.soorintel_drv.so. If not, reinstall xserver-xorg-video-intel or xserver-xorg-video-amdgpu. - Rarely, the kernel mode setting (KMS) breaks. Add
nomodesetto your boot parameters:
Find the linesudo nano /etc/default/grubGRUB_CMDLINE_LINUX_DEFAULTand addnomodesetinside the quotes. Save, then runsudo update-gruband reboot.
One more thing: If you have both an integrated GPU and a discrete NVIDIA card (laptop), the BIOS setting or prime-select can cause this. Run sudo prime-select nvidia or sudo prime-select intel to switch.
Quick-Reference Summary Table
| Symptom | Most Likely Cause | Fix |
|---|---|---|
| Boots to command line only | Default target set to multi-user | systemctl set-default graphical.target then reboot |
| Login screen flashes then goes black | Display manager crashed | Check logs, reinstall display manager, remove extras |
| Black screen with cursor or Xorg errors | GPU driver broken (NVIDIA common) | Purge NVIDIA, reinstall driver, or add nomodeset |
Start with step 1. Most people fix it there. If not, move to step 2, then step 3. Don't skip steps – they build on each other.
Was this solution helpful?