X-Windows
The HPC resources provided are not meant for extensive visualization tasks. Nevertheless, there are a number of scenarios where you would want to look at some data quickly without having to move it somewhere else. You may want to do this with tools such as Gnuplot to graphical debuggers like LinaroForge. Whenever you start a tool with a graphical user interface (GUI) on a Unix/Linux machine it will want to open an X11 window to display information.
X11 or X-Windows is a client-server infrastructure where a client displays information send to it from a server. In actual fact it is a little bit more complicated than that. Here we focus on the scenario where you view information on your local machine but this information comes from an application on a remote machine, as shown in the diagram below.
flowchart LR
XWindow["`Local X Window`"]
XServer["`Local X Server`"]
XApp["`Remote X Application`"]
XWindow <--> XServer <--> XApp
The Local X Window is the window that is displayed on your screen. The Local X Server is
the X Windows server that runs on your local machine that manages the windows displayed on
your screen. It also communicates with applications that want to display information.
The case of interest here is an X windows application running on a remote machine,
indicated with Remote X Application here.
The key message here is that if you want to run an X windows application on a remote machine and display it on your local screen you need to have an X windows server installed. Dependent on your machine there are different solutions available.
Linux - X-windows is it’s native graphical user interface platform, just make sure X11 is installed, for example by trying to run
Xorg -version. If it is installed you’ll get some output starting with something likeX.Org X Server 1.21.1.6, if it is not installed the operating system will respond withXorg: command not found.Windows - you will need to install an X-Window server, common options are Cygwin/X[1] or Xming[2]
MacOS - also here you will need to install an X-Window server, a common option is XQuartz[3]
Once you have an X-Windows server up and running you can login on a Linux
machine and try to open an X-Windows application. A key thing at this point is
the DISPLAY environment variable. This variable tells the X-Windows
application on which screen to open it’s display. The X-Windows server on your
local machine will define and set this variable. Commonly you would have ssh
forward this variable to remote machines so it knows how to find the screen of
your local machine.
How to forward the DISPLAY setting to a remote machine is explained in the
section Access with SSH.