X Window System RHEL

How to install X-server

There are several variants of X servers. First let us look at installing MATE Desktop, and then installing Server with GUI

Installing MATE Desktop on a virtual RHEL 7

Before installing X it is advisable to connect to the virtual machine over ssh, become the superuser and from there run

yum update
yum install -y redhat-lsb-core net-tools epel-release kernel-headers kernel-devel
yum groupinstall -y "Development Tools"

And then the installation itself

yum groupinstall -y "X Window System" "MATE Desktop"

systemctl set-default graphical.target

Removed symlink /etc/systemd/system/default.target. Created symlink from /etc/systemd/system/default.target to /usr/lib/systemd/system/graphical.target.

systemctl isolate graphical.target

After the previous command X should start in the Virtualbox window

Installing GNOME

Or if you want GNOME Desktop

sudo yum groupinstall "GNOME Desktop" "Graphical Administration Tools"

Installing Server with GUI

First of all run yum grouplist to see the list of available variants.

yum grouplist

Loaded plugins: fastestmirror, product-id, search-disabled-repos, subscription-manager There is no installed groups file. Maybe run: yum groups mark convert (see man yum) Determining fastest mirrors * base: rhel.mirror.far.fi * epel: mirror.cspacehostings.com * extras: rhel.mirror.far.fi * updates: rhel.mirror.far.fi Available Environment Groups: Minimal Install Compute Node Infrastructure Server File and Print Server Cinnamon Desktop MATE Desktop Basic Web Server Virtualization Host Server with GUI GNOME Desktop KDE Plasma Workspaces Development and Creative Workstation Available Groups: Cinnamon Compatibility Libraries Console Internet Tools Development Tools Educational Software Electronic Lab Fedora Packager General Purpose Desktop Graphical Administration Tools Haskell LXQt Desktop Legacy UNIX Compatibility MATE Milkymist Scientific Support Security Tools Smart Card Support System Administration Tools System Management TurboGears application framework Xfce Done

sudo yum groupinstall "Server with GUI"

Determine the X type

You can learn a few things about your X with the commands

rpm -qa |grep xorg-x11-server-Xorg
rpm -qa |grep gnome

If you want to check whether GNOME is installed, run

gnome-shell --version

If it is installed, you will see the version

GNOME Shell 3.28.3

If not

-bash: gnome-shell: command not found

How to restart X-server

You can restart X-server (after first switching to the console with Ctrl + Alt + F1) with the command

/etc/init.d/gdm restart

or

/etc/init.d/gdm3 restart

or

/etc/init.d/kdm restart

How to stop the X server

You can stop/start X-server (after first switching to the console with Ctrl + Alt + F1) with the command

/etc/init.d/gdm stop

or

/etc/init.d/gdm3 stop

or

/etc/init.d/kdm stop

If you do not know which X server you have, you can try:

/etc/init.d/gdm stop || /etc/init.d/gdm3 stop || /etc/init.d/kdm stop || /etc/init.d/xdm stop || /etc/init.d/lightdm stop

If that did not help either, try the variants here

or here.

How to start the X server

/etc/init.d/gdm start

or

/etc/init.d/gdm3 start

or

/etc/init.d/kdm start

This works if your X-server is gdm, gdm3 or kdm; if you have something else, just replace it.

Switching from X to the terminal and back

In RHEL by default there are 6 ttys for the console: 1-6, and one for X: 7.

So by pressing Ctrl-Alt[F1-F6] you get to the terminal.

And by pressing Ctrl-Alt-F7 you get to X.

History

X Window System is a windowing system that provides the standard tools and protocols for building a graphical user interface. It is used in UNIX-like operating systems.

X Window System provides the basic functions of a graphical environment: drawing and moving windows on the screen, and interaction with input devices such as, for example, the mouse and the keyboard.

X Window System does not define the details of the user interface; that is the job of window managers, of which many have been developed. For this reason the appearance of programs in the X Window System environment can differ very greatly depending on the capabilities and settings of a particular window manager.

X Window System provides network transparency: graphical applications can run on another machine on the network, while their interface is transmitted over the network and displayed on the user's local machine.

In the context of X Window System the terms “client” and “server” have a meaning unusual for many users: “server” means the user's local display (the display server), while “client” means a program that uses this display (it may run on a remote computer).

The X Window System was developed at the Massachusetts Institute of Technology (MIT) in 1984.

As of February 2016, the protocol version is X11R7.7, which appeared in June 2012.

The X project is led by the X.Org Foundation. The reference (or sample) implementation of the system is freely available under the MIT license and similar licenses.

X Window System is often called X11 or simply X (in colloquial speech, «X»)

Article author: Andrei Olegovich