Using Ubuntu 22.04. My fstab
entry:
some_user@some_storagebox.com:~/somedir /mnt/volume fuse.sshfs defaults,allow_other,reconnect,_netdev,users,ServerAliveInterval=15,identityfile=/root/.ssh/id_rsa,uid=101,gid=101,ServerAliveCountMax=3 0 0
Check fstab line with:
mount /mnt/volume-1
storage requires to enter password although I'm using rsa key with identityfile
parameter.
Could it be related with uid
, gid
parameters or any other. I'm lost.
UPDATE:
By testing @Nikita Kipriyanov answerI tried to connect via ssh -i /root/.ssh/id_rsa some_user@some_storagebox.com
and found that previously I connected via ssh with 23 port. Added it to fstab, but then mounting failed on
~/somedir
directory which was not found. After adjusting it to
/home/somedir
everything worked perfectly.
Updated fstab entry:
some_user@some_storagebox.com:/home/somedir /mnt/volume fuse.sshfs defaults,allow_other,reconnect,_netdev,users,ServerAliveInterval=15,port=23,identityfile=/root/.ssh/id_rsa,uid=101,gid=101,ServerAliveCountMax=3 0 0
Only one mind blowing thing, why mounted directory can go with a tilde and be found on mounting fstab with password and without port.