Skip to main content

Guide: How to SSH/VNC for UCSD

By October 18, 2013Guides

SSH

The first step is to SSH into UCSD. How to SSH?

For Windows, click here to download PuTTY. Scroll down to Binaries and you have three options to pick:

  • PuTTY: putty.exe (You can just open this application and it’ll run.)
  • Zip file: putty.zip (This will have all the extra commands for SSH if you need it)
  • Installer: putty-*-installer.exe (Recommended* This will install everything in your Program Files directory and have a Start Menu shortcut.)

After installing, open PuTTY and you should see this:

Putty Session

On the Host Name box, enter as in the example below but replace XXX with one of the ACMS lab servers here.

Putty Hostname

The numbering usually starts at 240 and up but depending how many people are currently using that server, it might be a better idea to pick a different server to login.

You can also put in your login username like below so that you won’t need to put in your username each time when you log into SSH.

Putty Hostname Login

To save these settings, type in a name under Saved Sessions and click Save.

Putty Session Save

After clicking Save, click Open and you now will get to SSH into the school’s linux server.

If this is your first time using SSH into the server, you should get the warning similar to the one below. Just click Yes and it should be fine.

Putty SSH Warning

After clicking Yes, you should be prompted for a password (or username first if you didn’t put your user login in the beginning of the hostname). This should be the same password as your UCSD account.

Putty SSH PW

After clicking enter, you should be logged in or have to re-try your password again if you put in the wrong one. You should have something similar to below after clicking spaces.

Putty SSH Logged

Here’s some simple useful commands to use:

    • Shows the current directory the SSH shell is in
pwd
    • Lists all files in the current directory
ls .
    • Move to another directory within the SSH shell (you can move you the previous directory or even a folder within the previous directory)
cd .<br />cd ../<br />cd ../some_folder_name/
    • Create a folder within the directory
mkdir some_folder_name
    • Copies a file
cp some_file.name newfile.name
    • Moves a file (or a directory and all it’s contents)
mv some_file.name<br />mv some_folder_name/
    • Removes a file (add -R to remove a directory and all it’s contents)
rm some_file.name<br />rm -R some_folder_name/

More commands can be found here.

VNC

First you should download VNC Viewer from here.

For VNC, you should start back in the PuTTY configuration and enter everything from before for the Host Name or click Load to get back the saved settings

SSH Load

On the left sidebar, click and expand SSH. Next select Tunnels.

SSH categorySSH Category Tunnels

Here set the Source Port to “5900” and Destination to “localhost:5900”. Then click Add.

SSH Tunnels

Next click on X11 on the the left sidebar and check Enable X11 Forwarding.

SSH X11

Now you can go back to Session on the left sidebar and then click Save for your session to save this configuration. Then log into the SSH shell and enter:

vncgnome

This will initialize a vncgnome session for you. If you have any errors, try the following to kill or restart vncgnome:

vncgnome -kill<br />vncgnome -restart

Next open VNC Viewer and set VNC Server to “localhost:0”.

If you’re getting a License Key error, you should go to “Enter VNC Server License Key” in the Start Menu and go through the license system .

If you are getting a loop with your Windows, then you need to turn off the VNC Server by going to “VNC Server” in the Start Menu. Click More and Stop VNC Server.

SSH VNC Stop

After all that and setting to “localhost:0”, click Connect. You might get a popup stating that it is an unencrypted connection. Just click Continue and you’re in the vncgnome!

SSH VNC Unencrypted

SSH-VNC-load

This might be dated after a while if UCSD ACMS changes some stuff.

%d bloggers like this: