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.