Skip to content

Commit

Permalink
Add ssh config info
Browse files Browse the repository at this point in the history
  • Loading branch information
s-sajid-ali committed Aug 26, 2024
1 parent 67e8c17 commit 8ff3dfe
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions _episodes/11-connecting.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,48 @@ Even if your cluster does not require it, the next section will guide you
through the use of SSH keys and an SSH agent to both strengthen your security
_and_ make it more convenient to log in to remote systems.

## Setting up the ssh configuration file

The Greene cluster has multiple login nodes (`log-1`, `log-2`, `log-3`) any of which
can be assigned as the login node. This can sometimes lead to the following warning:
```
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
```
{: .language-bash}

To avoid this error, open the file ``~/.ssh/config` on your computer and place the
following lines in it:
```
Host greene.hpc.nyu.edu dtn.hpc.nyu.edu
StrictHostKeyChecking no
ServerAliveInterval 60
ForwardAgent yes
StrictHostKeyChecking no
UserKnownHostsFile /dev/null
LogLevel ERROR
```
{: .language-bash}

Additionally, some people may experience connection warnings while connecting to Greene,
and connections being terminated too soon.This can be addressed by entering the
following into ``~/.ssh/config` file:
```
# Increase alive interval
host *.hpc.nyu.edu
ServerAliveInterval 60
ForwardAgent yes
StrictHostKeyChecking no
UserKnownHostsFile /dev/null
LogLevel ERROR
```
{: .language-bash}

## Log In to the Cluster

If you are connecting from a remote location that is not on the NYU network (your home
Expand Down

0 comments on commit 8ff3dfe

Please sign in to comment.