СHRISTMAS
WHEEL OF FORTUNE

Tap the button and win a guaranteed prize right now!

By registering, you are signing up to receiving e-mails.
MA
Michael Anderson
May 25 2020
Updated August 1 2023

Installing the GNOME GUI on CentOS 7

CentOS

Using another OS?

Select the desired version or distribution.

GNOME is part of the GNU project and is a desktop graphical interface (GUI). It uses the KISS (Keep it simple, stupid) principle and is the standard GUI for many distributions such as Debian, Fedora, Red Hat Enterprise Linux, Kali Linux, etc.

In this article, we will explain how to install the GNOME GUI on the base version of the CentOS 7 operating system. Since this system works in command line mode (CLI), as an example we will use a set of commands for the terminal.

Installation

We assume that you have already installed CentOS (if not already, you can rent VPS with this operating system), and you have root or superuser rights. In this case, we will write commands as the root user. If you are not a root user, just put sudo before all commands.

Step 1 - Upgrade your system

First, we update the system. This is not always required, but doing so is good practice:

yum update

We are waiting for the installation of updates to complete and move on to the next step.

Step 2 - Install GNOME packages

Now we install the GNOME packages. To install them, we will use a command that installs all packages related to the GNOME GUI:

sudo yum -y groups install "GNOME Desktop"

Step 3 - Configure the X Window System

The program that runs the graphical environment on most Linux systems is called the X Window System. So, firstly, you must tell the X Window System that GNOME is the default GUI. To enter this command:

echo "exec gnome-session" >> ~/.xinitrc

Now we have finished installing GNOME and configuring the X Window System. Let's verify this by entering the command:

startx

After running this command, you will see the GNOME GUI, similar to the image below, which means that it works:

82_gnome-centos

Step 4

Now the GNOME GUI is installed and tested. However, to start it, you must enter the command startx every time you start the operating system, which is not very convenient. Let's make it start automatically. To do this, use the following command:

systemctl set-default graphical.target
Vote:
5 out of 5
Аverage rating : 5
Rated by: 3
33145 North Miami, FL 2520 Coral Way apt 2-135
+1 302 425-97-76
700 300
ITGLOBAL.COM CORP
700 300
We use cookies to make your experience on the Serverspace better. By continuing to browse our website, you agree to our
Use of Cookies and Privacy Policy.