Student IT support moved to the DTU Library. Latex support remains in 125D/308

In computing, Secure Shell or SSH is both a computer program and an associated network protocol designed for logging into and executing commands on a networked computer. The designers of SSH aimed to replace the earlier rlogin, TELNET and rsh protocols, and the resultant protocol provides secure encrypted communications between two untrusted hosts over an insecure network. Users of SSH can also use it for tunnelling, forwarding arbitrary TCP ports and X11 connections over the resultant secure channel; and can transfer files using the associated SFTP or SCP protocols. An ssh server, by default, listens on the standard TCP port 22.

SSH login

To use SSH login to the G-bar, use the command


This will give you access to the front-end machine, from where you need to connect to one of the application nodes by means of the command


If you want to make use of X-forwarding, add '-X' to both the ssh and the linuxsh commands.

Please note that you are not supposed to run any application on the front-end machines. In fact, most applications are available on the Linux nodes, only!


SCP utility

Often, you will need to copy your files back and forth between your computer, and the G-Bar. If you are working with a Unix-based system (Mac, Linux etc.), then this can be done using the scp-utility. To copy a file from your computer to the G-Bar:

scp file

And doing it the other is just a matter of reversing the arguments. The path can be specified after : (under UNIX, ~ refers to your home directory). Note that you cannot move files from the G-Bar system when you are logged on the G-Bar to your own computer.

If you are using Windows, you may want to check out WinSCP, which provides a nice graphical user interface for accessing your G-Bar home directory.



SSH tunnelling

Deprecation Notice: Please note that the use of VNC on the G-bar servers is no longer possible. The examples below are kept, however, as tunnelling can be used for other things as well, and VNC is a convenient example.

SSH-tunnelling is an efficient tool for protection of personal data. If you e.g. connect with a VNC client to the server G-Bar login server, the data sent between your computer and will not be encrypted. This means that others may be able to get hold of your password. If you transmit your data through a ssh-tunnel, your data will be save.

Linux and Unix

On Linux and other Unix-like systems (e.g. G-Bar servers) the command ssh can be used. To establish a tunnel, use the command:

ssh -C -L <local port>:<server address>:<server port> <user name>@<server address>

The option -C enables ssh compression. An example:

ssh -C -L

This will log s801234 in to the G-Bar ( is an alias for an appropriate server) and forward the local port 5900 to the server's port 5955.

In another terminal-session, you will then be able to write:

 vncviewer -encodings "hextile copyrect" :0

to connect to the server's vnc-server on port 5955 through your ssh-tunnel. Explanation of the encodings option, see the vnc page.

If you intend to forward priviledged ports (port number < 1024) you have to be root.


On Windows it is recommended to use PuTTY. It is basically the same. To forward local port 5900 to port 5955 of the G-Bar server, do the following:

  1. Start putty.exe
  2. Under Category (left) choose Session.
  3. Write in the field Host Name (or IP address).
  4. Choose SSH as Protocol.
  5. In field Port: 22.
  6. Under Category (left) choose Connection => SSH => Tunnels.
  7. In the fieldSource port write 5900.
  8. In the field Destination write
  9. Click Add.
 10. Click Open. 

If you want to save the settings, you can do that just before you click Open. Do the following:

  1. Under Category (left) choose Session.
  2. Write a name for the settings in the field Saved Sessions.
  3. Click Save. 

Load and save of the settings should be obvious.

You connect your vncviewer to the G-Bar through the SSH-tunnel by doing the following:

  1. Start vncviewwer.exe
  2. Write localhost:0 as server address.
  3. Click Options
  4. Choose Allow CopyRect and Hextile
  5. Click OK and Connect


01 2017
Please note that the IT support office has been moved to the DTU library. Latex support remains in 308.
12 2015
Want to take advantage of the new GitLab service, or perhaps move your existing repos project over? Check out
09 2014
When you log in to your studentmail, remember to use your student number (sXXXXXX) as username.
04 2015
ShareLaTex We now offer ShareLatex, an online mulituser system for making LaTex documents. Check out and