3

I have a Java + MongoDB web application deployed on an OpenShift production medium gear, with no scaling enabled, with 11GB storage.

At the moment, I have some data stored, so MongoDB accurately reports a Data Size of 720.4K. This grows appropriately when I add new objects, everything is ok.

What I am concerned about is the reported Storage Size of 1.52M. Since this is a production gear, I am expecting that this allocated storage space will grow as needed (at the current rate of data production, I estimate the 1.52M limit will be reached in a few days). Is my expectation correct?

ETA: In the meantime, the Storage Size has increased to 2.02M, so I guess that answers my question.

0

You can more or less estimate that but you cannot be 100% sure.

A piece of advice I can give you is to change your storage engine to wiredTiger. I had 20.0GB of disk used by a mongodb instance using the MMAPv2 (which was the default storage engine before Mongodb 3.2). When I converted that to use wiredTiger my disk space dropped to unbelievable 1.9GB.

That might help you for a while.

|improve this answer|||||
  • Wired tiger provides data compression. So your disk space dropped to 1.9gb – harshavmb Dec 19 '15 at 9:30
  • Indeed it has data compression. Two modes of data compression by the way: Snappy and zlib. Snappy is the default, compress a little less but does it way faster than zlib. – Mestre San Dec 21 '15 at 20:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy