• Health tips to prevent the spread of COVID-19:
    • Wash your hands frequently;
    • Maintain 2 meters social distancing;
    • Minimise outdoor activities.
    Stay safe in your bubble!

How to disable (or enable) GUI on boot in Ubuntu 21.04 (Hirsute Hippo) (works on all systemd Linux)

Andy

Administrator
User ID
1
Joined
7 Jan 2019
Messages
254
Reaction score
8
Points
18
The following article will show you how to disable the GUI on boot in Ubuntu 21.04 (Hirsute Hippo) Desktop Linux

Areas covered:
  • How to disable GUI on boot
  • How to enable GUI on boot
  • How to start GUI from the console
  1. The following command will disable GUI on boot, and therefore upon the system reboot, the system will boot into multi-user target (default normal Linux console):
    Bash:
    $ sudo systemctl set-default multi-user
  2. Logout from the X-session or simply reboot your system to exit the GUI.
    Bash:
    $ gnome-session-quit
To enable back the GUI to start on boot:
Bash:
$ sudo systemctl set-default graphical
To start the GUI manually from the console:
Bash:
$ startx
For GNOME GUI installations using GDM as the default display manager, you can start GUI from a command line by executing the command below:
Bash:
$ sudo systemctl start gdm3
 
 Short URL:
Top