Excerpt |
---|
Unlike personal computers running operating systems such as Windows, MacOS or Ubuntu, our systems do not provide a graphical windowing environment. Nevertheless, some of the tools provided on Pawsey systems do have Graphical User Interfaces (GUIs). GUI applications on Pawsey supercomputers are typically based on the the X Window System (external site), also known as X11 or simply shortened to X. Typical examples of these applications are debuggers and profilers. Here we explain how to use the X X11 forwarding option of SSH to view and control these applications remotely. |
...
Section | ||||||
---|---|---|---|---|---|---|
|
Preliminaries
Although X can be used remotely without SSH, it is insecure and blocked by most firewalls. SSH X X11 forwarding fixes both these issues and also automatically sets automatically the DISPLAY environment variable.
...
Even when running with a GUI, use compute nodes for memory-intensive or cpu-intensive operations
Preparation for macOS
Current macOS operating systems do not have the X windows system. Mac users should install the XQuartz (external site) package to use SSH with X X11 forwarding.
After the installation, users may also need to indicate the path where the xauth program is. To do so, users must edit the ~/.ssh/config
file and add the path under The Host *
entry, as shown in listing 1.
Column | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||
|
...
Enabling SSH X11 Forwarding
For Linux, macOS and Windows (MobaXterm), the user opens a local terminal window and executes ssh
with the X forwarding option -X
.
$ ssh -X <username>@<hostname><remotehost>
Some sites recommend using the -Y
flag instead. While this can fix some compatibility issues, the -X
flag is more secure.
The user can test this option by running the xclock
command, that shows an analogical clock with the current time, on the remote host. This is shown in terminal 2.
...
Within the terminal shell on the remote host (eg, Setonix), you can check to see that the DISPLAY
Environment Variable has been set for you, by typing
Code Block | ||
---|---|---|
| bash | |
theme | DJango | |
title | Terminal 2. Execute xclock for X. | |
$ ssh -X <username>@setonix.pawsey.org.au
##############################################################################
# Pawsey Supercomputing Centre #
# Empowering cutting-edge research for Australia's future #
# #
# This service is for authorised clients only. #
# It is a criminal offence to: #
# - Obtain access to data without permission #
# - Damage, delete, alter or insert data without permission #
# #
##############################################################################
.
.
.
===============================================================================
<username>@setonix:~> xclock |
The graphical clock running on the supercomputer should be displayed as shown in figure 1.
Figure 1. xclock running as an example of X applications.
Improved Performance
...
| |
username@setonix> echo $DISPLAY
localhost:34.0
username@setonix> |
NOTE: The first number in the output may be different
You should now be able to invoke your graphical application, and have any windows it opens appear on you local desktop.
Improved Performance
X11 forwarding over SSH does not perform well over long distances. The user can try to improve performance over long distances with SSH compression. This can be activated by using the -C
option in the ssh
command line:
...
Column | ||
---|---|---|
|
Related pages
...