Please help with permissions? rclone failed to create vfs cache - operation not permitted

What is the problem you are having with rclone?

I know this is may end up not being exactly an rclone issue (maybe it is), so forgive me for going slightly tangiental. I am running a mount command with a vfs cache. When I do, it tells me it can't create the directory. I have two computers with almost the exact same setup, and the other isn't having this issue - which seems really odd to me that one should work while the other doesn't.

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

rclone v1.62.2

  • os/version: darwin 13.3 (64 bit)
  • os/kernel: 22.4.0 (arm64)
  • os/type: darwin
  • os/arch: arm64 (ARMv8 compatible)
  • go/version: go1.20.2
  • go/linking: dynamic
  • go/tags: cmount

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

Google Drive

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

\\\rclone mount --vfs-cache-mode full --vfs-cache-max-size 900G --vfs-cache-max-age 504h0m0s --cache-dir /Volumes/7SExt_01/rclone_cache --vfs-read-chunk-size 64M --buffer-size 256M BWA1_Best\ Western\ Sedona: /Users/jimmy16/rclone_mounts/BWA1_Best\ Western\ Sedona\\\

The rclone config contents with secrets removed.

\\ [BWA1_Best Western Sedona]
type = drive
client_id = 772570769330-5o86vml05a418r8hrt6fmmobcjufsbia.apps.googleusercontent.com
client_secret = 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
scope = drive
token = {"access_token":"ya29.a0Ael9sCOmdWBh6MCgDoq47dom4EeLhhvdHJrZjC9UeNao86Kd6XqlJl6Tl_Qpwjyzxqj5oN0mYqH2OmIfcZ8ZMJm4SnwYld1qcAOgI-9Sb0k-XvmwmekHDfOTHielYdMg9hW2Js4IhDRUhZZ-p1iyCZOs_PsI6zh4aCgYKAbESARMSFQG1tDrpvzTF2EE00DMGtt51VXVzRw0167","token_type":"Bearer","refresh_token":"1//06oLWLRXtr54dCgYIARAAGAYSNwF-L9IrJkApNPiUhusR-Xu6xy4srHfVZoEU8FPkO4rJ5Mb0qO7bPke_DWqP4rd40HdTovospDY","expiry":"2023-04-27T11:54:34.406012-07:00"}
team_drive = 0ALGyugQuIphWUk9PVA
root_folder_id = 
\\\

A log from the command with the -vv flag

\\\
jimmy16@Isaacs-Mac-mini ~ % rclone mount --vfs-cache-mode full --vfs-cache-max-size 900G --vfs-cache-max-age 504h0m0s --cache-dir /Volumes/7SExt_01/rclone_cache --vfs-read-chunk-size 64M --buffer-size 256M BWA1_Best\ Western\ Sedona: /Users/jimmy16/rclone_mounts/BWA1_Best\ Western\ Sedona -vv
2023/04/27 11:21:23 DEBUG : rclone: Version "v1.62.2" starting with parameters ["rclone" "mount" "--vfs-cache-mode" "full" "--vfs-cache-max-size" "900G" "--vfs-cache-max-age" "504h0m0s" "--cache-dir" "/Volumes/7SExt_01/rclone_cache" "--vfs-read-chunk-size" "64M" "--buffer-size" "256M" "BWA1_Best Western Sedona:" "/Users/jimmy16/rclone_mounts/BWA1_Best Western Sedona" "-vv"]
2023/04/27 11:21:23 DEBUG : Creating backend with remote "BWA1_Best Western Sedona:"
2023/04/27 11:21:23 DEBUG : Using config file from "/Users/jimmy16/.config/rclone/rclone.conf"
2023/04/27 11:21:23 DEBUG : vfs cache: root is "/Volumes/7SExt_01/rclone_cache"
2023/04/27 11:21:23 ERROR : Failed to create vfs cache - disabling: failed to create data cache directory: mkdir /Volumes/7SExt_01/rclone_cache/vfs/BWA1_Best Western Sedona: operation not permitted
2023/04/27 11:21:23 Fatal error: failed to mount FUSE fs: cannot open: /Users/jimmy16/rclone_mounts/BWA1_Best Western Sedona: open /Users/jimmy16/rclone_mounts/BWA1_Best Western Sedona: operation not permitted
\\\

This directory needs to not exist for a Windows mount to work. Is that true or is there a pre-existing directory of that name?

This is on Mac. And the directory does exist. I can try removing it, but it doesn't seem like that is the issue. As an update, I've plugged in a separate hard drive which works fine with the same configuration on a separate computer and I get the same permission error. This makes me think the issue is in the terminal and not on the specific hard drive. Is it possible that the terminal instances permissions aren't at admin level or something? Adding sudo to the beginning of the argument gives me the same error though.

I got it working. I added "terminal" to the permissions list in "privacy and security" inside Apple's settings and that fixed it. The program didn't have permission at a computer-wide level. I'm a noob, so I am not exactly sure what else to say, but that fixed it!

1 Like

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