[SERVER-28108] Standalone Mongo Performance Severely Downgraded Created: 24/Feb/17  Updated: 24/Feb/17  Resolved: 24/Feb/17

Status: Closed
Project: Core Server
Component/s: MMAPv1
Affects Version/s: None
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: Krystal Flores Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Running in Linux AWS


Participants:

 Description   

Our performance of our MongoDB Standalone started running extremely slow. It has been running seamlessly for 3 months now.

Basically yesterday I noticed a 70% downgrade in the ability to iterate through a cursor.

I've increased the RAM on the box to 500GB even though that didn't seem an issue. We know this should be sharded but it is not. Our primary collection:

db.maid_location.count();
759848687

This machine also is NOT using WiredTiger.

There also is TTL index running:

db.maid_location.getIndexes();
[
	{
		"v" : 1,
		"key" : {
			"_id" : 1
		},
		"name" : "_id_",
		"ns" : "twine.maid_location"
	},
	{
		"v" : 1,
		"key" : {
			"ts" : 1
		},
		"name" : "ts_1",
		"ns" : "twine.maid_location"
	},
	{
		"v" : 1,
		"key" : {
			"md" : 1
		},
		"name" : "md_1",
		"ns" : "twine.maid_location"
	},
	{
		"v" : 1,
		"key" : {
			"d" : 1
		},
		"name" : "d_1",
		"ns" : "twine.maid_location",
		"expireAfterSeconds" : 518400
	}
]

Here are the stats:

db.stats();
{
	"db" : "twine",
	"collections" : 12,
	"objects" : 837614104,
	"avgObjSize" : 227.24632088573333,
	"dataSize" : 190344723456,
	"storageSize" : 278239156320,
	"numExtents" : 229,
	"indexes" : 17,
	"indexSize" : 145874965600,
	"fileSize" : 485028265984,
	"nsSizeMB" : 16,
	"extentFreeList" : {
		"num" : 0,
		"totalSize" : 0
	},
	"dataFileVersion" : {
		"major" : 4,
		"minor" : 22
	},
	"ok" : 1
}

I was going to run a mongodump on the collection so that I can remove probably over half of what is in there. The query for the mongodump is using the field "d".. which is the same one the TTL index is using.

This is the output from the mongodump. Is this the number of documents dumped? If so it's running as slow as my process was running so this isn't going to help me. Is there any reason a database would just slow down when iterating over a cursor? There is a ton of memory on here.

2017-02-24T22:13:03.380+0000	twine.maid_location  13128025
2017-02-24T22:13:06.380+0000	twine.maid_location  13128025
2017-02-24T22:13:09.380+0000	twine.maid_location  13128025
2017-02-24T22:13:12.380+0000	twine.maid_location  13128025



 Comments   
Comment by Kelsey Schubert [ 24/Feb/17 ]

Hi kflores,

Thanks for your report. Please note that SERVER project is for reporting bugs or feature suggestions for the MongoDB server. For MongoDB-related support discussion please post on the mongodb-user group or Stack Overflow with the mongodb tag. A question like this involving more discussion would be best posted on the mongodb-users group. In addition, I would recommend providing the output of db.currentOp(), which may identify an operation that explains this slowdown.

Kind regards,
Thomas

Generated at Thu Feb 08 04:17:08 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.