Fatal error on mount (exit status 1) : permission problems

Hello,

I check lot of past without solving my problem...

What is the problem you are having with rclone?

I configure a storage system which seems to work : i can use "ls".
I try to mount the storage to be used by plex and i get an error.
I guess i have a conflit with the permission and the user who run rclone.

My user is "jbo".

The error i use :

jbo:/mnt/bigfoot$ rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids --vfs-cache-mode full --network-mode --volname "kids" --allow-other
2025/01/19 19:03:42 mount helper error: fusermount: user has no write access to mountpoint /mnt/bigfoot/MegaData/kids
2025/01/19 19:03:42 Fatal error: failed to mount FUSE fs: fusermount: exit status 1

When:

jbo:/mnt/bigfoot/MegaData$ ls -la
total 12
drwxr-xr-x 3 root root 4096 17 janv. 22:49 .
drwxr-xr-x 5 root root 4096 17 janv. 22:40 ..
drwxr-xr-x 2 root root 4096 17 janv. 22:49 kids

It tried various commands.

It works when :

jbo:/mnt/bigfoot/MegaData$ ls -la
total 8
drwxr-xr-x 3 root root 4096 17 janv. 22:49 .
drwxr-xr-x 5 root root 4096 17 janv. 22:40 ..
drwxr-xr-x 1 jbo  jbo     0 19 janv. 00:14 kids

But i get an error in my front interface, and i will be afraid plex will not see the folders and the files:

lstat permission denied

Run the command 'rclone version' and share the full output of the command.

rclone v1.60.1-DEV
- os/version: debian 12.9 (64 bit)
- os/kernel: 6.1.0-30-amd64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.19.8
- go/linking: dynamic
- go/tags: none

Which cloud storage system are you using? (eg Google Drive)

webdav

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids --vfs-cache-mode full --network-mode --volname "kids" --allow-other

I have try without --allow-other and it doesn't solve anything.

Please run 'rclone config redacted' and share the full output. If you get command not found, please make sure to update rclone.

jbo:/mnt/bigfoot/MegaData$ rclone config redacted
Usage:
  rclone config [flags]
  rclone config [command]

Available Commands:
  create      Create a new remote with name, type and options.
  delete      Delete an existing remote.
  disconnect  Disconnects user from remote
  dump        Dump the config file as JSON.
  file        Show path of configuration file in use.
  password    Update password in an existing remote.
  paths       Show paths used for configuration, cache, temp etc.
  providers   List in JSON format all the providers and options.
  reconnect   Re-authenticates user with remote.
  show        Print (decrypted) config file, or the config for a single remote.
  touch       Ensure configuration file exists.
  update      Update options in an existing remote.
  userinfo    Prints info about logged in user of remote.

Flags:
  -h, --help   help for config

Additional help topics:
  rclone config edit       Enter an interactive configuration session.

Use "rclone [command] --help" for more information about a command.
Use "rclone help flags" for to see the global flags.
Use "rclone help backends" for a list of supported services.
Command config needs 0 arguments maximum: you provided 1 non flag arguments: ["redacted"]

A log from the command that you were trying to run with the -vv flag

When i try to use --log-file=FILE, i also get a permission error.

Thank you in advance for the help.

hi,
please install latest stable v1.69.0 and test again
https://rclone.org/install/

that is for windowz os, not linux

Hello,

I remove the debian package to run the install script.

Now:

$ rclone version
rclone v1.69.0
- os/version: debian 12.9 (64 bit)
- os/kernel: 6.1.0-30-amd64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.23.4
- go/linking: static
- go/tags: none

now, run the command again with -vv and post the full output


that is not really a rclone issue, but a basic linux permissions issue

I run the command without --network-mode:

$ rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids --vfs-cache-mode full --allow-other -vv
2025/01/20 08:58:31 DEBUG : rclone: Version "v1.69.0" starting with parameters ["rclone" "mount" "mega.kids:/" "/mnt/bigfoot/MegaData/kids" "--vfs-cache-mode" "full" "--allow-other" "-vv"]
2025/01/20 08:58:31 DEBUG : Creating backend with remote "mega.kids:/"
2025/01/20 08:58:31 DEBUG : Using config file from "/home/jbo/.config/rclone/rclone.conf"
2025/01/20 08:58:31 DEBUG : found headers: 
2025/01/20 08:58:31 DEBUG : fs cache: renaming cache item "mega.kids:/" to be canonical "mega.kids:"
2025/01/20 08:58:31 INFO  : webdav root '': poll-interval is not supported by this remote
2025/01/20 08:58:31 DEBUG : webdav root '': vfs cache: root is "/home/jbo/.cache/rclone"
2025/01/20 08:58:31 DEBUG : webdav root '': vfs cache: data root is "/home/jbo/.cache/rclone/vfs/mega.kids"
2025/01/20 08:58:31 DEBUG : webdav root '': vfs cache: metadata root is "/home/jbo/.cache/rclone/vfsMeta/mega.kids"
2025/01/20 08:58:31 DEBUG : Creating backend with remote ":local,encoding='Slash,Dot':/home/jbo/.cache/rclone/vfs/mega.kids/"
2025/01/20 08:58:31 DEBUG : :local: detected overridden config - adding "{bxYPm}" suffix to name
2025/01/20 08:58:31 DEBUG : fs cache: renaming cache item ":local,encoding='Slash,Dot':/home/jbo/.cache/rclone/vfs/mega.kids/" to be canonical ":local{bxYPm}:/home/jbo/.cache/rclone/vfs/mega.kids"
2025/01/20 08:58:31 DEBUG : Creating backend with remote ":local,encoding='Slash,Dot':/home/jbo/.cache/rclone/vfsMeta/mega.kids/"
2025/01/20 08:58:31 DEBUG : :local: detected overridden config - adding "{bxYPm}" suffix to name
2025/01/20 08:58:31 DEBUG : fs cache: renaming cache item ":local,encoding='Slash,Dot':/home/jbo/.cache/rclone/vfsMeta/mega.kids/" to be canonical ":local{bxYPm}:/home/jbo/.cache/rclone/vfsMeta/mega.kids"
2025/01/20 08:58:31 INFO  : webdav root '': vfs cache: cleaned: objects 0 (was 0) in use 0, to upload 0, uploading 0, total size 0 (was 0)
2025/01/20 08:58:31 DEBUG : webdav root '': Mounting on "/mnt/bigfoot/MegaData/kids"
2025/01/20 08:58:31 mount helper error: fusermount3: user has no write access to mountpoint /mnt/bigfoot/MegaData/kids
2025/01/20 08:58:31 CRITICAL: Fatal error: failed to mount FUSE fs: fusermount: exit status 1

Does it help?
The permission issue is not clear for me...

It is not rclone problem.

If you want to mount something to a directory it has to have permissions for user you run rclone with.

You already made it work. Not sure what else you need...

If you have issues with Plex then maybe ask on their forum.

Thank you @kapitainsky
So i have to play with user and group...

When i will fix it, i could think about mount optimization for plex.

I try to restart another command:

rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids \
--vfs-cache-mode full \ 
--allow-non-empty \ 
--cache-dir /mnt/bigfoot/MegaCache \
--vfs-refresh \
--vfs-cache-max-size 100G \
--vfs-cache-max-age 9999h \
--cache-tmp-wait-time 600 \
--buffer-size 1G \
--vfs-fast-fingerprint \
--dir-cache-time 9999h \
--read-only
^C2025/01/20 13:33:20 ERROR : /mnt/bigfoot/MegaData/kids: Unmounted rclone mount

I don't understand i have to use ctrl + C to back to the bash...

I change the ownership before my command:

total 36
drwxr-xr-x 6 root root  4096 20 janv. 10:55 .
drwxr-xr-x 4 root root  4096 17 janv. 13:32 ..
drwxr-xr-x 4 jbo  jbo   4096 20 janv. 11:09 MegaCache
drwxr-xr-x 3 jbo  jbo   4096 17 janv. 22:49 MegaData

This is how it works. If you do not want to keep it running in your terminal then you have to run in the background. On Linux probably the best approach is to use systemd. You will find plenty of examples on this forum, e.g.:

