sshfs
sshfs
sshfs lets you mount a remote filesystem using SSH.
I usually use sshfs to mount my phone onto my PC (I temporarily run an SSH server on phone using Termux).
Why I use sshfs
- It’s better than scp/rsync for sharing files, in my opinion.
- You could even mount filesystems from startup by default using
/etc/fstab.
Caveats
- Since it uses FUSE, it can be a bit slow at times.
- If the SSH connection drops, sshfs can hang and you’d have to unmount. But that happens rarely, at least to me.
Mounting
sshfs -p 8022 user@example.com:/home/user mnt/Here, we mount the remote user’s home directory to a directory named mnt/ in our machine.
NB: -p lets you connect to a different SSH port, in case you’re not using the standard port 22 for SSH.
Unmounting
Unmounting is as easy as:
fusermount -u mnt/