1GB of RAM sufficient?

81 views
Skip to first unread message

Nick Hoffman

unread,
Nov 16, 2012, 3:55:18 PM11/16/12
to mongod...@googlegroups.com
Hi guys. Considering the following info, is a server with 1GB of RAM and 2 Xeon 2.13GHz CPUs sufficient? I ask because the CPU is spiking frequently.

mongostat

mongotop

> db.stats()
{
        "db" : "production",
        "collections" : 40,
        "objects" : 1500495,
        "avgObjSize" : 298.134407645477,
        "dataSize" : 447349188,
        "storageSize" : 667463680,
        "numExtents" : 167,
        "indexes" : 63,
        "indexSize" : 129687712,
        "fileSize" : 2080374784,
        "nsSizeMB" : 16,
        "ok" : 1
}

Nick Hoffman

unread,
Nov 16, 2012, 3:57:54 PM11/16/12
to mongod...@googlegroups.com
Actually, it looks like RAM isn't the issue. Why would the CPU be spiking?

$ free -m
             total       used       free     shared    buffers     cached
Mem:           992        983          9          0          1        352
-/+ buffers/cache:        629        363
Swap:         1023          0       1023

gregor

unread,
Nov 16, 2012, 5:35:14 PM11/16/12
to mongod...@googlegroups.com
Your idx miss % is low which means your index is in RAM but you are page faulting - your data it being faulted in from disk because you have such a small ram. 
Does the log show any slow queries?

Nick Hoffman

unread,
Nov 16, 2012, 5:43:37 PM11/16/12
to mongod...@googlegroups.com
Hi gregor. I'm tracking slow queries in ScoutApp.com , which says that MongoDB's averaging 6.6 slow queries per minute, which is pretty low.

gregor

unread,
Nov 19, 2012, 3:29:55 AM11/19/12
to mongod...@googlegroups.com
Slow queries are logged in the mongod log file - can you paste some of those?
Is anything else running on the box?

Christopher Choi

unread,
Nov 19, 2012, 5:29:07 AM11/19/12
to mongod...@googlegroups.com
Generally its a bad idea to have such a low ram. as MongoDB tries to cache all your data on RAM....


On Friday, November 16, 2012 8:55:18 PM UTC, Nick Hoffman wrote:
Reply all
Reply to author
Forward
0 new messages