A new utility in #Mastodon 3.1.0 is `tootctl media remove-orphans`. Orphaned files are files that the database believes have been removed, but actually aren't. If your server has been around for a long time, it's likely that you have at least some of those due to various previous bugs and object storage glitches.
For mastodon.social, it was able to remove 619 GB worth of files.
Please mind that API requests necessary for this command can incur extra charges with your object storage provider.
@Gargron finally getting all those orphans off of mastodon
@Gargron my instance isn't old enough. nothing saved sadly.
Hi to all and to all
me is AARNE and I offer financial assistance to all people in need
The procedure is simple and fast
quick contact: firstname.lastname@example.org
realize your projects in the best of cases
@Gargron wow, that's a lot of space!
@Gargron Would it be complicated to add --days parameter to the tootctl media remove-orphans command to avoid S3 extra fees, at Wasabi for example? 90 days by default would be ideal in my opinion. Thank you!
@manu You're confusing the command, remove-orphans isn't for regular use, you're thinking of remove and it's got a --days option
@Gargron I'm realy talking about remove-orphans. In my cron, I run statuses remove, media remove and preview_cards remove with the --days parameter each hour. And I run media remove-orphans each day.
Is there a way to know the creation date of an orphan media?
@manu It’s not for regular use! Don’t run it each day! Files only get orphaned if you do a live migration from one S3 provider to another or through bugs that existed 2 years ago in Mastodon
@Gargron Oh.. Thank you! I remove it from my cron.
Server run by the main developers of the project It is not focused on any particular niche interest - everyone is welcome as long as you follow our code of conduct!