How to use filter correctly?

What is the problem you are having with rclone?

I had set directory to be excluded in filter.txt and mount, yet rclone keep creating and uploading that folder.

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

rclone version
rclone v1.58.0-beta.6000.dc7e3ea1e

  • os/version: unknown
  • os/kernel: 4.4.180+ (x86_64)
  • os/type: linux
  • os/arch: amd64
  • go/version: go1.17.7
  • go/linking: static
  • go/tags: none

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)

/usr/bin/rclone --config /volume1/docker/rclone/rclone.conf mount gCryptQS: /volume2/downloads/media/ --allow-other --uid=1026 --gid=100 --umask 002 --transfers=20 --checkers=20 --tpslimit=10 --default-permissions --copy-links --no-check-certificate --vfs-cache-mode full --dir-cache-time 9999h --attr-timeout 9999h --no-gzip-encoding --no-checksum --no-modtime --poll-interval 15m --cache-dir /volume2/downloads/gCache/vfs/ --vfs-read-wait 60ms --buffer-size 0M --use-mmap -v --filter-from /volume1/docker/rclone/filter.txt

The rclone config contents with secrets removed.

[gCryptQS]
type = crypt
remote = gCacheQS:/219.hJANsLw
filename_encryption = obfuscate
directory_name_encryption = true
password = 
password2 =
server_side_across_configs = true

[gCacheQS]
type = cache
remote = gDriveQS:/Crypted
info_age = 1y
db_path = /volume1/docker/rclone/gCache
chunk_path = /volume2/downloads/gCache
tmp_upload_path = /volume2/downloads/gCache/upload
writes = true
chunk_clean_interval = 9000h
chunk_total_size = 8000G

[gDriveQS]
type = drive
client_id = 
client_secret = 
scope = drive
token = {"access_token":
root_folder_id = 
server_side_across_configs = true

content in the filter.txt

- *.db
- /@eaDir/
- /37.@plOtC/
- /@eaDir/**
- /37.@plOtC/**
- /test123/
- /test123/**

it appear that - *.db is working correctly, thumbnail created from windows explorer did not get uploaded.
but - /@eaDir/ doesnt seems to work, the folder and its thumbnail get uploaded uninterrupted.
same goes to - /test123/ folder still get created and uploaded to google drive.

my complete setup as below:

CryptedMount --> Cache Back End --> Google Drive

i am aware cache back end is deprecating, but i believe this may not related to cache back end, this could be my setup problem.

kindly teach me how to exclude the directory being uploaded to google drive correctly. thanks.

You appear to be using filters with rclone mount. These stop those files appearing in the mount listings, but they don't stop you uploading them.

Filters are most useful with rclone copy and rclone sync.

thank you for reply and yes you are correct i was trying to use filter with mount. so is that means it is not possible to filter if using mount?

You can use filter with mount, but it doesn't stop uploads, only listing the files.

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