ISO27001:2013
Certified Supplier

FIND OUT MORE

We're an ISO27001:2013 Certified Supplier

blog-post-featured-image

The sshfs utility is a FUSE (“Filesystem in Userspace”) program that allows you to mount a directory from a remote system locally, assuming you have ssh access to the remote system. The command format is:

$ sshfs user@remote-system local-mountpoint options

There are lots of options, but the one that is almost always worth using is -C, which enables compression on the ssh link.

Mounting

Here is it in action:

$ mkdir workpc
$ sshfs kae@myworkpc.tiger-computing.co.uk: workpc -C

At this point, you can edit / copy / generally work on files under workpc as if they were local files.

Unmounting

A minor gotcha is that simply using umount won’t work:

$ umount workpc
umount: workpc: Permission denied

Non-privileged users are not permitted to unmount filesystems by default. However, because sshfs is a FUSE filesystem, we can unmount it with fusermount:

$ fusermount -u workpc

Was This Linux Tip Useful?

Let us know in the comments below.

 

Leave a Reply

Your email address will not be published. Required fields are marked *