Skip to main content



To generate an SSH key pair:

[..]$ ssh-keygen -f ~/.ssh/id_name -t rsa -b 4096

Here the key pair is named "id_name" as an example.


It is OK to leave the passphrase empty when prompted (i.e. no password). Be aware that if you choose a password your SSH-key based access may not work with SFTP software like FileZilla.

The public part of the key is found here "~/.ssh/", and it is easiest to view the content like this

[..]$ cat ~/.ssh/

Copy the content and send it to the admins.

After the public key has been uploaded to the login node by the admin, you can log into the system like this

[..]$ ssh <uname>
# or if you are juggling many SSH keys
[..]$ ssh -i ~/.ssh/id_name <uname>

Your terminal window should display a login message, followed by a command line like this:

[<uname>@elja-ihpc ~]$

For quick access it is recommended to make an "alias" in the "~/.bashrc" of your local machine:

[..]$ cat >> ~/.bashrc << EOF
> alias elja="ssh -i ~/.ssh/id_name <uname>

After sourcing the "~/.bashrc" you can log in like this:

[..]$ elja

Alternatively you can add a config file to your .ssh directory

[..]$ touch ~/.ssh/config
[..]$ chmod 600 ~/.ssh/config

then add information about Elja to the config file

[..]$ cat >> ~/.ssh/config << EOF
> Host Elja
> HostName
> User <uname>
> Port 22
> IdentityFile ~/.ssh/id_elja

You can now log in via

[..]$ ssh Elja

These instruction will not work for Windows command prompt.