Unlink performance on FreeBSD

It’s like that on Linux and Windows too.
Seems all FSes are struggling with deleting a big amount of small files.
I do not have any suggestions how to improve that.
We need to stat each piece, to include its size to the amount of the deleted data to then update databases… Thus it’s so slow.

We have discussed several ideas internally, like do not perform any stat in any condition (but the requirement is to allocate the whole disk/partition), or to go with a On a statistical approach for the used space file walker (the team is excited about the idea, by the way, thanks @Toyoo, your ideas are very appreciated and we did not forget about you other nice idea Design draft: a low I/O piece storage !)

Still WIP though.

2 Likes