25. Tip #7
Index creation blocks by
default. Use background
indexing if necessary.
25/30
MongoDB Manual: http://bit.ly/mongobgindex
26. Tip #8
Increase your OS file
descriptor limit + use
persistent connections.
26/30
27. Too many open files!
/etc/security/limits.conf
mongo hard nofile 10000
mongo soft nofile 10000
user type limit
/etc/ssh/sshd_config
UsePAM yes
27/30
28. Space is not reused
Data + indexes 551GB
Actual disk usage 638GB
Fixed in
1.1.4 1.3.x 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4?
28/30
JIRA: SERVER-366
29. Summary
1. Keep indexes in memory.
2. Data is flushed to disk every 60s.
3. Monitor the 24k namespace limit.
4. Pre-provision oplog files.
5. Expect slower performance on replica sync.
6. Rotate logs from the console.
7. Index creation blocks by default.
29/30 8. OS file descriptor limit + persistent connections.
30. Slides
blog.boxedice.com/mongodb
David Mytton
30/30 david@boxedice.com / @davidmytton