What do you need --allow-non-empty for? It should be used only in special situations.

What is this flag? --cache-tmp-wait-time ?? It is from some ancient cache remote which is deprecated for ages. You can not use it together with VFS.

Do not use random flags you find on internet. At least check in documentation before what they are for.

Thank you for the tips to run it with systemd...
Wasn't it the purpose of --daemon?

You perfectly right i try to compile somme flag i found on the web and in the forum. I will check the documentation before the next try.

I understand I can unmount several time without be worried about my data with :

fusermount -u /mnt/bigfoot/MegaData/kids

It is another (basic though) way to do it but systemd gives you more control, e.g mount can be only started when network is back after reboot.

Yes. You can also use other commands supported by fuse and your OS, like umount.

I change my mount command following the documentation and it seems to work:

rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids --cache-dir /mnt/bigfoot/MegaCache --vfs-cache-mode full --vfs-refresh --vfs-cache-max-size 100G --vfs-cache-max-age 24h --vfs-fast-fingerprint --vfs-read-chunk-streams 16 --vfs-read-chunk-size 32M --read-only --daemon

Then I try to use systemd.

$ cat /etc/systemd/system/rclone-drive.service
[Unit]
Description=Mount for /mnt/bigfoot/MegaData
Wants=network-online.target
After=network-online.target

[Mount]
Type=notify
What=mega.kids:/
Where=/mnt/bigfoot/MegaData/kids
Options=cache-dir=/mnt/bigfoot/MegaCache,vfs-cache-mode=full,vfs-refresh,vfs-cache-max-size=100G,vfs-cache-max-age=24h,vfs-fast-fingerprint,vfs-read-chunk-streams=16,vfs-read-chunk-size=32M,read-only
Restart=on-failure

[Install]
WantedBy=default.target

I get an error

$ systemctl status rclone-drive.service
○ rclone-drive.service - Mount for /mnt/bigfoot/MegaData
     Loaded: bad-setting (Reason: Unit rclone-drive.service has a bad unit file setting.)
     Active: inactive (dead)

I use the documentation mixed with your post reference.
Maybe i have to use automount.

there are a few approaches to using systemd with rclone mount
so, cannot mix and match between them.

your systemd is a mishmash between the two of them, that is not going to work.

from your post, based on rclone docs.

  1. the name of the systemd file needs to end with .mount, not .service
  2. Type=notify should be Type=rclone
  3. remove all extra lines that you added, that are not found in the rclone example

Hello,

Thank you for the information and the interesting link.

With .mount, i don't succeed to make it run well...
But it seems to work with rclone-drive.service .

[Unit]
Description=RClone Service
Wants=network-online.target
After=network-online.target mega-cmd-server.service

[Service]
Type=notify
Environment=RCLONE_CONFIG=/home/jbo/.config/rclone/rclone.conf
ExecStart=/usr/bin/rclone mount mega.kids:/ /mnt/bigfoot/MegaData/kids --cache-dir /mnt/bigfoot/MegaCache --vfs-cache-mode full --vfs-refresh --vfs-cache-max-size 100G --vfs-cache-max-age 24h --vfs-fast-f>
ExecStop=/bin/fusermount -u /mnt/bigfoot/MegaData/kids
Restart=on-failure

[Install]
WantedBy=default.target

It work partially.
As you notice, i run a mega service before to get the webdav server path. Unfortunatly it webdav server don't start on reboot, it a problem i have to fix.
And I get a mess with my mounted folder:

$ ls -la
total 20
drwxr-xr-x  5 root root 4096 22 janv. 08:01 .
drwxr-xr-x 19 root root 4096 15 janv. 21:54 ..
drwxrwxrwx  3 root root 4096 22 janv. 08:00 bigfoot
drwxr-xr-x  6 root root 4096 20 janv. 10:55 bigfoot-1

bigfoot-1 is a hard disk who have to be mount before rclone.

I will look for adding this service in the After tag in rclone-drive.service.

I guess the problem is out of the scope of rclone.

Thank you again with the help.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.