I have a directory on a CentOS 7.6 machine that I want to mount on another machine that runs RedHat 7.9.
On the RedHat machine, I add this line to /etc/fstab:
[email protected]:/mnt/Scan-PDF /mnt/scanfiles/ fuse.sshfs rw,x-systemd.automount,x-systemd.nofail,_netdev,idmap=user,allow_other,transform_symlinks,identityfile=/root/.ssh/id_rsa,umask=0222 0 0
I have been trying various options such as uid, user, etc. The result is the same in that the filesystem is mounted as read-only. The file /proc/mounts shows two entries (why 2?):
systemd-1 /mnt/scanfiles autofs rw,relatime,fd=33,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=26826 0 0
[email protected]:/mnt/Scan-PDF /mnt/scanfiles fuse.sshfs ro,nosuid,nodev,noexec,relatime,user_id=0,group_id=0,default_permissions,allow_other 0 0
It looks like the filesystem is being mounted as read-only, which could be causing issues with accessing or modifying files on the remote system.
One thing to check is the permissions on the remote directory (/mnt/Scan-PDF). Make sure that the user on the local machine has appropriate permissions to read and write to the directory.
Another thing to try is to add the "rw" option to the mount command in /etc/fstab:
Also, try removing the "ro" option from the mount command and see if that helps:
After making changes to /etc/fstab, you can try remounting the filesystem using the command "mount -a" to see if the changes take effect.