Goal: mount remote folder via sshfs on local system on boot
I have an empty USB attached to my machine:
There is one folder inside the drive
The permissions of the drive and the folder are:
When I run this command:
sshfs [email protected]:/mnt/mpathw/steve/Downloads /media/steve/downloads-remote/Downloads -o allow_other,reconnect
The drive is mounted, and the two directories are linked. I can see folders, add/remove edit on both sides and everything works as expected.
Now I am trying to achieve the same thing, but have this drive mounted on boot permanently.
I have edited
fuse.conf and added:
Then I have edited my
fstab file and added this:
[email protected]:/mnt/mpathw/steve/Downloads /media/steve/downloads-remote/Downloads fuse.sshfs allow_other,identityfile=/home/steve/.ssh/id_rsa,default_permissions,idmap=user,reconnect,uid=1000,gid=1000 0 0
Now, after rebooting my system:
First it creates another mounting point, so that my media folder suddenly looks like this:
/media/steve --downloads-remote --downloads-remote1/Downloads
/Downloads folder has now been pushed onto
When I try to access
/media/steve/downloads-remote/ I get Permission Denied.
When I check the permissions of
/media/steve/downloads-remote/ I see
drwx------ 3 root root.
I then changed the permissions with:
sudo chmod -R a+rwx downloads-remote, so now permissions look like this:
drwxrwxrwx 3 root root
Now I can enter into
/media/amir/downloads-remote/Downloads, however, there are no files there, it is not synced with the remote server.
What is missing from my setup?
I don't want it to create this new directory
downloads-remote1, I want it mounted just like I have it when I use
Why does is it assigning the folder to root and making me change the permissions?
Why does it not seem to be actually connected to the remote drive, since I can't see any of the files/folders.