Norwegian version of this page

Using a Linux VM via SSH

Connecting via SSH

SSH on Windows

1. Open Putty

2. Go to "Sessions". Fill in the name of the VM you want to connect to in the "Host Name" window. Port is by default set to 22. Leave this as is.

3. An SSH tunnel is opened to the VM. Log in with UiO username and password.

SSH on Mac

1. Open Terminal.

2. Enter the command <ssh username@vm-name>.  Ex. testuser@vdi-test-999.uio.no

3. Enter your UiO password.

SSH on Linux

1. Open Terminal.

2. Enter the command <ssh username@vm-name>.  Ex. testuser@vdi-test-999.uio.no

3. Enter your UiO password.

X11 forwarding

X11 forwarding lets the SSH session open applications as graphical windows on your machine.

Step-by-step on Windows

1. In UiO machines the application X-WIN32 can be downloaded from Software Center. No configuration is required.

2. In Putty go to "Connection" -> "SSH" -> "X11" and tick the box marked "Enable X11 forwarding"

3. After this you can connect to your VM via SSH and start graphical applications.

4. When opening for example MATLAB a box from X-WIN32 will appear. It asks if you want to allow the connection. Click "Always".

5. The graphical application opens in its own window.

Step-by-step on Mac

1. Start the application XQuartz. This is installed on UIO machines.

2. Click on XQuartz in the upper left-hand corner and choose "Preferences".

3. Go to "Windows" and tick the box "Click-through Inactive Windows". This lets you click the buttons in applications you start.

4. In XQuartz choose "Applications" -> "Terminal".

5. Run the command: ssh -X username@linux-vm

6. You are now able to run graphical applications via SSH. They will open in their own window.

Ending the session

If you close the window the session will disconnect and you have to reconnect and log in.

Sertificates

Usually the SSH session asks if you want to allow the sertificate from the server. Here you have to click yes to open the SSH session.

Basic Linux commands

A guide for using the terminal is here (Norwegian)

Published June 12, 2019 3:29 PM - Last modified June 14, 2019 10:29 AM