103 reputation
5
bio website askasya.com
location San Francisco, CA
age
visits member for 2 years, 8 months
seen Nov 12 at 10:20

Principal Solutions Architect for MongoDB Inc.

Answering questions and discussing MongoDB use cases on MongoDB Users Group at https://groups.google.com/forum/#!forum/mongodb-user

Posting "stupid MongoDB tricks" on http://www.kamsky.org/stupid-tricks-with-mongodb.html

Answering most interesting questions in details on http://askasya.com


Jul
28
comment Mongo Cluster - Unresponsive node/primary prevents creation of databases, secondary didn't take over
without knowing why primary was non-responsive (i.e. anything in the logs? what does db.currentOp() show?) it's impossible to say, but it sounds like primary was still sending and acknowledging heartbeats so the other two nodes did not see the need to elect a new primary.
Jul
28
comment MongoDB Sharding Issue
is there a reason that you are running with only one config server? Also you seem to be trying to insert a batch of 61680 documents - I would suggest using smaller batches and more threads in parallel to load them. Lastly, your pastebin is gone so I can't tell anything else that may have happened.
Jul
28
comment MongoDB Max Connections
this output looks like version 2.6. however, it's not clear to me that you've run out of connections - this looks like an error caused by the shell not being able to connect to the server, not from the server giving an error because it cannot create/accept another connection. If you've run out of connections, there would be lots of errors in mongod log file of the sort "cannot create connection" or pthread no resources or some such. Are you sure it's mongod that's not accepting more connections? Rather than the network/machine?
Jul
28
comment MongoDB - DB/collection fragmentation level
that's not technically true as that will only show preallocated space, not space that's "extra" allocated for each record (if that's what OP wanted to know). However padding factor in the same stats output will show if more than "default" is being allocated for each newly inserted record.
Jul
28
comment Very strange disk-usage for replica in Mongodb
note that you do have an option to re-enable the old default. If you don't ever delete files in this collection, then you don't have to worry about efficient space re-use and it might be a better option for you (adding it here in case @Dharshan wants to add a note about that to his answer).
Mar
28
comment Strange Mongo DB writelock values in logfile
you asked this on mongodb-users group - it's a more appropriate question for that forum. But short answer - there is nothing wrong with your system.
Mar
28
comment MongoDB and datasets that don't fit in RAM no matter how hard you shove
The advice to read a record before writing to it to get it into RAM is not good advice. Since 2.0 (mid-2011) MongoDB has had yielding if data to be accessed isn't in RAM so you're just causing an extra read and an extra round trip to the server for no good reason if you do that since the lock wouldn't be held for that duration anyway.
Dec
5
comment High CPU usage on mongodb server when idle?
did you try turning off snapshotting? cpu = false or just comment out cpu=true. Also check this bug out: jira.mongodb.org/browse/SERVER-2114
Jul
1
comment MongoDB ReplicaSet Elections when some nodes are down
If two out of three are up they will elect one of them as primary. If they split the vote the first time, they will back off and renominate so while it may take more than one "vote" a new primary will be elected.