Rclone uploads over mega storage limit

What is the problem you are having with rclone?

I have mega drives connected with a union drive. I also encrypted the union drive.
Now, when I upload to the encrypted union drive, the files get uploaded perfectly fine. The only problem is that the storage limit is exceeded by approx. 1-2 GB. So instead of using 20 GB free space, 21-22 GB are being used.
Is there a way or a flag so rclone checks if there is enough space available without exceeding the storage limit ?
For example. Storage is about 19GB/20GB full. File1 should be uploaded and hat 800MB so the file gets uploaded to the drive. File2 has 1.1GB so it should be uploaded to the drive.

The union policies are:
action_policy = epall
create_policy = epmfs
search_policy = ff

I hope I made it clear^^

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

mega

The command you were trying to run

rclone copy -P /path/to/file union-crypt-drive:path/to/dir

Rclone version

rclone v1.55.1

  • os/type: linux
  • os/arch: amd64
  • go/version: go1.16.3
  • go/linking: static
  • go/tags: none

Thanks you !

hello and welcome to the forum,

rclone does not have such a feature but you can write a script.
to get the amout of free space rclone about

latest stable rclone is v1.58.1

Hey! Thank you for your help.
The problem here is that if I use rclone about to find out how much space there is available I`ll get the space information for the whole union.

Even when I write a script that takes the free space into account, I can just use the information for the union since I dont know into which drive the file will get uploaded :confused:

have you seen Union: Retry with the next remote, if there's insufficcient free space left

I didnt till now but to be honest I dont understand quite what to do here. Should I use OPs workaround ?

Manually change the first drive to :nc, then the second, so on, retry manually until the end.