I'm having a weird problem. I'm measuring a performance on a similar dataset with a similar indexes (in fact i just mognodumped/mongorestored it).
One instance is running locally in vagrant (1 core, 4 gigs etc...) Another is running on a server.
The version of of MongoDB is 3.0.6.
So I ran that import in vagrant server and got noticeably different results in performance. In fact vagrant instance executes same query 3 to 5 times faster than a real server.
So I checked db.stats()
output. And here are the differences:
Reallife server:
> db.stats()
{
"db" : "komparu_product_acc",
"collections" : 1,
"objects" : 30235,
"avgObjSize" : 147517.09485695386,
"dataSize" : 4460179363,
"storageSize" : 1610596352,
"numExtents" : 0,
"indexes" : 16,
"indexSize" : 2682880,
"ok" : 1
}
And here's vagrant instance:
> db.stats()
{
"db" : "komparu_product_dev",
"collections" : 4,
"objects" : 30273,
"avgObjSize" : 261799.2074786113,
"dataSize" : 7925447408,
"storageSize" : 9727320048,
"numExtents" : 27,
"indexes" : 17,
"indexSize" : 11233824,
"fileSize" : 36423335936,
"nsSizeMB" : 16,
"extentFreeList" : {
"num" : 52,
"totalSize" : 24781381472
},
"dataFileVersion" : {
"major" : 4,
"minor" : 22
},
"ok" : 1
}
Here are stats for live server collection: http://pastebin.com/9vipBmQm
Same for vagrant one: http://pastebin.com/HbbSi0Pu
As you can see. Live server runs wiredTiger data storage. And I can notice that it compresses data really tight (compared to MMAPv1).
For more concern here's an explain output for the same query on both environments:
- Vagrant: http://pastebin.com/8h3iL5Fh
- Live: http://pastebin.com/2DjX4YTg
How can I boost the performance of wiredTiger? Or should I switch back to MMAPv1?
Any hints are helpful!
Thank you!