Cannot create folder or files inside a mounted rclone drive

What is the problem you are having with rclone?

The problem is that we are getting the following error message when trying to create a folder inside an rclone mounted folder.
"mkdir(): Permission denied"

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

NO, we are not
We are using 1.55.1 and the latest apparently is 1.61.1

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

We are using the Object Share from OVH

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

rclone mount ovhobs:obshared  "/home/michael/projects/www2/html/shared/images/obshared" --allow-other --no-modtime --daemon --log-file /var/log/rclone/ovhobs_obshared.log --log-level DEBUG  --uid=48 --gid=48   --dir-perms 0777 --file-perms 0777 --umask 000

The rclone config contents with secrets removed.

rclone mount ovhobs:obshared  "/home/michael/projects/www2/html/shared/images/obshared" --allow-other --no-modtime --daemon --log-file /var/log/rclone/ovhobs_obshared.log --log-level DEBUG  --uid=48 --gid=48   --dir-perms 0777 --file-perms 0777 --umask 000

A log from the command with the -vv flag

[root@dev-001 images]# more /var/log/rclone/ovhobs_obshared.log
2023/02/28 07:33:40 INFO  : Swift container obshared: poll-interval is not supported by this remote
2023/02/28 07:39:54 DEBUG : Using config file from "/root/.config/rclone/rclone.conf"
2023/02/28 07:39:54 DEBUG : rclone: Version "v1.55.1-DEV" starting with parameters ["rclone" "mount" "ovhobs:obshared" "/home/michael/projects/www2/html/shared/images/
obshared" "--allow-other" "--no-modtime" "--daemon" "--log-file" "/var/log/rclone/ovhobs_obshared.log" "--log-level" "DEBUG" "--uid=48" "--gid=48" "--dir-perms" "0777"
 "--file-perms" "0777" "--umask" "000"]
