Scavenge eats disk space

Hello Community!

There was very little space left on the disk. I started scavenge in hope of freeing up disk space. Unfortunately, during this process, disk space began to decrease even more and it was finally over.
Is it normal? Does the scavenge use extra space while it is running?

Hi,

Yes, a scavenge will take extra space while its running as it does not modify the existing chunks but rather writes new ones and then swaps them out at the end. From the docs:

A scavenge reclaims disk space by rewriting your database chunks, minus the events to delete, and then deleting the old chunks. Scavenges only affect completed chunks, so deleted events in the current chunk are still there after you run a scavenge.

You can read more about scavenging here: https://developers.eventstore.com/server/20.6/server/operations/scavenge.html

1 Like