I've found the answer myself. The problem was that I didn't use the option allow_other.
sshfs -o allow_other -o kernel_cache -o auto_cache -o reconnect \
-o compression=no -o cache_timeout=600 -o ServerAliveInterval=15 \
xxx@yyy.yyy.yyy.yyy:/mnt/content /home/xxx/path_to/content
To use this option you have to set the option user_allow_other in /etc/fuse.conf. When I did this I had another problem. The file /etc/fuse.conf haven't had read permissions for other users on my Ubuntu box. So I've changed that too and now I can access the directory with any user.
You can copy the lines started with /dev/sd**
from mtab (/etc/mtab
) and paste them in to a new text file and change /dev/sd**
with UUID
or LABEL
.
For example from your config:
use
UUID="3fc55e0f-a9b3-4229-9e76-ca95b4825a40" / ext4 rw,errors=remount-ro 0 0
instead
/dev/sda1 / ext4 rw,errors=remount-ro 0 0
The line above also works, but UUID
is the new standart and if your grub configured with UUID
, it might can't understand which partition is what.
if partition has Label you can use the LABEL
instead UUID
, for example:
LABEL="Files_Server_Int" /media/Files_Server ext4 rw 0 0
IMO copy your mtab to a new file and remove the lines started with "none"
and change the /dev/sd**
part with blkid output equivelants. If UUID exist, use the UUID
instead of /dev/sd**
. If LABEL exist use the LABEL
instead of UUID.
Do not remove anything else except "none"
lines. Save the file, change the file name to fstab
and copy in to /etc
.
Finally add lines for swap
if any (if you forget this, your system will boot but you might have zero swap space or swap file will be generated at root (/
) depending of OS default configuration.). e.g. in your case note that blkid
prints this line:
/dev/sda5: UUID="718e611d-b8a3-4f02-a0cc-b3025d8db54d" TYPE="swap"
so you need this line in fstab
:
UUID=718e611d-b8a3-4f02-a0cc-b3025d8db54d none swap sw 0 0
This might help to restore your fstab.
Best Answer
What system are you on? What versions of sshfs and fuse are you running? I'm on ubuntu server 18.04 and using authorized keys for auth.
This my fstab:
and versions:
Here's some output from timing ls -l
A remote directory with 1259 files or folders listed pretty quickly.
I don't know if it may make a difference or not but I also have:
In my /etc/ssh/sshd_config file. It speeds up initial logins