NIKOLA Computing User Documentation
Home
User Docs and FAQ
FAQ
Tutorials
About NIKOLA
Links

VNC Overview

VNC connections are not directly allowed from offsite. This means that in order to connect to a running VNC server from outside of the EE building, one has to tunnel the connection over ssh. This can be accomplished on any platform.

Please remember to shutdown any VNC servers when you are done using them. You may use the command:

vncserver -kill :display#

The Scenario

You need to start a simulation using a tool like Cadence or ADS, which both start graphical interfaces. There is no way to close the window sometimes without stopping the simulation. So, you need to start this process and access it later from a remote site to check on its progress.

The Process

First, you should start a vncserver on the machine on which the simulation/program will be run. For example, if machine1 is to be used, you would ssh to machine1 and start a new vncserver by issuing the commands:

$ ssh machine1
machine1$ vncserver

At this point, a server will have been started on machine1. The information will be printed to STDOUT, indicating the user, server, and display port in the form:

New 'machine1:1 (joeuser)' desktop is machine1:1
Starting applications specified in /homes/joeuser/.vnc/xstartup
Log file is /homes/joeuser/.vnc/machine1:1.log

This means that a vncserver has been created on display 1 of machine1.

Fast forward...you have gone home, it has been a few hours, and you want to check your simulation. If you are using Windows, you will need a good ssh client (I recommend puTTY) and a vnc viewer (for that, I would recommend RealVNC Viewer- the free edition). Generally, the process includes creating an ssh session that tunnels the vnc port from the server to your workstation, then starting a vncviewer session.

One note before continuing: by default, vncserver starts on the next available display and listens on a corresponding 59xx port, starting at 5900 (for display 0). In the working example, the server is created using display 1, meaning the server will listen on port 5901.

Linux/Unix

To create the ssh tunnel, you would issue the command (in a terminal):

$ ssh -L 5901:localhost:5901 machine1.ee.washington.edu

This means that everything from machine1, port 5901, will be forwarded to the local machine, on the same port. Then, the you can simply open a secure vncviewer session using the command:

$ vncviewer localhost:5901

This will open the ssh-tunneled vncserver session. Note, that if the vncserver was opened on a different display, one would have to replace all the 1's with that number.

Windows

First, download puTTY and RealVNC viewer, free edition.

Open PuTTY and, under the "SSH" category, choose "Tunnels". Add a new tunnel by putting the appropriate port (like 5901) in "source port." Then, in the box for "Destination" type:

localhost:5901

Be sure to replace 5901 with the appropriate port number. Click "Add" to add this tunnel.

Next, open an ssh session with the remote host by clicking on "Sessions" and opening a default session with the remote host. Next, open RealVNC and connect to

localhost:5901

where 5901 should be replaced by port to which the vnc display is being forwarded. This will open the vnc session.

For further details see: