You can easily mount remote server file system or your own home directory using special sshfs and fuse tools.

FUSE – Filesystem in Userspace

FUSE is a Linux kernel module also available for FreeBSD, OpenSolaris and Mac OS X that allows non-privileged users to create their own file systems without the need to write any kernel code. This is achieved by running the file system code in user space, while the FUSE module only provides a “bridge” to the actual kernel interfaces. FUSE was officially merged into the mainstream Linux kernel tree in kernel version 2.6.14.

You need to use SSHFS to access to a remote filesystem through SSH or even you can use Gmail account to store files.

Following instructions are tested on CentOS, Fedora Core and RHEL 4/5 only. But instructions should work with any other Linux distro without a problem.

Step # 1: Download and Install FUSE

Visit fuse home page and download latest source code tar ball. Use wget command to download fuse package:
# wget
Untar source code:
# tar -zxvf fuse-2.6.5.tar.gz
Compile and Install fuse:
# cd fuse-2.6.5
# ./configure
# make
# make install

Step # 2: Configure Fuse shared libraries loading

You need to configure dynamic linker run time bindings using ldconfig command so that sshfs command can load shared libraries such as
# vi /etc/
Append following path:
Run ldconfig:
# ldconfig

Step # 3: Install sshfs

Now fuse is loaded and ready to use. Now you need sshfs to access and mount file system using ssh. Visit sshfs home page and download latest source code tar ball. Use wget command to download fuse package:
# wget
Untar source code:
# tar -zxvf sshfs-fuse-1.7.tar.gz
Compile and Install fuse:
# cd sshfs-fuse-1.7
# ./configure
# make
# make install

Mounting your remote filesystem

Now you have working setup, all you need to do is mount a filesystem under Linux. First create a mount point:
# mkdir /mnt/remote
Now mount a remote server filesystem using sshfs command:
# sshfs /mnt/remote

  • sshfs : SSHFS is a command name
  • – vivek is ssh username and is my remote ssh server.
  • /mnt/remote : a local mount point

When promoted supply vivek (ssh user) password. Make sure you replace username and hostname as per your requirements.

Now you can access your filesystem securely using Internet or your LAN/WAN:
# cd /mnt/remote
# ls
# cp -a /ftpdata . &

To unmount file system just type:
# fusermount -u /mnt/remote
# umount /mnt/remote

Further readings:

🥺 Was this helpful? Please add a comment to show your appreciation or feedback.

nixCrat Tux Pixel Penguin
Hi! 🤠
I'm Vivek Gite, and I write about Linux, macOS, Unix, IT, programming, infosec, and open source. Subscribe to my RSS feed or email newsletter for updates.

19 comments… add one
  • Ritesh Raj Sarraf May 10, 2007 @ 17:50

    I didn’t know that RedHat/CentOS didn’t include Fuse/SSHFS.

    In Debian, we do things simply as:
    `apt-get install sshfs fuse-utils`

    sshfs host:/mount/point /mount/point


  • Devin May 10, 2007 @ 21:21

    Another option is to install fuse RPMs via the ATrpms repository:

    Then you can install the fuse-sshfs RPM from Fedora Core 6:

  • Komi May 14, 2007 @ 14:23

    sshfs is nice, but I experienced problems when working with cvs on a mounted filesystem over sshfs. CVS just refused to work with something like “unable to get working directory” or something similar.

  • Justin Jun 19, 2007 @ 0:17

    what is the recommended way for this to operate in true user (aka w/o root permissions) or autofs type mode? I’d rather not suid fusermount

  • venkatakrishnan.p Jan 23, 2008 @ 4:15

    it is very good but i want more detail to configure
    in redhat 5 edition ……………

  • 🛡️ Vivek Gite (Author and Admin) nixCraft Jan 23, 2008 @ 6:39


    This is more than sufficient to install and use the sshfs. Do you have any problem?

  • taco Jan 21, 2009 @ 15:49

    I am unable to read the files from an apache cgi script. That’d be great if I could… If I run the script via ssh, I can read the mounted files. If I run the script via a web browser, it’s a no go.

  • durba Jul 31, 2009 @ 18:16

    This is really helpful. But I cant view the files of my mounted directory unless I log in as root. How can I get rid of this problem? Any help will be appreciated

    • Schwarzes Tigerle Apr 7, 2013 @ 14:04

      append the following string:
      -o allow_other -o idmap=user

      badly it seems the sshfs works a little like mounting a fat filesystem:
      the filesystem is accessed as the user who’s mountet the filesystem…
      so if root mounts the filesystem, an ordinary user can manipulate the files with superuser rights.
      Hopefully i’am wrong, otherwise the sshfs seems a bit useless for me….

  • domidc Nov 20, 2009 @ 8:57

    At step 3 when execute ./configure I get this error:
    configure: error: Package requirements (fuse >= 2.2 glib-2.0) were not met.
    Consider adjusting the PKG_CONFIG_PATH environment variable if you
    installed software in a non-standard prefix.
    Somehow the dynamic linking failed. Anybody knows how to solve this?

    • Balamurugan May 5, 2011 @ 11:10


      Even I faced the same problem. Downloading “glib-2.0” and installing it would do the needful. Mail to me if you need some detailed explanation.


  • Muralidharan Jul 25, 2010 @ 2:25

    Hi all

    after installing fuse and sshfs , when i try to mount the fs from remote system using

    sshfs uname@server : /location mountpoint

    i get the error as the fuse module is not loaded.

    can any one help me out please?


  • Dislo Aasi Aug 15, 2010 @ 4:42

    I kept on running into problems with missing packages. Specifically missing glib and gthread. The command that fixed it for me on RHEL 5 was:

    yum install glib2-devel

  • தங்கமணிஅருண் Apr 21, 2011 @ 6:18

    on ubuntu 10.04

    # sudo apt-get install sshfs fuse-utils

    then go head to mounting the same.


  • jalal hajigholamali Jul 13, 2011 @ 16:33

    really helpful

  • tez Aug 27, 2012 @ 13:04

    Appreciate for recipe.

  • Gilbert Arias Feb 24, 2013 @ 0:14

    hey..!! any help ?

    im getting this error while trying to mount the remote directory

    fuse: failed to open /dev/fuse: Permission denied

    • Schwarzes Tigerle Apr 7, 2013 @ 13:39

      you must mount the directory as SuperUser e.g. root

      or Bad Idea: change the permision of /dev/fuse to r/w for every one….

  • Baptiste Jul 8, 2013 @ 1:33

    Wow, I never knew about the fusermount command. Umount requires root privileges to unmount sshfs, even when you’ve mounted your remote file system as a user and in your home directory. Fusermount works! but during all these years I didn’t know it existed.

    Gilbert Arias, Schwarzes Tigerle : this is solved by adding your user to the “fuse” group.

Leave a Reply

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

Use HTML <pre>...</pre> for code samples. Your comment will appear only after approval by the site admin.