High Availability with MongoDB for Fun and Profit

Post on 24-May-2015

9.663 views 1 download

description

My talk at MongoSF 2012.

Transcript of High Availability with MongoDB for Fun and Profit

  • 1. High Availability with MongoDBfor Fun and Profit Greg Brockman Stripe@thegdb // gdb@stripe.com

2. IntroTips & TricksBest PracticesQuestions @thegdb // gdb@stripe.com 3. Replica Set Crash Course PRIMARYSECONDARYSECONDARY @thegdb // gdb@stripe.com 4. Live Demo!@thegdb // gdb@stripe.com 5. Start a cluster@thegdb // gdb@stripe.com 6. Naively: zz @thegdb // gdb@stripe.com 7. With retries:@thegdb // gdb@stripe.com 8. All the (hard) problems are solved @thegdb // gdb@stripe.com 9. Tips & Tricks @thegdb // gdb@stripe.com 10. If at first you dont succeed... @thegdb // gdb@stripe.com 11. Rebuild all the things! @thegdb // gdb@stripe.com 12. Force initial syncs from secondaries primarynewnode# HACKnewnode> iptables -I OUTPUT -j DROP -d primary@thegdb // gdb@stripe.com 13. IPs vs Hostnames @thegdb // gdb@stripe.com 14. Zero-downtime migrations Background index buildsObject versioning Avoid multi-updates@thegdb // gdb@stripe.com 15. Best Practices @thegdb // gdb@stripe.com 16. Always rehearse your exact administration procedure@thegdb // gdb@stripe.com 17. Be skeptical@thegdb // gdb@stripe.com 18. Read the issues `@thegdb // gdb@stripe.com 19. Understand the guarantees youre getting* @thegdb // gdb@stripe.com 20. Questions@thegdb // gdb@stripe.com