Skip to content

Accessing the login node (ssh)

On this Page

  • How to generate an SSH key and register it with OnDemand
  • How to SSH through a terminal
  • How to SSH with OnDemand

Use of the login node should be limited to 'lightweight' tasks such as file browsing/copying/moving or submitting jobs into the SLURM scheduler.

You can access the Research Cluster login node remotely through the two below mechanisms.

Instead of typing your password every time you connect, you can register an SSH public key with OnDemand and use key-based authentication to log in to the login node from a terminal. This is faster and required for some tools (e.g. rsync, scp, VS Code Remote-SSH) that don't handle interactive password prompts well.

Step 1: Generate an SSH key pair

If you already have an SSH key pair (typically ~/.ssh/id_ed25519.pub or ~/.ssh/id_rsa.pub on Mac/Linux), you can skip to Step 2.

Windows 10/11 ship with an OpenSSH client. Open PowerShell and run:

ssh-keygen -t ed25519 -C "your.name@otago.ac.nz"

Press Enter to accept the default file location (C:\Users\<you>\.ssh\id_ed25519), then set (or skip) a passphrase.

Using PuTTY instead

If you use PuTTY rather than the built-in OpenSSH client, run PuTTYgen, click Generate, and save the private key. Copy the public key text shown in the box at the top of the window — you'll need it in Step 2.

Open a terminal and run:

ssh-keygen -t ed25519 -C "your.name@otago.ac.nz"

Press Enter to accept the default file location (~/.ssh/id_ed25519), then set (or skip) a passphrase.

No ed25519 support?

If your system or client doesn't support ed25519 keys, use ssh-keygen -t rsa -b 4096 instead.

Step 2: Copy your public key

You need the contents of the public key file — never share your private key (the file without the .pub extension).

Get-Content $env:USERPROFILE\.ssh\id_ed25519.pub | Set-Clipboard

This copies the key straight to your clipboard.

pbcopy < ~/.ssh/id_ed25519.pub
cat ~/.ssh/id_ed25519.pub

Select and copy the full output (it starts with ssh-ed25519 and ends with the comment you set).

Step 3: Add the key in OnDemand

  1. Log in to OnDemand at https://ondemand.otago.ac.nz.
  2. From the top navigation bar, select Clusters > SSH Public Key.

    Clusters menu showing SSH Public Key
    Figure 1: Clusters menu showing SSH Public Key

  3. On the SSH Public Key Manager page, paste your public key (the full line, e.g. ssh-ed25519 AAAA... your.name@otago.ac.nz) into the Public key box and click Add.

    SSH Public Key Manager page
    Figure 2: SSH Public Key Manager page

  4. Your key will now appear under Registered Public Keys.

Step 4: Connect using your key

Once your key is registered, SSH to the login node as normal — if your private key is in the default location, no extra flags are needed:

ssh <otago-username>@aoraki-login.otago.ac.nz

You should connect without being prompted for your password. If you saved your key to a non-default location, specify it with -i:

ssh -i /path/to/your/private_key <otago-username>@aoraki-login.otago.ac.nz

SSH through a terminal

Open a terminal and use the ssh command with your Otago username:

Terminal

ssh <otago-username>@aoraki-login.otago.ac.nz
<otago-username>@aoraki-login.otago.ac.nz's password:

First time connecting

The first time you ssh from a computer you will likely see output extremely similar to:

Terminal

The authenticity of host 'aoraki-login.otago.ac.nz (X.X.X.X)' can't be established.
ED25519 key fingerprint is SHA256:WXAGQmlR5C7rvCOiSSL8PtiuxytA368rjozXXO0NckE.
This key is not known by any other names.
Are you sure you want to continue connecting (yes/no/[fingerprint])?

Warning

Double check the fingerprint matches one of the following:

(RSA) SHA256:pzUx1abRS35sbM9n/3OqMpGiF9zegvlG4jQrr78cGFg
(ECDSA) SHA256:g/BKtsqcMchX7l7YRqDJ98azAumTxzQT0hCCCgVIKxc
(ED25519) SHA256:WXAGQmlR5C7rvCOiSSL8PtiuxytA368rjozXXO0NckE

Type 'yes' and Enter, where you will then be prompted for your password (or need to re-ssh) depending on your ssh client.

Password not showing

When typing in your password when prompted, nothing will be displayed on the screen. Once you have typed your password, press Enter to submit and continue. If you mistyped your password you will be prompted to re-enter it.

SSH within OnDemand

To use the cluster shell access within OnDemand, first connect to the Otago OnDemand web portal and then from the top menu bar select the menu Clusters > Aoraki Cluster Shell Access.

You will then be prompted to input your password, similar to SSH through the terminal.

Open OnDemand Shell
Figure 3: Open OnDemand Shell