• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
MongoDB Devops Madrid February 2012
 

MongoDB Devops Madrid February 2012

on

  • 1,181 views

A quick look at MongoDB database

A quick look at MongoDB database

Statistics

Views

Total Views
1,181
Views on SlideShare
850
Embed Views
331

Actions

Likes
0
Downloads
0
Comments
0

3 Embeds 331

http://juanvicenteherrera.eu 324
http://translate.googleusercontent.com 4
http://www.linkedin.com 3

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

CC Attribution License

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

    MongoDB Devops Madrid February 2012 MongoDB Devops Madrid February 2012 Presentation Transcript

    • First steps with MongoDB   
    • Index When you should use  NoSQL When you should not use NoSQL A quick look at MongoDB Other features Main scheme Replication Auto­sharding Architecture First steps   
    • When should I use NoSQL? Caching High data amount Horizontal scalability(without joins or complex  transactions) The Slogan is ”not only SQL”  and ”not only  NOSQL”    
    • When should not I useNoSQL High transaction level Business Intelligence Problems that need relational queries   
    • A quick look at MongoDB Document database oriented (BSON) Flexible scheme Dinamic queries Replication Auto­sharding Atomic operations Full indexes   
    • A quick look at MongoDB Not relational Distributed Opensource Horizontal scalability Drivers for most known programming languages Replication and automatic sharding GridFS   
    • Other features Map Reduce Queries are executed in parallel in all of the shards Adittion and process of flexible data Geospatial index Find objects based on their geographical location    
    • Basic schemeDatabase ServerShellSharding router Mongod Mongo Database server Interactive shell Mongos Sharding router   
    • Replication Master: mongod –master Slave: mongod –source url:port or pasive –slavedelay  numberofseconds Replica Sets Full support in dealing with failures(recommended by each  shard) You can have passive members that never will be masters. Master­master Only recommended for insert and delete queries by id.   
    • Auto-sharding Defined by a shard key Response in dealing with failures is handled by each  replica set. Queries map reduce could run in paralell between  many shards. You can add servers as shards and automatically data  are distributed along of all shards.    
    • Fragmentation   
    • Fragmentation   
    • Architecture Shards Servers: mongod –shardsvr You can configure replication to dealing with failures. Shards Routers: mongos –configdb  urlconfig:portconfig It is the shell for the rest of clients. It can be executed in an application server for reduce  the load of the server. Config Routers:mongod –configsvr Recommended a group of 3   
    • Logical architecture   
    • Important note _id Special key Present in all stored documents Unique to each collection It can be the type you want   
    • First step with sharding use admin db.runCommand( { addshard : "pre­mongo1:10000" } ); db.runCommand( { addshard : "pre­mongo2:10000" } ); db.runCommand( { enablesharding : "activities" } ); db.runCommand( { shardcollection :  "activities.userWall" , key : { userId: 1 } } ); db.printShardingStatus()   
    • Backup EC2 → Snapshot EBS LVM→ Snapshot LV FS→mysqldump, dd (with sharding not recommended) Weak point of sharding. More details ­> http://bit.ly/wNdlIA   
    • Questions?   
    • Who am I? Spanish web: http://www.juanvicenteherrera.es English web: http://www.juanvicenteherrera.eu Twitter: http://twitter.com/jvicenteherrera LinkedIn: http://es.linkedin.com/in/jvherrera