2023/02/28 07:39:54 DEBUG : Creating backend with remote "ovhobs:obshared"
2023/02/28 07:39:55 DEBUG : rclone: Version "v1.55.1-DEV" finishing with parameters ["rclone" "mount" "ovhobs:obshared" "/home/michael/projects/www2/html/shared/images
/obshared" "--allow-other" "--no-modtime" "--daemon" "--log-file" "/var/log/rclone/ovhobs_obshared.log" "--log-level" "DEBUG" "--uid=48" "--gid=48" "--dir-perms" "0777
" "--file-perms" "0777" "--umask" "000"]
2023/02/28 07:39:55 DEBUG : Using config file from "/root/.config/rclone/rclone.conf"
2023/02/28 07:39:55 DEBUG : rclone: Version "v1.55.1-DEV" starting with parameters ["rclone" "mount" "ovhobs:obshared" "/home/michael/projects/www2/html/shared/images/
obshared" "--allow-other" "--no-modtime" "--daemon" "--log-file" "/var/log/rclone/ovhobs_obshared.log" "--log-level" "DEBUG" "--uid=48" "--gid=48" "--dir-perms" "0777"
 "--file-perms" "0777" "--umask" "000"]
2023/02/28 07:39:55 DEBUG : Creating backend with remote "ovhobs:obshared"
2023/02/28 07:39:55 INFO  : Swift container obshared: poll-interval is not supported by this remote
2023/02/28 07:39:55 DEBUG : Swift container obshared: Mounting on "/home/michael/projects/www2/html/shared/images/obshared"
2023/02/28 07:39:56 DEBUG : : Root:
2023/02/28 07:39:56 DEBUG : : >Root: node=/, err=<nil>
2023/02/28 07:42:22 DEBUG : /: Attr:
2023/02/28 07:42:22 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:22 DEBUG : /: ReadDirAll:
2023/02/28 07:42:23 DEBUG : /: >ReadDirAll: item=4, err=<nil>
2023/02/28 07:42:23 DEBUG : /: Attr:
2023/02/28 07:42:23 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:23 DEBUG : /: Lookup: name="DS"
2023/02/28 07:42:23 DEBUG : /: >Lookup: node=DS/, err=<nil>
2023/02/28 07:42:23 DEBUG : DS/: Attr:
2023/02/28 07:42:23 DEBUG : DS/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:23 DEBUG : /: Lookup: name="ebay_for_bep.jpg"
2023/02/28 07:42:23 DEBUG : /: >Lookup: node=ebay_for_bep.jpg, err=<nil>
2023/02/28 07:42:23 DEBUG : ebay_for_bep.jpg: Attr:
2023/02/28 07:42:23 DEBUG : ebay_for_bep.jpg: >Attr: a=valid=1s ino=0 size=68574 mode=-rwxrwxrwx, err=<nil>
2023/02/28 07:42:33 DEBUG : /: Lookup: name="DS"
2023/02/28 07:42:33 DEBUG : /: >Lookup: node=DS/, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/: Attr:
2023/02/28 07:42:33 DEBUG : DS/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/: ReadDirAll:
2023/02/28 07:42:33 ERROR : DS: Entry doesn't belong in directory "DS" (too short) - ignoring
2023/02/28 07:42:33 DEBUG : DS/: >ReadDirAll: item=4, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/: Attr:
2023/02/28 07:42:33 DEBUG : DS/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:33 DEBUG : /: Attr:
2023/02/28 07:42:33 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/: Lookup: name="10"
2023/02/28 07:42:33 DEBUG : DS/: >Lookup: node=DS/10/, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/10/: Attr:
2023/02/28 07:42:33 DEBUG : DS/10/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/: Lookup: name="9"
2023/02/28 07:42:33 DEBUG : DS/: >Lookup: node=DS/9/, err=<nil>
2023/02/28 07:42:33 DEBUG : DS/9/: Attr:
2023/02/28 07:42:33 DEBUG : DS/9/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:39 DEBUG : /: Lookup: name="DS"
2023/02/28 07:42:39 DEBUG : /: >Lookup: node=DS/, err=<nil>
2023/02/28 07:42:39 DEBUG : DS/: Attr:
2023/02/28 07:42:39 DEBUG : DS/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:42:39 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:42:39 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:42:39 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:42:39 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:42:39 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:42:39 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:42:39 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:42:39 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:42:39 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:42:39 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:44:44 DEBUG : /: Attr:
2023/02/28 07:44:44 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:46:30 DEBUG : /: Lookup: name="DS"
2023/02/28 07:46:30 DEBUG : /: >Lookup: node=DS/, err=<nil>
2023/02/28 07:46:30 DEBUG : DS/: Attr:
2023/02/28 07:46:30 DEBUG : DS/: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:46:30 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:46:30 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:46:30 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:46:30 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:46:30 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:46:30 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:46:30 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:46:30 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:46:30 DEBUG : DS/: Lookup: name="Logos"
2023/02/28 07:46:30 DEBUG : DS/: >Lookup: node=<nil>, err=no such file or directory
2023/02/28 07:47:18 DEBUG : /: Attr:
2023/02/28 07:47:18 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:47:18 DEBUG : /: ReadDirAll:
2023/02/28 07:47:18 DEBUG : /: >ReadDirAll: item=4, err=<nil>
2023/02/28 07:47:20 DEBUG : /: Attr:
2023/02/28 07:47:20 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:47:20 DEBUG : /: ReadDirAll:
2023/02/28 07:47:20 DEBUG : /: >ReadDirAll: item=4, err=<nil>
2023/02/28 07:47:33 DEBUG : /: Attr:
2023/02/28 07:47:33 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:47:33 DEBUG : /: ReadDirAll:
2023/02/28 07:47:33 DEBUG : : Re-reading directory (5m11.134705943s old)
2023/02/28 07:47:34 DEBUG : /: >ReadDirAll: item=4, err=<nil>
2023/02/28 07:48:54 DEBUG : /: Attr:
2023/02/28 07:48:54 DEBUG : /: >Attr: attr=valid=1s ino=0 size=0 mode=drwxrwxrwx, err=<nil>
2023/02/28 07:48:54 DEBUG : /: ReadDirAll:
2023/02/28 07:48:54 DEBUG : /: >ReadDirAll: item=4, err=<nil>
[root@dev-001 images]#

Try running rclone as a user not as root.

Also try the latest release :slight_smile:

Thank for the reply.
I tried both suggestion:

run as a regular user:

[michael@dev-001 images]$ whoami
michael
[michael@dev-001]$
[michael@dev-001]$ rclone mount ovhobs:obshared  "/home/michael/projects/www2/html/shared/images/obshared" --allow-non-empty --no-modtime --daemon --log-file /home/michael/ovhobs_obshared.log --log-level DEBUG  --uid=48 --gid=48   --dir-perms 0777 --file-perms 0777 --umask 000
[michael@dev-001]$

and also upgraded to newest version

[michael@dev-001]$ rclone version
rclone v1.61.1
- os/version: centos 7.9.2009 (64 bit)
- os/kernel: 3.10.0-1160.45.1.el7.x86_64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.19.4
- go/linking: static
- go/tags: none

but I still get permission denied

mkdir(): Permission denied

I did another test which is just trying to READ the content of that folder and I got an error there too:

failed to open dir: Permission denied

SO I cannot even read that folder, yet, it is correctly mounted and "777" rights set on that folder.

Looking at your debug log there is no mention of Mkdir in it, so the request was denied by the kernel before it even reached rclone.

tail the rclone debug log and see if you can confirm that the requests are not reaching rclone.

Another thing to check /etc/fuse.conf - you'll need allow_other uncommented in here.

Try also running with the minimal set of flags and trying to mkdir as you.

rclone mount ovhobs:obshared  "/home/michael/projects/www2/html/shared/images/obshared" --log-file /home/michael/ovhobs_obshared.log --log-level DEBUG

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