Mongo DBを半年運用してみた
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Mongo DBを半年運用してみた

on

  • 50,246 views

MongoDBの簡単な概要と、Ameba PicoでMongoDBを半年運用した中で発生した障害など。

MongoDBの簡単な概要と、Ameba PicoでMongoDBを半年運用した中で発生した障害など。

Statistics

Views

Total Views
50,246
Views on SlideShare
38,295
Embed Views
11,951

Actions

Likes
70
Downloads
215
Comments
1

28 Embeds 11,951

http://d.hatena.ne.jp 6691
http://ameblo.jp 4167
http://matsukaz.hatenablog.com 611
http://snip-snap.posterous.com 132
http://s.ameblo.jp 86
http://slide.localhost 49
http://webcache.googleusercontent.com 43
https://twitter.com 35
http://twitter.com 30
http://blog.ameba.jp 18
http://www.slideshare.net 18
http://storage.zetta.flab.fujitsu.co.jp 16
http://s.deeeki.com 10
http://translate.googleusercontent.com 9
http://www.twylah.com 6
http://www.google.co.jp 5
http://feedblog.ameba.jp 5
http://b.hatena.ne.jp 4
http://tube.deldig.com 2
https://kcw.kddi.ne.jp 2
https://www.google.co.jp 2
http://localhost 2
http://tweetedtimes.com 2
http://cache.yahoofs.jp 2
http://feedly.com 1
http://tr398.posterous.com 1
https://www.chatwork.com 1
http://posterous.com 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Mongo DBを半年運用してみた Presentation Transcript

  • 1. MongoDB Masakazu Matsushita @matsukaz2011 7 28
  • 2. • @matsukaz • • Ameba Pico • DevLOVE2011 7 28
  • 3. 2011 7 28
  • 4. Ameba Pico • • 2010 32011 7 28
  • 5. (2011 7 ) • 390 MAU 60 • 10 20 • 3:7 •2011 7 28
  • 6. 2011 7 28
  • 7. • MongoDB • Ameba Pico • MongoDB2011 7 28
  • 8. MongoDB2011 7 28
  • 9. Document-oriented storage • • BSON (Binary JSON) > db.users.save( { name : "hoge", age : 20 } ) > db.users.save( { name : "fuga" } ) > db.users.find() { "_id" : ObjectId("4d6b7ef5934c0000000053a4"), "name" : "hoge", "age" : 20 } { "_id" : ObjectId("4d6b7f06934c0000000053a5"), "name" : "fuga" }2011 7 28
  • 10. Full Index Support • Index • Unique Index Index2011 7 28
  • 11. Replication • ReplicaSet mongod Member 1 (PRIMARY) mongod mongod Member 2 Member 3 (SECONDARY) (SECONDARY)2011 7 28
  • 12. Replication • ReplicaSet mongod Member 1 (DOWN) mongod mongod Member 2 Member 3 (PRIMARY) (SECONDARY)2011 7 28
  • 13. Replication • ReplicaSet mongod Member 1 (RECOVERING) mongod mongod Member 2 Member 3 (PRIMARY) (SECONDARY)2011 7 28
  • 14. Replication • ReplicaSet mongod Member 1 (SECONDARY) mongod mongod Member 2 Member 3 (PRIMARY) (SECONDARY)2011 7 28
  • 15. Auto-Sharding • Shard Key Shard 1 users name1 name2 name3 name4 name5 name6 name7 name8 name9 items item1 item2 item32011 7 28
  • 16. Auto-Sharding • Shard Key Shard 1 Shard 2 users name1 name2 name3 name4 name5 name6 name7 name8 name9 items item1 item2 item32011 7 28
  • 17. Auto-Sharding • Shard Key Shard 1 Shard 2 users users name1 name2 name3 name7 name8 name9 name4 name5 name6 name7 name8 name9 items item1 item2 item3 Chunk (Shard Key Range)2011 7 28
  • 18. Auto-Sharding • Shard Key Shard 1 Shard 2 users users name1 name2 name3 name7 name8 name9 name4 name5 name6 items mongos item1 item2 item3 client client mongos mongoc Shard2011 7 28
  • 19. Ameba Pico2011 7 28
  • 20. 2011 1 Shard 1 mongoc mongos mongod mongod mongod Shard 2 Web Socket mongos mongoc mongod mongod mongod Shard 3 mongos mongoc mongod mongod mongod (memcached) LB ID/Point/ (HAProxy) MySQLEC2 m2.2xlarge (Mem 34.2GB / 13 EC2CU) c1.xlarge (Mem 7GB / 20 EC2CU) m1.large (Mem 7.5GB / 4 EC2CU) c1.medium (Mem 1.7GB / 5 EC2CU) m1.small (Mem 1.7GB / 1 EC2CU) EBS S3 CloudFront Elastic MapReduce2011 7 28
  • 21. 2011 3 Shard 1 mongoc mongos mongod mongod mongod Shard 2 Web Socket mongos mongoc mongod mongod mongod Shard 3 mongos mongoc mongod mongod mongod (memcached) Shard 4 mongos mongod mongod mongod LB ID/Point/ (HAProxy) MySQLEC2 m2.2xlarge (Mem 34.2GB / 13 EC2CU) c1.xlarge (Mem 7GB / 20 EC2CU) m1.large (Mem 7.5GB / 4 EC2CU) c1.medium (Mem 1.7GB / 5 EC2CU) m1.small (Mem 1.7GB / 1 EC2CU) EBS S3 CloudFront Elastic MapReduce2011 7 28
  • 22. 2011 5 Shard 1 mongoc mongos mongod mongod mongod Shard 2 Web Socket mongos mongoc mongod mongod mongod Shard 3 mongos mongoc mongod mongod mongod (memcached) Shard 4 mongos mongod mongod mongod LB ID/Point/ Shard 5 (HAProxy) MySQL mongod mongod mongodEC2 m2.2xlarge (Mem 34.2GB / 13 EC2CU) Shard 6 c1.xlarge (Mem 7GB / 20 EC2CU) m1.large (Mem 7.5GB / 4 EC2CU) mongod mongod mongod c1.medium (Mem 1.7GB / 5 EC2CU) m1.small (Mem 1.7GB / 1 EC2CU) EBS S3 CloudFront Elastic MapReduce2011 7 28
  • 23. 2011 7 Shard 1 mongoc mongod mongod mongod mongos mongos Shard 2 Web Socket mongoc mongod mongod mongod Shard 3 mongos mongoc mongod mongod mongod (memcached) Shard 4 mongod mongod mongod LB ID/Point/ Shard 5 (HAProxy) MySQL mongod mongod mongodEC2 m2.2xlarge (Mem 34.2GB / 13 EC2CU) Shard 6 c1.xlarge (Mem 7GB / 20 EC2CU) m1.large (Mem 7.5GB / 4 EC2CU) mongod mongod mongod c1.medium (Mem 1.7GB / 5 EC2CU) m1.small (Mem 1.7GB / 1 EC2CU) EBS S3 CloudFront Elastic MapReduce2011 7 28
  • 24. MongoDB2011 7 28
  • 25. 2011 22011 7 28
  • 26. 2011 7 28
  • 27. 2011 7 28
  • 28. mongod Repair2011 7 28
  • 29. 2011 7 28
  • 30. 2011 7 28
  • 31. 2011 32011 7 28
  • 32. Shard2011 7 28
  • 33. 2011 7 28
  • 34. 2011 7 28
  • 35. 2011 7 28
  • 36. 2011 7 28
  • 37. http://www.flickr.com/photos/andreasmarx/190619661/2011 7 28
  • 38. 62011 7 28
  • 39. 2011 52011 7 28
  • 40. Shard 22011 7 28
  • 41. OFF2011 7 28
  • 42. MongoDB2011 7 28
  • 43. 2011 7 28
  • 44. 2011 7 28
  • 45. 2011 7 28
  • 46. 2 Shard2011 7 28
  • 47. 2011 7 28
  • 48. 2011 7 28
  • 49. 2011 62011 7 28
  • 50. mongos2011 7 28
  • 51. 2011 7 28
  • 52. 2011 72011 7 28
  • 53. MongoDB 1.6.5 → 1.8.22011 7 28
  • 54. 2011 7 28
  • 55. 2011 7 28
  • 56. chunk chunk2011 7 28
  • 57. http://www.flickr.com/photos/madhorse5/415958992/2011 7 28
  • 58. 2011 7 28
  • 59. 4 Shard2011 7 28
  • 60. 2011 7 28
  • 61. 2011 7 28
  • 62. 2011 7 28
  • 63. 2011 7 28
  • 64. 2011 7 28
  • 65. 2011 7 28
  • 66. 2011 7 28
  • 67. Shard 2 EC22011 7 28
  • 68. 30 Repair2011 7 28
  • 69. 2011 7 28
  • 70. mongod 12011 7 28
  • 71. 2011 7 28
  • 72. 2011 7 28
  • 73. 2011 7 28
  • 74. 2011 7 28