- Infos im HLRS Wiki sind nicht rechtsverbindlich und ohne Gewähr -
- Information contained in the HLRS Wiki is not legally binding and HLRS is not responsible for any damages that might result from its use -

Graphic Environment: Difference between revisions

From HLRS Platforms
Jump to navigationJump to search
 
(27 intermediate revisions by 6 users not shown)
Line 1: Line 1:
For graphical pre- and post-processing purposes there is 1 visualisation nodes installed in the Nehalem cluster. The node is equipped with a nVIDIA Quadro 5800 FX and has 8 GB memory. Access to the nodes is possible by using the node feature vis.
For graphical pre- and post-processing purposes some visualisation nodes have been integrated into the Vulcan cluster.  
<pre>
<pre>
user@cl3fr1>qsub -I -lnodes=1:vis
user@cl5fr2>qsub -I -l select=1:node_type=visamd -q vis
</pre>
</pre>


Line 8: Line 8:


== VNC Setup ==
== VNC Setup ==
If you want to use the Nehalem Graphic Hardware e.g. for graphical pre- and post-processing, on way to do it is via a vnc-connection.
If you want to use the vulcan Graphic Hardware e.g. for graphical pre- and post-processing, on way to do it is via a vnc-connection. For that purpose you have to download/install a VNC viewer to/on your local machine.  


