I'm trying to mount a remote disk using SSHFS that is not directly accessible, i.e. I need to use a proxy, like local -> proxy -> remote. I'm using only key-based auth for both. The following command works:
sshfs -o IdentityFile='[PATH_TO_KEY_FOR_REMOTE]' -o ProxyCommand='ssh -q -i [PATH_TO_KEY_FOR_PROXY] -W %h:%p [PROXY_USER]@[PROXY]' [REMOTE_USER]@[REMOTE]:[SOURCE] [DESTINATION] Unfortunately, I can't get this to work as an entry in /etc/fstab; the current one is:
[REMOTE_USER]@[REMOTE]:[SOURCE] [DESTINATION] fuse.sshfs delay_connect,rw,noauto,_netdev,reconnect,ProxyCommand='ssh -q -i [PATH_TO_KEY_FOR_REMOTE] -W %h:%p [PROXY_USER]@[PROXY]',ServerAliveInterval=15,ServerAliveCountMax=3,IdentityFile=[PATH_TO_KEY_FOR_REMOTE]' 0 0 but when running mount [DESTINATION], I get an error:
mount: /etc/fstab: parse error at line X -- ignored I've tried replacing ProxyCommand with ProxyJump, like so:
[REMOTE_USER]@[REMOTE]:[SOURCE] [DESTINATION] fuse.sshfs delay_connect,rw,noauto,_netdev,reconnect,ProxyJump=[PROXY_USER]@[PROXY],ServerAliveInterval=15,ServerAliveCountMax=3,IdentityFile=[PATH_TO_KEY_FOR_REMOTE]' 0 0 This works for the command-line version, and mount [DESTINATION] doesn't report errors, but I keep getting Input/output error when trying to access it.
On the other hand, the below works when using mount [DESTINATION] (and if the key file for the proxy has been added to the SSH agent), but I'm still getting a prompt for the password (for the proxy) if mounting the remote graphically (XFCE 4):
[REMOTE_USER]@[REMOTE]:[SOURCE] [DESTINATION] fuse.sshfs rw,noauto,_netdev,ProxyJump=[PROXY_USER]@[PROXY],IdentityFile=[PATH_TO_KEY_FOR_PROXY],IdentityFile=[PATH_TO_KEY_FOR_REMOTE] 0 0 Any ideas to make it work via the graphical prompt?