Difference between revisions of "SSH/SFTP"

From radwiki
Jump to navigation Jump to search
m
Line 9: Line 9:
 
To connect with SSH or SFTP, you need to use a client program.  
 
To connect with SSH or SFTP, you need to use a client program.  
  
{{Note| '''X11 vs VNC:'''<br></br>
+
{{Note| '''Remote desktop options: X11 vs VNC:'''<br></br>
 
  X forwarding sends a single application window, typically without compression or network optimization. VNC sends the entire desktop and is optimized for networked usage, such as persisting after an accidental disconnect. The former uses the default port range 6000+N, the latter 5900+N.|reminder}}
 
  X forwarding sends a single application window, typically without compression or network optimization. VNC sends the entire desktop and is optimized for networked usage, such as persisting after an accidental disconnect. The former uses the default port range 6000+N, the latter 5900+N.|reminder}}
  

Revision as of 11:05, 23 May 2020

Shell access is arguably the most important feature of the GPU cluster, as it allows researchers to run their code, e.g. using the anaconda environment.

SSH allows commandline access to the connected server.

SFTP allows file transfers. They normally also include an SSH terminal feature.

In addition, remote desktop solutions such as VNC or X forwarding typically depend on shell (SSH tunnel) access.

To connect with SSH or SFTP, you need to use a client program.

Remote desktop options: X11 vs VNC:

X forwarding sends a single application window, typically without compression or network optimization. VNC sends the entire desktop and is optimized for networked usage, such as persisting after an accidental disconnect. The former uses the default port range 6000+N, the latter 5900+N.

Windows Clients

  • Modern powershell or PuTTy are some of the many clients available for SSH
  • WinSCP or Filezilla are typical SFTP clients.
  • realVNC is a known VNC client
  • Xming is a known X server/client

Input your user ID, password and server IP address as appropriate.

SSH Port forwarding (tunneling)

In simple terms, you first setup a tunnel running in the background, e.g. a minimized PuTTy terminal. After that your main application (e.g. browser, git client, VNC/X11 client) talks to a localhost port instead of directly addressing an external address/port; the SSH connection transparently forwards that data.

The syntax in powershell or bash is: ssh -L local_port:remote_address:remote_port username@server.com You can then leave that tunnel open in the background, traffic targeting localport will move through it. This will be the recommended method for connecting (including Jupyter Notebooks) once the firewalls are hardened.

See also