Skip to content

Instantly share code, notes, and snippets.

@Friedjof
Last active May 9, 2023 17:21
Show Gist options
  • Save Friedjof/97e68c643b09c429e2b5aebb48373def to your computer and use it in GitHub Desktop.
Save Friedjof/97e68c643b09c429e2b5aebb48373def to your computer and use it in GitHub Desktop.

How to mount TUM Rechnerhalle using SSHFS

Installation

Ubuntu/Debian:

sudo apt-get install sshfs

CentOS/RHEL:

sudo yum install sshfs

Usage

with ssh key:

sudo sshfs -o allow_other,IdentityFile=/home/<local-name>/.ssh/id_rsa <rgb-name>@halle.in.tum.de:/u/halle/<rgb-name>/home_at /mnt/halle

How to generate a ssh key

with password:

sudo sshfs -o allow_other <rgb-name>@halle.in.tum.de:/u/halle/<rgb-name>/home_at /mnt/halle

Now you can access the folder /u/halle/<rgb-name>/home via /mnt/halle on your local machine. You can also change the mount point /mnt/halle to any other folder you like.

cd /mnt/halle
ls -al

Unmount

sudo umount /mnt/halle

Tips

*See also Sources for more information about Windows and MacOS.

Alias

Short the command with alias and add it to ~/.bashrc:

alias mount-tum='sudo sshfs -o allow_other,IdentityFile=/home/<local-name>/.ssh/id_rsa <rgb-name>@halle.in.tum.de:/u/halle/<rgb-name>/home_at /mnt/halle'
alias umount-tum='sudo umount /mnt/halle'

Now you can mount/unmount the folder with mount-tum and umount-tum respectively.

Automount (may slow down the booting process)

Add the following line to /etc/fstab to mount the folder automatically at startup:

<rgb-name>@halle.in.tum.de:/u/halle/<rgb-name>/home_at /mnt/halle fuse.sshfs allow_other,_netdev,user,idmap=user,transform_symlinks,identityfile=/home/<local-name>/.ssh/id_rsa 0 0

Android

For Android you can use Dateimanager to access the Rechnerhalle on your phone. Download the App and select Remote -> + -> SFTP and fill in the following information:

  • Host: halle.in.tum.de
  • Port: 22
  • Username: <rgb-name>
  • Password: <rgb-password>

Alternatively you can use a ssh key instead of the password (select more for this option).

Sources

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment