sshfs would be used to any system you can open an ssh connection to. This is the default way to long in to a shell session on a UNIX or Linux system. Right now, this would include SDF, as well as most of my personal systems.
The basic command line is:
sshfs remote-user@remote-hostname:full-remote-path target-directory
You will be prompted for the password associated with the remote user on the remote system. Enter it, and the remote path will be visible locally at the target directory.
sshfs firstname.lastname@example.org:/home/jbleaux ~/foo.com
jbleaux's home directory on
foo.com will be mounted locally in the local user's home directory, under the
foo.com directory locally.
For some local systems, the permissions will not default to the local user, but to a local sysadmin. SDF, for instance, has this quirk. To resolve this, the options
-o idmap=user -o gid=500 will need to be utilized:
You might also have to indicate the
sshfs remote-user@remote-hostname:full-remote-path target-directory -o idmap=user -o gid=500
uidof the local user, in order to mount properly:
This will mount the drive with the owner the same as the local user specified by UID of 501. To find your local UIDs, run
sshfs remote-user@remote-hostname:full-remote-path target-directory -o idmap=user -o uid=501
.ssh/config has entries for the system in it, you can simplify it with just the associated name. For instance, if I have an entry for foo.com like this:
The command can be simplified to:
Host foo HostName foo.com User jbleaux
sshfs foo:/home/jbleaux ~/foo.com
fusermount -u target-directory
So, to unmount our example:
fusermount -u ~/foo.com
Conventions for Remote Storage Guides.
Return to Reference Index