SSH is a program that allows you to log in to and run programs on a remote server. It is used in the School of Computer Science to allow access to our Linux Servers from your own computer, where you can edit, compile, and run code for your labs and assignments. SSH comes in two part - the client and the server.
The SSH Server: The ssh server is a piece of software that runs on a remote computer and listens for connections from the SSH client.
The SSH Client: The SSH client runs on your own machine and allows you to connect to the server.
To use SSH to connect to SoCS Servers, you must have an SSH Client installed. SSH is available for the most common operating systems: Windows, MacOS, and Linux.
A built in client is available on Windows, and can be accessed by opening the Windows Powershell application.
To check if ssh is installed, Open Windows Powershell, and type “ssh” followed by enter. You should see the following:
This client should be available by default, but if it is missing, follow the instructions in the Install SSH on Windows section.
The SSH client comes automatically installed as part of Mac OS. To access the ssh client, open the Terminal application, then type “ssh” followed by enter. You should see the following:
The SSH client is usually installed on most Linux distributions. To check that it is installed, open your Terminal application, then type “ssh” followed by enter. You should see the following:
The commands to use SSH are the same from all operating systems. In general, the ssh command is ssh <username>@<hostname>.socs.uoguelph.ca
, where <username> is your Central Login ID and <hostname> is the name of the server you wish to connect to (i.e. linux, portkey).
The following are examples of commands to connect to the Schools “linux.socs” servers. While the prompts look slightly different, the behaviour is identical.
SSH connections from off campus are restricted by the campus firewall.
apt-get install openssh-client
yum -y install openssh-clients
After entering the ssh command there is a blinking cursor with no response, or the following error
ssh: connect to host linux.socs.uoguelph.ca port 22: Operation timed out
If you are connecting from off campus, the most likely issue is that you are trying to connect to linux.socs.uoguelph.ca without the VPN. You should ensure you have followed the directions to install and run the Campus VPN.
Every time you enter your password, you receive the following error:
Permission denied, please try again.
The most likely cause is that you are not specifying your username when trying to connect. If you type ssh linux.socs.uoguelph.ca
as your command, it will automatically use your computer's user account name as the username. Make sure you specify your username with ssh username@linux.socs.uoguelph.ca
.