How to calculate the db size

1,741 views
Skip to first unread message

Admin

unread,
May 2, 2011, 12:50:28 PM5/2/11
to mongodb-user
Hello,

We are planning to go into production with MONGO DB.How can we
calculate the db size???? Please provide me with some docs as to what
are the parameters thats needs to be considered for planning this.

Thanks,

Kenny Gorman

unread,
May 2, 2011, 12:55:46 PM5/2/11
to <mongodb-user@googlegroups.com>, Kenny Gorman
--
You received this message because you are subscribed to the Google Groups "mongodb-user" group.
To post to this group, send email to mongod...@googlegroups.com.
To unsubscribe from this group, send email to mongodb-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/mongodb-user?hl=en.


Admin

unread,
May 2, 2011, 1:04:14 PM5/2/11
to mongodb-user
Thank you Kenny. But this will give me the size of existing DB.I want
to plan at hardware level as to how much disk storage is needed what
would be the memory size and the number of CPU`s.

Regards,
C

On May 2, 9:55 am, Kenny Gorman <kgor...@shutterfly.com> wrote:
> db.stats()
>
> http://www.mongodb.org/display/DOCS/Monitoring+and+Diagnostics#Monito...
>
> -kg
>
> On May 2, 2011, at 9:50 AM, Admin wrote:
>
> Hello,
>
> We are planning to go into production with MONGO DB.How can we
> calculate the db size???? Please provide me with some docs as to what
> are the parameters thats needs to be considered for planning this.
>
> Thanks,
>
> --
> You received this message because you are subscribed to the Google Groups "mongodb-user" group.
> To post to this group, send email to mongod...@googlegroups.com<mailto:mongod...@googlegroups.com>.
> To unsubscribe from this group, send email to mongodb-user...@googlegroups.com<mailto:mongodb-user+unsubscribe@g­ooglegroups.com>.

Admin

unread,
May 2, 2011, 1:08:09 PM5/2/11
to mongodb-user
In a way i am doing capacity planning to come up with the cost.I do
have the number of records that will be loaded and retrieved from this
database.I want to plan the hardware that should be thrown into to
acieve the TPS and what that would cost.

On May 2, 9:55 am, Kenny Gorman <kgor...@shutterfly.com> wrote:
> db.stats()
>
> http://www.mongodb.org/display/DOCS/Monitoring+and+Diagnostics#Monito...
>
> -kg
>
> On May 2, 2011, at 9:50 AM, Admin wrote:
>
> Hello,
>
> We are planning to go into production with MONGO DB.How can we
> calculate the db size???? Please provide me with some docs as to what
> are the parameters thats needs to be considered for planning this.
>
> Thanks,
>
> --
> You received this message because you are subscribed to the Google Groups "mongodb-user" group.
> To post to this group, send email to mongod...@googlegroups.com<mailto:mongod...@googlegroups.com>.
> To unsubscribe from this group, send email to mongodb-user...@googlegroups.com<mailto:mongodb-user+unsubscribe@g­ooglegroups.com>.

Kenny Gorman

unread,
May 2, 2011, 1:08:17 PM5/2/11
to <mongodb-user@googlegroups.com>, Kenny Gorman
You can create some sample documents that represent your expected dataset size. Then look at the avgSize, then perform some analysis/math to calculate out the expected size.

-kg

> To post to this group, send email to mongod...@googlegroups.com.
> To unsubscribe from this group, send email to mongodb-user...@googlegroups.com.

Kenny Gorman

unread,
May 2, 2011, 1:12:06 PM5/2/11
to mongod...@googlegroups.com, Kenny Gorman
I should have said: "expected document size"

-kg

Admin

unread,
May 2, 2011, 1:36:34 PM5/2/11
to mongodb-user
Thank you. Do you have any document outlining tese steps to be
followed to reach this conclusion??I know while calculation the db
size in other database we cosider avg row size and then based on 4k,8K,
16K and 32K page size we come up with the db size.But for mongo what
page size to be considered?? and how much momery?



Regards,
C
> >> For more options, visit this group athttp://groups.google.com/group/mongodb-user?hl=en.- Hide quoted text -
>
> - Show quoted text -
Message has been deleted

Admin

unread,
May 2, 2011, 5:12:50 PM5/2/11
to mongodb-user
Can someone please provide the steps to be followed to calculate the
db size that might be needed based on existing POC system? By
default
what page size should be used for calculation (4K,8k or 16 k)
> > >> For more options, visit this group athttp://groups.google.com/group/mongodb-user?hl=en.-Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -

Greg Studer

unread,
May 2, 2011, 7:09:42 PM5/2/11
to mongod...@googlegroups.com
Hi,

It may be possible to calculate the exact size of your data set
beforehand, but it will be very complex, and will change as you
insert/delete/index data. You could try inserting a large set (10%?) of
indexed sample data into your system, remove and reinsert a quarter of
it, and use the stats() shell commands as Kenny suggested to determine
how large your data grew. The exact page size of your system will not
affect your data size or performance nearly as much as the way you model
your schema.

Useful docs:
All data is stored in BSON:
http://bsonspec.org/#/specification
http://www.mongodb.org/display/DOCS/dbshell
+Reference#dbshellReference-Miscellaneous

Guide to disk space
http://www.mongodb.org/display/DOCS/Excessive+Disk+Space

On Mon, 2011-05-02 at 13:50 -0700, Admin wrote:
> Can someone please provide the steps to be followed to calculate the
> db size that might be needed based on existing POC system? By default

> what page size should be used for caculation (4K,8k or 16 k)


>
> On May 2, 10:36 am, Admin <nmchan...@gmail.com> wrote:

> > > >> For more options, visit this group athttp://groups.google.com/group/mongodb-user?hl=en.-Hide quoted text -
> >
> > > - Show quoted text -- Hide quoted text -

Reply all
Reply to author
Forward
0 new messages