Issue with not deleting trash since months

The correct answer is probably to let the used space file walker run and sort it out, but on a large node that could take a long time if it even works correctly. You might have to apply a work around to side step a bug in one of the databases.

It’s not recommended but sometimes I use a command to tell my node that I don’t have any trash to allow more ingress.

from inside the database folder:

sudo sqlite3 piece_spaced_used.db "update piece_space_used  set total = '0' where satellite_id = 'trashtotal'";

restart the node after.

If I want to run the file walker for real, I first do:

sudo sqlite3 used_space_per_prefix.db "DELETE FROM used_space_per_prefix";

And then restart the node.
Or else the file walker will retrieve outdated and incorrect numbers instead of actually walk the files(until they fix the bug)

Requires that sqlite3 be installed

In your case it looks like the used space is wrong.
Here is a link to the work around instructions to be able to run the file walker if it’s reporting the incorrect number: High Trash usage - 27 TB - no more uploads - #29 by Alexey

Those instructions basically do the same thing as the second sqlite3 command I posted. It’s just a different way of getting rid of the problematic data in the used_space_per_prefix.db file.

3 Likes