== Graphical Login (VNC) [[PageOutline]] The availability of remote visualization, either implemented within visualization applications themselves, or through server software, eliminates the need for off-site file transfers and allows HPC users to run a broad range of visualization tools in-place on the supercomputer where the data resides. \\ === Remote Visualization - Technical Details {{{#!table style="border:none; text-align:left; margin:0px" {{{#!th align=left,style="border: none" [[Image(https://upload.wikimedia.org/wikipedia/commons/thumb/6/67/X11transport.png/600px-X11transport.png, 200px, align=left, margin=10, link=wiki:remote3d)]] }}} {{{#!th align=left,style="border: none" The availability of remote visualization, either implemented within visualization applications themselves, or through server software, eliminates the need for off-site file transfers and allows HPC users to run a broad range of visualization tools in-place on the supercomputer where the data resides. \\ \\ [wiki:remote3d more...] }}} }}} == Remote rendering using VNC and !VisIt Remote rendering is also possible using the Virtual Network Computing (VNC, e.g. [http://www.tigervnc.org TigerVNC] or [http://www.turbovnc.org/ TurboVNC]) package. VNC follows a very general approach, where a remote desktop on one node of the remote cluster is opened. On the users workstation only a lightwise VNC client (viewer) has to be installed. The image of the remote desktop is send from the cluster to the viewer on the fly. The user can work with this desktop in the usual way, just by interacting with keyboard and mouse. This is a very convenient way to work on a remote machine, not only for data visualisation. Whenever an OpenGL capable visualisation software, like !VisIt, is started on the remote node, OpenGL commands must be redirected to the GPU of this node with the help of [http://www.virtualgl.org/ VirtualGL] (command: vglrun). This way the hardware accelerated rendering capabilities of a cluster node can be exploit for remote rendering into a VNC window. A general overview about this topic is given [wiki:remote3d here].\\ [[Image(Trac_Setup_VNC.png, 640px)]]\\ The following steps are necessary to start a VNC session for remote rendering with !VisIt on JURECA. Please notice that the VNC server is only availble on vis nodes! === 1. Create a VNC password and a startup script on JURECA This step is a prerequisite for using VNC and has only to be done '''once'''. The aim of this step is to create a VNC password and a very small (one line) VNC startup script to start the [http://www.xfce.org/?lang=en Xfce] desktop environment. As all VNC related commands are ony available on a vis node, one has to allocate a vis node first and then start an interactive shell and execute the necessary commands there. It works as follows:\\ {{{ #!sh salloc -N 1 -p vis --gres=gpu:2 srun --cpu_bind=none -n 1 --pty /bin/bash -i mkdir .vnc # if not already exist cd .vnc vncpasswd # now type in your vnc password echo "exec startxfce4" > xstartup exit # exit task exit # exit job }}} === 2. Login to JURECA and start the VNC server on a vis node Open an ssh shell on a login node of JURECA the usual way. To allocate a vis node with 512 GByte main memory for one hour, use: {{{ #!ShellExample salloc -N 1 -p vis --gres=mem512,gpu:2 --start-xserver --time=1:00:00 srun -n 1 --cpu_bind=none --gres=gpu:0 vncserver -fg -geometry 1920x1080 }}} Alternatively you may want to allocate a vis node with 1024 GByte main memory by: {{{ #!ShellExample salloc -N 1 -p vis --gres=mem1024,gpu:2 --start-xserver --time=1:00:00 srun -n 1 --cpu_bind=none --gres=gpu:0 vncserver -fg -geometry 1920x1080 }}} The default wallclock time is 1 hour, the maximum is 24 hours.\\ In case the VNC server could successfully be started, you will get an output like: {{{ #!ShellExample New 'jrc1391:1 (zilken)' desktop is jrc1391:1 Starting applications specified in /homeb/zam/zilken/.vnc/xstartup Log file is /homeb/zam/zilken/.vnc/jrc1391:1.log }}} As you have to setup an ssh tunnel (with the correct network port) to the allocated node in step 3, two important informations have to be taken from this output: 1. The allocated node is '''jrc1391''' 1. The number of the VNC display is ''':1''' It is very important to know that the network port of the VNC server depends on this display number. The actual port number is 5900+display_number, therefore port '''5901''' must be tunneled in this case. === 3. Open an ssh tunnel Now you have to open an ssh tunnel from your workstation to this node. The steps to be done depend strongly on your operating system and your setup.\\ '''Linux:'''\\ If your operating system is Linux, just use: {{{ #!ShellExample ssh -4 -N -L 5901:jrc1391:5901 jureca.fz-juelich.de }}} '''Windows:'''\\ In case your operating system is Windows, the setup of the tunnel depends on your ssh client. Here a short overview on how-to setup a tunnel with [http://www.putty.org/ PuTTY] is given. It is assumed that PuTTY is already configured in a way that a general ssh connection to JURECA is possible, that means that host name, username and the private ssh key are correctly set. To establish the ssh tunnel, enter the "SSH-->tunnels" tab in the PuTTY configuration window. You have to enter the source port (in this case 5901) and the destination (in this case jrc1391:5901) and than press add:\\ [[Image(putty2.jpg)]]\\ After pressing add, the tunnel should appear in the list of forwarded ports and you can establish the tunnel by pressing the open button:\\ [[Image(putty3.jpg)]]\\ === 4. Connect to the VNC server If you are using Linux, a vncviewer typically is already part of the distribution or can be installed from a repository. For Windows, a VNC viewer can be downloaded for example [http://sourceforge.net/projects/turbovnc/files/ here].\\ Start your local VNC client and connect to localhost:1, e.g.: {{{ #!ShellExample vncviewer localhost:1 }}} After typing in your vnc password, you will have access to the remote desktop. ---- any feedback welcomed - [mailto:h.zilken@fz.juelich.de], [mailto:j.goebbert@fz-juelich.de]