0

Im using MongoDB 3.6 I have a huge number of fragmentation in my collections. 300+ GB on one collection. WiredTiger is the storage engine.

I know its bad for the OS and much wasted space. This affects the memory as well if we use MMAP engine. But I don't know how the fragmentation affects the WiredTiger?

1 Answer 1

0

It will be less efficient to fetch data if you have a lot of space available for reuse. However, that space could be reused if you continue to insert or update documents in the collection.

If you've dropped a significant amount of data (which sounds like ~300GB in one of your collections) you can reclaim space by either:

For either approach I would use rolling maintenance to maintain availability.

A resync would be the most effective option. The compact command is riskier to run as a replica set member may become stale while running compact offline (and require resync); this operation may also not be able to free as much disk space as a resync and needs to be run per collection.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.