Duplicacy cannot access rclone mounted folder

I have a remote storage mounted to a local directory on my home server (OMV/Debian 10) using rclone mount. I works fine when I cd into that directory: I can access the remote files as expected. However, when I try to add a storage to duplicacy (web), it cannot access that same folder:

As soon as I unmount the remote storage, duplicacy can access the directory (but won’t see the reomote storage, of course). So rclone somehow seems to block access while it is active. Or rather: duplicacy is not willing to access the directory as long as rclone is there (because I can access the directory fine from the command line, so it is not blocked.)

I suppose there is a simple solution that I just can’t see?

Was the web GUI started by a different user account?

If rclone mount is done as a user, and duplicacy is running as another user, say, superuser, it won’t be able to access the first user-mounted filesystem.

To solve this problem (backing up of user-mounted filesystems) ArqBackup launches special process (arqreader) impersonating that user to fetch data. Duplicacy today does not handle that scenario.

However, for the rclone usecase specifically depending on your OS and the version of Fuse on that OS you may be able to give access to the mount to other users and/or root. IIRC fuse needs to be configured with user_allow_other flag, and then mount with allow_other or allow_root as needed. I think you can feed all of this to rclone in some way.

Alternatively you can just have duplicacy mount the filesystem again for backup purposes inside the pre-backup script.

2 Likes

Thank you @saspus! Very enlightening, as always!

I tried rclone mount because I couldn’t get rcloud serve to work. Maybe I should try that again.

But I did manage to get the mounted storage to work by creating the rclone remote as root (because duplicavy is running as root), however it doesn’t seem tonwork properly on the duplicacy side. I keep getting these:

2022-03-13 09:18:07.336 WARN SNAPSHOT_CHECK Chunk ff.davfs.tmp29e029 has a size of 0
2022-03-13 09:18:07.341 WARN SNAPSHOT_CHECK Chunk fe.davfs.tmp24c189 has a size of 0
2022-03-13 09:18:07.341 WARN SNAPSHOT_CHECK Chunk fe.davfs.tmp365389 has a size of 0
2022-03-13 09:18:07.341 WARN SNAPSHOT_CHECK Chunk fe.davfs.tmp375c89 has a size of 0
2022-03-13 09:18:07.345 WARN SNAPSHOT_CHECK Chunk fd.davfs.tmp199189 has a size of 0
2022-03-13 09:18:07.345 WARN SNAPSHOT_CHECK Chunk fd.davfs.tmp1a4809 has a size of 0
2022-03-13 09:18:07.364 WARN SNAPSHOT_CHECK Chunk fa.davfs.tmp044f09 has a size of 0
2022-03-13 09:18:07.364 WARN SNAPSHOT_CHECK Chunk fa.davfs.tmp046209 has a size of 0
2022-03-13 09:18:07.364 WARN SNAPSHOT_CHECK Chunk fa.davfs.tmp2e4729 has a size of 0
2022-03-13 09:18:07.367 WARN SNAPSHOT_CHECK Chunk f9.davfs.tmp2a7309 has a size of 0

I have no idea about IIRC fuse . I installed rclone on my debian 10 server using the official rclone script. I will try those flags though, once I’ve figured others things out. At the moment, it looks like serve might be the better way (if I can get it to work).