AFFiNE icon indicating copy to clipboard operation
AFFiNE copied to clipboard

​Self-host affine meets file size limit when uploading

Open xymeng16 opened this issue 1 year ago • 4 comments

What happened?

In canary 3d3a66c (actually it also happens in other recent versions I've tested), when uploading a large file (50MB~), I met the following file size limit error.

image

As mentioned in https://github.com/toeverything/AFFiNE/issues/5978, "selfhost should have unlimited storage". So I regard this as a bug, hence reporting here.

Distribution version

Linux

What browsers are you seeing the problem on if you're using web version?

No response

Are you self-hosting?

  • [X] Yes

Relevant log output

WARN [FsStorageProvider:blobs] Failed to read metadata of object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`
   WARN [FsStorageProvider:blobs] Error: ENOENT: no such file or directory, open '/root/.affine/storage/blobs/e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=.metadata.json'
VERBOSE [FsStorageProvider:blobs] Read object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`
   WARN [FsStorageProvider:blobs] Failed to read metadata of object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`
   WARN [FsStorageProvider:blobs] Error: ENOENT: no such file or directory, open '/root/.affine/storage/blobs/e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=.metadata.json'
VERBOSE [FsStorageProvider:blobs] Read object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`
   WARN [FsStorageProvider:blobs] Failed to read metadata of object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`
   WARN [FsStorageProvider:blobs] Error: ENOENT: no such file or directory, open '/root/.affine/storage/blobs/e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=.metadata.json'
VERBOSE [FsStorageProvider:blobs] Read object `e5a7d11f-5678-4ba7-81ba-22a560c48d96/cPEezFL9kCjizhjoBhJcqwlbuRDajqTGEWGG35B7mSQ=`

Anything else?

No response

xymeng16 avatar Oct 17 '24 09:10 xymeng16

#6641 might be helpful for you because self-hosted is still not unrestricted​

Timtaran avatar Oct 18 '24 09:10 Timtaran

#6641可能对你有帮助,因为自托管仍然不是不受限制的

I can use this method to change the configuration, the capacity limit can see the change, but the upload limit is still 10M

snmnr avatar Nov 16 '24 04:11 snmnr

#6641可能对你有帮助,因为自托管仍然不是不受限制的

I can use this method to change the configuration, the capacity limit can see the change, but the upload limit is still 10M

I suppose you should edit blobLimit

Timtaran avatar Nov 16 '24 12:11 Timtaran

#6641可能对你有帮助,因为自托管仍然不是不受限制的

I can use this method to change the configuration, the capacity limit can see the change, but the upload limit is still 10M

I suppose you should edit blobLimit

I have tried to configure these configurations and only for upload restrictions not work 8 | free_plan_v1 | {"name":"Free","blobLimit":10485760,"storageQuota":10737418240,"historyPeriod":604800000,"memberLimit":3} 9 | pro_plan_v1 | {"name":"Pro","blobLimit":104857600,"storageQuota":107374182400,"historyPeriod":2592000000,"memberLimit":10} 10 | restricted_plan_v1 | {"name":"Restricted","blobLimit":1048576,"storageQuota":10485760,"historyPeriod":2592000000,"memberLimit":10} 11 | free_plan_v1 | {"name":"Free","blobLimit":104857600,"storageQuota":10737418240,"historyPeriod":604800000,"memberLimit":3} 12 | free_plan_v1 | {"name":"Free","blobLimit":10485760,"businessBlobLimit":104857600,"storageQuota":10737418240,"historyPeriod":604800000,"memberLimit":3} 13 | free_plan_v1 | {"name":"Free","blobLimit":10485760,"businessBlobLimit":104857600,"storageQuota":10737418240,"historyPeriod":604800000,"memberLimit":3,"copilotActionLimit":10} 14 | pro_plan_v1 | {"name":"Pro","blobLimit":104857600,"storageQuota":107374182400,"historyPeriod":2592000000,"memberLimit":10,"copilotActionLimit":10} 15 | restricted_plan_v1 | {"name":"Restricted","blobLimit":1048576,"storageQuota":10485760,"historyPeriod":2592000000,"memberLimit":10,"copilotActionLimit":10} 16 | lifetime_pro_plan_v1 | {"name":"Lifetime Pro","blobLimit":104857600,"storageQuota":1099511627776,"historyPeriod":2592000000,"memberLimit":10,"copilotActionLimit":10}

snmnr avatar Nov 22 '24 14:11 snmnr

selfhost user now granted Pro quota as it on affine.pro

you may roll up your image and do a redeploy to make to work

forehalo avatar Feb 24 '25 04:02 forehalo