Install XWindows (Graphical mode) in Linux

 

If you recently installed linux (CentOS/Fedora/RedHat) with text mode and now want to use its Graphical GUI which was left unchecked during the installation, you can install it from Internet very easily.

If you are not already root, switch users to the root account:

install the X Window System and a graphical desktop environment. For example, to install the GNOME desktop environment, use this command

1yum groupinstall "X Window System" "Desktop"

That will install necessary files for XWindows and default Desktop (GNome), for install KDE as desktop environment type:

1yum groupinstall "X Window System" "KDE Desktop"

OR if you want to install Sound/Video Applets to be install, type this:

1yum groupinstall "X Window System" '"Desktop" "Sound and Video"

This step may take some time as your Fedora/CentOS system downloads and installs additional software. You may be asked to provide the installation media depending on your original installation source.

But if you think GUI is already installed, check by typing:

Now if your system is showing text mode when boot even you have XWindows Installed, you can change login preference from :

1vi /etc/inittab

By default it will show 3 for text mode like this

1id:3:initdefault:

Change it to 5:

01# Default runlevel. The runlevels used by RHS are:
02#   0 - halt (Do NOT set initdefault to this)
03#   1 - Single user mode
04#   2 - Multiuser, without NFS (The same as 3, if you do not have networking)
05#   3 - Full multiuser mode
06#   4 - unused
07#   5 - X11
08#   6 - reboot (Do NOT set initdefault to this)
09#
10id:5:initdefault: