wlanboy

tutorials and ruby scripts

Read my tutorials

Tutorial

Tutorial: using sshfs

Use sshfs to mount a remote path through ssh:

  1. Create folder and add sshfs link

    mkdir ~/my-folder
    sshfs [email protected]:/foldertomount/ ~/my-folder
    
  2. Mount external folder

    fusermount -u ~/my-folder
    
  3. Add reconnect options

    sshfs -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=3 [email protected]:/foldertomount/ ~/my-folder

    • Allow reconnects
    • Check remote server every 15 seconds
    • Allow up to 3 failed checks
  4. Identify the disk by “lable” and copy the “uuid”.

  5. Add ssh key for automatic login

    sshfs -o IdentityFile=~/.ssh/myprivatekey