Good morning everyone, I have a problem here. I can’t delete files from the recycle bin. There is a bug in the system. The files stored in the main folder count the usage space, but the files in the recycle bin do not take up the account’s usage space. This just keeps accumulating and causing a headache until the client decides to delete the files. I’m here to ask for help because this is giving me a headache.
There’s an entire chapter in the Admin Manual devoted to the topic of configuring the Trash Bin however you prefer.
Good morning, however, the configuration that I show is the same as this config.php but it does not delete and does not restrict the user space either.
‘trashbin_retention_obligation’ => ‘auto, 7’,
‘trashbin_purge_limit’ => 1,
‘trashbin_auto_expire’ => true,
hey @lucasperegrino, you’re quite right… it can be complicated.
although you’re not using the snap, see Configure config.php · nextcloud-snap/nextcloud-snap Wiki · GitHub for reference as this should work on most installs.
I believe your issue is this:
I’m not sure that this will work with the auto
option in connection with the retention period. there should be a value there instead.
so you’d want something like this;
‘trashbin_retention_obligation’ => ‘30, 7’,
for the default retention period
you could do something like this for shorter two week period:
‘trashbin_retention_obligation’ => ‘14, 7’,
and do be aware to start that background job:
occ config:app:delete files_trashbin background_job_expire_trash
personally I prefer a daily/weekly/monthly cronjob on corporate servers that does the same:
#!/bin/bash
occ trashbin:cleanup --all-users ;
occ groupfolders:trashbin:cleanup -f ;
exit
maybe this general cleanup skript works for you? Note! I’m not a dev and a snap user, so you must adapt the script to suit your requirements!