Recommended Terminal SetupΒΆ
Before configuring your ~/.ssh/config file, ensure that you have completed the First Time Login process and set your new cluster password. SSH connections using this configuration will not succeed until your temporary password has been replaced.
-
In a new local terminal run;
mkdir -p ~/.ssh/socketsthis will create a subdirectory in your home directory to store socket configurations. -
Open your ssh config file (e.g.
nano ~/.ssh/configto open with the text editornano) and add the following
Make sure to replace username with your BMRC Username in all four places
Host *
ControlMaster auto
ControlPath ~/.ssh/sockets/ssh_mux_%h_%p_%r
ControlPersist 1
Host bmrc1
User username
hostname cluster1.bmrc.ox.ac.uk
ForwardAgent yes
ForwardX11Trusted yes
ControlMaster auto
ControlPath ~/.ssh/sockets/ssh-socket-%r-%h-%p
ControlPersist 24h
ServerAliveInterval 300
ServerAliveCountMax 2
Host bmrc2
User username
hostname cluster2.bmrc.ox.ac.uk
ForwardAgent yes
ForwardX11Trusted yes
ControlMaster auto
ControlPath ~/.ssh/sockets/ssh-socket-%r-%h-%p
ControlPersist 24h
ServerAliveInterval 300
ServerAliveCountMax 2
Host bmrc3
User username
hostname cluster3.bmrc.ox.ac.uk
ForwardAgent yes
ForwardX11Trusted yes
ControlMaster auto
ControlPath ~/.ssh/sockets/ssh-socket-%r-%h-%p
ControlPersist 24h
ServerAliveInterval 300
ServerAliveCountMax 2
Host bmrc4
User username
hostname cluster4.bmrc.ox.ac.uk
ForwardAgent yes
ForwardX11Trusted yes
ControlMaster auto
ControlPath ~/.ssh/sockets/ssh-socket-%r-%h-%p
ControlPersist 24h
ServerAliveInterval 300
ServerAliveCountMax 2
bmrc4 , bmrc2, etc. For an example, if you wanto to connec to cluster4.bmrc.ox.ac.uk which is bmrc4, execute