sshfs




(adsbygoogle = window.adsbygoogle || []).push({});

sshfs (SSH Filesystem) is a filesystem client based on FUSE, userspace filesystem for linux. If a client can ssh to a host (server), sshfs can be use to mount a remote directory. Client system requirement is FUSE version 2.2 or higher.

sshfs configuration:

### Host ###
1. On the host or server side, verify ssh is installed and running.

There’s nothing to setup in the host if ssh is running.

# service sshd status
openssh-daemon (pid 1410) is running…

### Client ###
2. From the client side, verify it can ssh to the host:
$ ssh username@hostname

3. Install the latest stable of glib2 and fuse.
In CentOS, RHEL, Fedora, or Oracle Linux:
# yum install glib2.x86_64 fuse.x86_64

4. sshfs is provided in Centos, RHEL, or Fedora repo.
Install sshfs, fuse-sshfs.x86_64, from the repo:
# yum install fuse-sshfs.x86_64

To mount sshfs:
mount remote directory to local directory
# sshfs username@hostname:/remote_Directory /mountpoint

Example:
# sshfs root@confignotes.com:/var/www/html ~/temp

To unmount sshfs:
# fusermount –u /mountpoint

Add a user to fuse group:
# usermod -a -G fuse user_name

Change the permission of fusermount to execute by a regular user:
# chmod +x /bin/fusermount

#####

If sshfs is not available from a repo, download it from:

http://sourceforge.net/projects/fuse/files/sshfs-fuse/2.4/

Latest stable version: sshfs-fuse-2.4.tar.gz

Extract the file in your home directory:
$ tar -xvf sshfs-fuse-2.4.tar.gz

As root, cd in the sshfs-fuse-2.4 directory to configure and compile:
# cd sshfs-fuse-2.4
# ./configure
# make
# make install

Source:
http://fuse.sourceforge.net/sshfs.html


Published by

Ferdy Mañago

Portland, Oregon