Using SSHFS

You can mount a directory on the HPC as a file system on our own PC via SSHFS if you have an SSH login.

On a Linux Client

On Linux clients just install fuse-sshfs (if Centos) or sshfs (if Debian). Then you can do this:

$ sshfs hpc_ip_address:/shared/homes/your_home/some_directory  /home/your_local_home/some_directory

where:
hpc_ip_address is the IP address that you use to login to the cluster,
/shared/homes/your_home/some_directory is a directory under your home directory on the HPC and,
/home/your_local_home/some_directory is any location on your PC where you want your HPC home to be mounted. This needs to be an empty directory.

After you run this command the directory /home/your_local_home/some_directory should show the contents of /shared/homes/your_home/some_directory on the HPC. You don’t need to mount your entire home directory, it’s best to just mount the directory that you require access to.

When you have finished working on your files you should “unmount” the directory. Otherwise when you shutdown your PC you could get corrupted files.

To unmount the filesystem do this:

$ fusermount -u /home/your_local_home/some_directory

Note: For those using Ubuntu Linux you might need to use sudo to run the sshfs command and you might need to add yourself to the “fuse” group.

On a Windows Client

These instructions are for a Windows 10, 64-bit. You may need to contact IT support to install this software if you do not have install rights on your machine.

Download and install the latest stable installer of WinFSP from here: https://github.com/billziss-gh/winfsp/releases
Download and install the latest stable installer of SSHFS-Win from here: https://github.com/billziss-gh/sshfs-win/releases (You will want the 64-bit installer.)

After these are installed you can setup the SSHFS connection as described below.

Open File Explorer, right-click on “This PC” and choose “Map Network Drive”.
In the Drive field, choose a drive letter that is not already mapped. Already mapped drives will have a location shown after the drive letter.
In the Folder field enter \\sshfs\your_id@the_hpc_ip_address\some_directory.

where some_directory is the directory under your home directory you wish to mount. If it’s /shared/homes/XXXX/mydata just enter mydata.

Map drive

Do not select “Reconnect at sign-in”. You should only mount your HPC home directory when you need to. It should be “disconected” when you no longer need to access it. Click Finish.

It will then ask for your login credentials. It’s best not to enable “Remember me”.

Login

Finally when you have finished your work you should “disconnect” your mapped drive from the HPC. From File Explorer, right click the mounted drive and select “Disconnect”.

Disconnect

On an OSX Client

See the site “What is FUSE for macOS?” at https://osxfuse.github.io/ From that site you will need to download the latest stable releases of “FUSE for macOS” and the “SSHFS” module.

Create a folder on your Mac to use as a mount point.

In Terminal, run a command similar to the following to access your directory on the remote system and mount it at the local folder you created:

$ sshfs your_uts_id@hpc_ip_address:/path_to_your_hpc_directory /path_to_your_local_mount_point

When you have finished your work you should un-mount the directory.

Note: These instructions for the Mac have not been tested.

This is custom footer