How to mount a remote directory in Linux using sshfs
Tutorials Shared by the Internet Community
Total Hits - 27430
Total Votes - 103 votes
Vote Up - 45 votes
Vote Down - 58 votes
Domain - www.linuxnix.com
Category - Linux/Administration
Submitted By - Surendra Anne
Submitted on - 2013-09-17 13:14:41
A. The answer to this is yes, We can share data/mount folder on a local machine by using just SSH protocol. This can be done by using FUSE(Filesystem in USErspace) which support SSH and FTP file systems. This post is in response to conversation which I had with one our users two days back. the question he asked about ftp is “I want to transfer one latest file from my ftp server and I want to automate this task through shell script to download latest file from my FTP server, And I don’t know what is the Operating System at server end(This is ultimate sentence I hear from the user today in my office :) )“. Let’s prepare our machine on how to mount a remote folder by using SSH protocol.
Step1: Installing Package
apt-get install sshfs
rpm -ivh fuse-sshfs-1.8-1.el5.rf.i386.rpm
Step2: Once the package is installed we have to create a mount point and mount our server data using sshfs command, for which we require username/password. Here are my details for this task.
My Username: root
My password: redhat
My Server: 10.233.10.212
My mount point: /mnt/ssh
Now create the mount point and mount SSH account data. ...