Setting up FUSE under Debian

Setting up FUSE under Debian


Filesystem in Userspace (FUSE) is a technology that allows programs operating in userspace to be mounted in the same way as filesystems based in the kernel can be. This allows a userspace program to interface to all sorts of services, or create completely virtual filesystems through a generic interface back to the kernel. Filesystems currently available via FUSE are listed on their wiki: FUSE wiki: FileSystems. I've used FUSE to mount remote directories over SSH so that they're presented on the local filesystem.

Preparing the kernel module

FUSE requires a generic kernel module which userspace applications can interface to (via libfuse). On Debian, this is easily built using module-assistant in a few quick steps:

  1. sudo apt-get install module-assistant fuse-utils
  2. sudo module-assistant
  3. Select Prepare to download the kernel source and build tools required
  4. Select Select, scroll down to 'fuse', tick it and select Ok
  5. Select Get to download the source package
  6. Select Build to compile the module and agree to install it
  7. sudo modprobe fuse

Using sshfs to mount SSH filesystems

Install the sshfs package and then use it to mount the remote directory:

  1. sudo apt-get install sshfs
  2. sshfs user@remotehost:/directory /local/mount/point

You can then browse, edit and work as if the files were local from within the local mount point.

Useful links

Debian Administration - Storing files off-site with gmail

- using the gmailfs program (via FUSE) to mount a remote gmail mailbox

-- Dominic