Connect to HPCs
The IP addresses of the HPCs are:
HPC | IP address/Host name |
---|---|
DGX | 146.95.214.135 |
DLS | 146.95.128.169 |
Dragon | csgpu01.hunter.cuny.edu |
All of the machines are inside the network of Hunter College (Hunter network).
1. Inside the Hunter Network
You can use ssh
via a computer inside the Hunter network to access it:
2. Outside the Hunter Network
If you want to access the HPCs outside the Hunter network, you can use the following two ways:
2.1. SSH with Username and Password
Use
ssh
to connect to eniac from anywhere using your eniac account:(Note: To apply for a new eniac account or reset your password, just send an email to cstechsp@hunter.cuny.edu with your Hunter email address)
After connecting to eniac, use
ssh
to connect to the HPCs:
2.2. SSH with SSH Key Pair (Recommended)
This way is more secure than the first one and you don't need to type your password every time. You will still need an eniac account.
Create your own SSH keys
MacOS/Linux:
Hit enter to keep the default settings all the way until the key pair is successfully created.
Windows: Windows now supports OpenSSH. If
ssh
command does not work, you should be able to install it following the instructions here: OpenSSH in Windows. The following protocols are based on OpenSSH. You should also be able to do it with PuTTY, but it is not recommended.Copy your public key to eniac and HPCs
After generating the SSH key pair, you should get two files in your local
.ssh
directory:id_rsa
andid_rsa.pub
.id_rsa
is your private key, you should keep it only to yourself. Theid_rsa.pub
file is the public key file. We need to copy it to eniac and HPCs so we do not need to type password every time. The command to copy yourid_rsa.pub
to another computer is:The copying will ask for your password. You need to copy your public key to eniac first and connect to eniac with
ssh
, copy the same key to HPCs again. Now you should be able to connect to eniac withwithout being asked for passwords.
Set up the SSH config file
Setting up an SSH config file will let you connect to HPCs from your local machine with only one line of command without complex URLs or IP addresses. First, you need to create a file named
config
in your local.ssh
folder. In the file, put the following example contents:The first code block defines a proxy host. In our case, it is the eniac server. The second and third code blocks are for DGX and DLS, respectively. In the case of Windows, if the ProxyCommand causes errors, you can try to replace the
ssh
with the full path tossh.exe
file. For example, in my case, the ProxyCommand is:ServerAliveInterval variable lets your terminal send an empty package to the server every x seconds to keep your connection alive. With the config file, you should be able to connect to HPCs simply with:
or
You should also be able to use
scp
command below:
Last updated