==== Linux ====
E.g. TurboVNC comes as a pre-compiled package which can be downloaded from [https://sourceforge.net/projects/turbovnc/ https://sourceforge.net/projects/turbovnc/]. For Fedora 13 the package tigervnc is available via yum installer.
For that purpose you have to install TurboVNC on your local machine. TurboVNC comes as a pre-compiled package which can be downloaded from [http://www.virtualgl.org/Downloads/TurboVNC  http://www.virtualgl.org/Downloads/TurboVNC].
 
Other VNC viewers can also be used but we recommend the usage of TurboVNC, an accelerated version of TightVNC
designed for video and 3D applications, since we run the TurboVNC server on the visualisation nodes and  the combination of the two components will give the best performance for GL applications.


==== Preparation of Nehalem Cluster ====
==== Preparation of vulcan Cluster ====
Before using vnc for the first time you have to log on to the Nehalem frontend and run
Before using vnc for the first time you have to log on to the Nehalem frontend and run
<pre>vncpasswd</pre>
<pre>vncpasswd</pre>
Line 23: Line 25:


<pre>
<pre>
user@client>ssh cl3fr1.hww.de
user@client>ssh cl1fr3.hww.hlrs.de
</pre>
 
Then load the VirtualGL module to setup the VNC environment and launch the VNC startscript.
<pre>
user@eslogin001>module load VirtualGL
user@eslogin001>vis_via_vnc.sh
</pre>
</pre>


Then load the VirtualGL module to setup the TurboVNC environment and start the TurboVNC server.
This will set up a default VNC session with one hour walltime running a TurboVNC server with a resolution of 1240x900.
To control the configuration of the VNC session the vis_via_vnc.sh script has three '''optional''' parameters.
 
<pre>
<pre>
user@cl3fr1>module load tools/VirtualGL
vis_via_vnc.sh [walltime] [geometry] [x0vnc]
user@cl3fr1>vis_via_vnc.sh XX:XX:XX
</pre>
</pre>
Where XX:XX:XX is the required walltime for your visualisation job.
 
where walltime can be specified in format hh:mm:ss or only hh.
 
The geometry option sets the resolution of the Xvnc server launched by the TurboVNC session and has to be given in format 1234x1234.
 
If x0vnc is specified instead of a TurboVNC server with own Xvnc Display a X0-VNC server is started. As its name says this server is directly connected to the :0.0 Display which is contoled by an X-Server always running on the visualisation nodes. A session started with this option will have a maximum resolution of 1152x864 pixels which can not be changed.
 
There is also a -help option which returns the explanation of the parameters and gives examples for script usage.


The vis_via_vnc.sh script returns the name of the node reserved for you, a display number and the IP-address.
The vis_via_vnc.sh script returns the name of the node reserved for you, a display number and the IP-address.


==== VNC viewer with -via option ====
If you got a VNC viewer which supports the via option like TurboVNC or TigerVNC you can simply call the viewer
If you got a VNC viewer which supports the via option like TurboVNC or TigerVNC you can simply call the viewer
like stated below
like stated below
<pre>
<pre>
user@client>vncviewer -via cl3fr1.hww.de <node name>:<Display#>
user@client>vncviewer -via cl1fr3.hww.hlrs.de <node name>:<Display#>
</pre>
</pre>


If you got a VNC viewer without support of the vis option you have to setup a ssh tunnel via the frontend first and
==== VNC viewer without -via option ====
then launch the VNC viewer with a connection to localhost
If you got a VNC viewer without support of the vis option, like JavaVNC or TightVNC for Windows, you have to setup a ssh tunnel via the frontend first and then launch the VNC viewer with a connection to localhost
<pre>
<pre>
user@client>ssh -N -L10000:<IP-address of vis-node>:5901 &
user@client>ssh -N -L10000:<IP-address of vis-node>:5901 &
Line 48: Line 65:
</pre>
</pre>


Enter the vnc password you set on the frontend and you should get a Gnome session running in your VNC viewer. To execute 64Bit GL Applications within this session you have to open a shell and again load the VirtualGL module to set the VirtualGL environment and then start the application with the VirtualGL wrapper command
Enter the vnc password you set on the frontend and you should get a Gnome session running in your VNC viewer.


==== GL applications within the VNC session with TurboVNC ====
To execute 64Bit GL Applications within this session you have to open a shell and again load the VirtualGL module to set the VirtualGL environment and then start the application with the VirtualGL wrapper command
<pre>
<pre>
vglrun <Application command>
vglrun <Application command>
Line 55: Line 74:


[[Image:vgl_in_vnc_session.png]]
[[Image:vgl_in_vnc_session.png]]
==== GL applications within the VNC session with X0-VNC ====
Since the X0-VNC server is directly reading the frame buffer of the visualisation node's graphic card, GL applications can be directly executed within the VNC session without using any wrapping command.


==== Ending the vnc session ====
==== Ending the vnc session ====


If the vnc session isn't needed any more the TurboVNC server should be shut down with
If the vnc session isn't needed any more and the requested walltime isn't expired already you should kill your queue job with
 
<pre>
user@cl1fr3>qdel [Job ID]
</pre>
 
==== Usage under Windows ====
 
VNC viewers for Windows often do not support the '-via' option to tunnel via SSH. In this manual tunneling is required, which can be done using the PLink tool which comes with the [[http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html|Putty] distribution.


Open a command prompt window and run PLink with the options
<pre>
<pre>
user@n150701>module load tools/VirtualGL
plink.exe -N -L 10000:<IP-address of vis-node>:5901
user@n150701>vncserver -kill :<Display#>
</pre>
</pre>
The you can need to start your VNC client and connect to the address localhost:10000.


== VirtualGL Setup (WITHOUT turbovnc) ==
== VirtualGL Setup (WITHOUT turbovnc) ==
Line 70: Line 101:


==== Linux ====
==== Linux ====
After the installation of VirtualGL you can connect to cl3fr1.hww.de via the vglconnect command
After the installation of VirtualGL you can connect to cl3fr1.hww.de via the vglconnect command. Please be aware that vglconnect uses the nettest binary on the remote side to determine a free port for  the VGL connection. Since on the hww machines, VGL is installed in a non standard path one has either to use the -bindir option or set the environment variable VGL_BINDIR on the client side to the correct directory. I.e. to connect to the vulcan front-ends please use the following commands:
<pre>
<pre>
user@client>vglconnect -s cl3fr1.hww.de
user@client>export VGL_BINDIR=/opt/hlrs/non-spack/2022-02/vis/VirtualGL/2.6.5/bin
user@client>vglconnect -s cl1fr3.hww.hlrs.de
</pre>
</pre>
Then connect to the visualisation node n150701 via the vglconnect command
To prepare the visualisation queue job use the vis_via_vnc.sh script that is made available via the VirtualGL module.
<pre>
user@cl3fr1>module load VirtualGL
user@cl3fr1>vis_via_vnc.sh XX:XX:XX
</pre>
where XX:XX:XX is the walltime required for your visualisation job.
 
Once the job is running and the node is set up, the job-id as well as the node name are printed in front of the instructions on how to connect via vnc. To be able to connect to the reserved visualization node directly it is necessary to export the environment variable PBS_JOBID to the job-id of the corresponding queue job. I.e.:
<pre>
<pre>
user@cl3fr1>module load tools/VirtualGL
export PBS_JOBID=<job.no>.cl1intern
user@cl3fr1>vglconnect -s n150701
user@cl3fr1>vglconnect -s n<node.no>
</pre>
</pre>


Line 83: Line 122:


<pre>
<pre>
user@n150701>module load tools/VirtualGL
user@vis-node>module load VirtualGL
user@cl3fr1>vglrun <Application command>
user@vis-node>vglrun <Application command>
</pre>
</pre>

Latest revision as of 12:33, 1 August 2023

For graphical pre- and post-processing purposes some visualisation nodes have been integrated into the Vulcan cluster.

user@cl5fr2>qsub -I -l select=1:node_type=visamd -q vis

To use the graphic hardware for remote rendering there are currently two ways tested. The first is via TurboVNC the second one is directly via VirtualGL.

VNC Setup

If you want to use the vulcan Graphic Hardware e.g. for graphical pre- and post-processing, on way to do it is via a vnc-connection. For that purpose you have to download/install a VNC viewer to/on your local machine.

E.g. TurboVNC comes as a pre-compiled package which can be downloaded from https://sourceforge.net/projects/turbovnc/. For Fedora 13 the package tigervnc is available via yum installer.

Other VNC viewers can also be used but we recommend the usage of TurboVNC, an accelerated version of TightVNC designed for video and 3D applications, since we run the TurboVNC server on the visualisation nodes and the combination of the two components will give the best performance for GL applications.

Preparation of vulcan Cluster

Before using vnc for the first time you have to log on to the Nehalem frontend and run

vncpasswd

which creates you a .vnc directory in your home containing a passwd file.

Starting the TurboVNC server

To start a TurboVNC server you simply have to login to the cluster frontend cl3fr1.hww.de via ssh.

user@client>ssh cl1fr3.hww.hlrs.de

Then load the VirtualGL module to setup the VNC environment and launch the VNC startscript.

user@eslogin001>module load VirtualGL
user@eslogin001>vis_via_vnc.sh

This will set up a default VNC session with one hour walltime running a TurboVNC server with a resolution of 1240x900. To control the configuration of the VNC session the vis_via_vnc.sh script has three optional parameters.

vis_via_vnc.sh [walltime] [geometry] [x0vnc]

where walltime can be specified in format hh:mm:ss or only hh.

The geometry option sets the resolution of the Xvnc server launched by the TurboVNC session and has to be given in format 1234x1234.

If x0vnc is specified instead of a TurboVNC server with own Xvnc Display a X0-VNC server is started. As its name says this server is directly connected to the :0.0 Display which is contoled by an X-Server always running on the visualisation nodes. A session started with this option will have a maximum resolution of 1152x864 pixels which can not be changed.

There is also a -help option which returns the explanation of the parameters and gives examples for script usage.

The vis_via_vnc.sh script returns the name of the node reserved for you, a display number and the IP-address.

VNC viewer with -via option

If you got a VNC viewer which supports the via option like TurboVNC or TigerVNC you can simply call the viewer like stated below

user@client>vncviewer -via cl1fr3.hww.hlrs.de <node name>:<Display#>

VNC viewer without -via option

If you got a VNC viewer without support of the vis option, like JavaVNC or TightVNC for Windows, you have to setup a ssh tunnel via the frontend first and then launch the VNC viewer with a connection to localhost

user@client>ssh -N -L10000:<IP-address of vis-node>:5901 &
user@client>vncviewer localhost:10000

Enter the vnc password you set on the frontend and you should get a Gnome session running in your VNC viewer.

GL applications within the VNC session with TurboVNC

To execute 64Bit GL Applications within this session you have to open a shell and again load the VirtualGL module to set the VirtualGL environment and then start the application with the VirtualGL wrapper command

vglrun <Application command>

Vgl in vnc session.png

GL applications within the VNC session with X0-VNC

Since the X0-VNC server is directly reading the frame buffer of the visualisation node's graphic card, GL applications can be directly executed within the VNC session without using any wrapping command.

Ending the vnc session

If the vnc session isn't needed any more and the requested walltime isn't expired already you should kill your queue job with

user@cl1fr3>qdel [Job ID]

Usage under Windows

VNC viewers for Windows often do not support the '-via' option to tunnel via SSH. In this manual tunneling is required, which can be done using the PLink tool which comes with the [[1] distribution.

Open a command prompt window and run PLink with the options

plink.exe -N -L 10000:<IP-address of vis-node>:5901

The you can need to start your VNC client and connect to the address localhost:10000.

VirtualGL Setup (WITHOUT turbovnc)

To use VirtualGL you have to install it on your local client. It is available in the form of pre-compiled packages at http://www.virtualgl.org/Downloads/VirtualGL.

Linux

After the installation of VirtualGL you can connect to cl3fr1.hww.de via the vglconnect command. Please be aware that vglconnect uses the nettest binary on the remote side to determine a free port for the VGL connection. Since on the hww machines, VGL is installed in a non standard path one has either to use the -bindir option or set the environment variable VGL_BINDIR on the client side to the correct directory. I.e. to connect to the vulcan front-ends please use the following commands:

user@client>export VGL_BINDIR=/opt/hlrs/non-spack/2022-02/vis/VirtualGL/2.6.5/bin
user@client>vglconnect -s cl1fr3.hww.hlrs.de

To prepare the visualisation queue job use the vis_via_vnc.sh script that is made available via the VirtualGL module.

user@cl3fr1>module load VirtualGL
user@cl3fr1>vis_via_vnc.sh XX:XX:XX

where XX:XX:XX is the walltime required for your visualisation job.

Once the job is running and the node is set up, the job-id as well as the node name are printed in front of the instructions on how to connect via vnc. To be able to connect to the reserved visualization node directly it is necessary to export the environment variable PBS_JOBID to the job-id of the corresponding queue job. I.e.:

export PBS_JOBID=<job.no>.cl1intern
user@cl3fr1>vglconnect -s n<node.no>

On the visualisation node you can then execute 64Bit GL applications with the VirtualGL wrapper command

user@vis-node>module load VirtualGL
user@vis-node>vglrun <Application command>