How to: Mount a SFTP Folder (SSH + FTP) on Ubuntu Linux using SSHFS & Fuse
Purpose: to mount a remote directory on my local Ubuntu Linux Desktop system using SFTP (which is SSH in an FTP-like fashion).
The goal is to easily gain access to a remote system’s files through another folder on my desktop. Debina/Ubuntu allows you to easily mount SSH folders via the GUI, however, these mounts won’t show up in the terminal (and in some programs).
sshfs to accomplish this.
Ubuntu’s SSHFS documentation here.
Sshfs and mount
- add your username to the
fuse
group.- On Ubuntu, you would open a terminal window and perform the following:
[crayon-680d545f1f3f1244029786/]
- SFTP server. I created a folder on my desktop called
sftp
. - Once the folder has been created, simply run
sshfs
using the appropriate login information (host username and IP), the host and local directories, and the SFTP connection is mounted on a folder on my desktop.
[crayon-680d545f1f3fc286237500/]
possible errors and workarounds
[crayon-680d545f1f3ff784552272/]
Create a bash alias to save time and typing
-
[crayon-680d545f1f401175446455/]
unmount
[crayon-680d545f1f404093723901/]