I have a kubernetes cluster on bare metal with 3 machines having 8Gb of ram each. All my apps and a mongodb 4.0.9 replicaset runs on it.
There is an import program that:
1. Download a 8Gb mongo dump from external source and restore it in fresly created database A. There is one collection whitout indexes.
2. Fully browse the restored collection with one find({}) and 1M next().
3. Emit amqp messages for each doc, then messages are stored in mongo database B, C, D.
4. Drop the database A.
Part 2 use a lot of ram.
How should I configure mongo database A (and let database B normal) to reduce at max the footprint of the import operation? (Because more important tasks are running in the cluster)
For example, can I configure mongo to not create cache for the temporary collection?
Asked by Slim
(291 rep)
Apr 12, 2019, 07:46 PM
Last activity: Jun 29, 2025, 02:02 AM
Last activity: Jun 29, 2025, 02:02 AM