geesefs
geesefs copied to clipboard
Quota support?
Can geesefs support file system quotas on a "per-directory" basis? (Say just top level directories, immediately under the bucket root.) a. Have they been implemented? b. If not, are they feasible?
Hi.
- no
- I think anything can be implemented :-) but quotas will require scanning the whole directory subtree, at least when mounting. So it will be slow. Also it will probably require an additional API to be able to manage these quotas and it must be made inaccessible to the rest of applications, so it will probably require some additional permissions or configuration (geesefs currently doesn't implement permissions at all). And overall, I suspect that the usecase isn't very popular. :-)
Awesome, thanks for listening and responding / indulging me! I'll be back if I can address the above, but for now...
It depends on whether the backend supports obtaining the usage of buckets. I submitted a PR support quota. Currently, only Minio is supported as the backend.
Theoretically, you can traverse all objects to calculate the usage, like du -sh
or ls -r
, but it will be slow when the data volume exceeds ten million levels, so I gave up this idea.
#41 @jaytmiller @vitalif By the way, this PR has been running on our intranet for about two weeks, and about 200million pieces of data have been tested.
Awesome! That definitely sounds useful for us since ultimately we want to expose storage to a large set (~500?) of users and will need to bound the storage they can allocate while they go about their freeform tasks. If we can figure out how to assign each user their own bucket and dynamically mount it in k8s, we're set. Thanks for this!