Mount a SFTP remote filesystem that doesn’t give shell access

linux-networkingsftpsshfs

I have a NAS that exposes its filesystem as SFTP, but it doesn't give any access to connect throught SSH as a normal user. I've tried to use sshfs to mount it from a remote webserver, but I receive the error:

read: Connection reset by peer

Does sshfs require a user that can do login or is there a way to mount a "SFTP-only" share in Linux?

Thank you very much in advance.

Best Answer

First of all it is important to understand that there is no such thing as "SFTP-only". SFTP is not a stand-alone protocol, it is a subsystem of SSH. The SFTP client connects to the SSH server, authenticates, and then opens the SFTP subsystem (or it opens a shell, which is what your NAS does not allow, but you don't have to worry about that).

So... assuming that SFTP access to your NAS is properly configured, you shouldn't have any problem mounting it as a virtual drive using sshfs... well, to be honest the number of people who recently have reported problems with sshfs to me is embarrassing.

Therefore I would recommend you to try alternatives to sshfs. One such alternative that immediately comes to my mind (and it's free) is SFTP Net Drive (but it supports only Windows clients). So far I never had any trouble with it. :)

Related Topic