发表于 2015-7-9 09:51:37

mongodb集群

  要了解mongodb各个组件的作用
  This is a list of the components (processes) in the MongoDB server package.

[*]mongod - The core database process
[*]mongos - Sharding controller
[*]mongo - The database shell (uses interactive javascript)


[*]Import Export Tools

[*]mongoimport
[*]mongoexport
[*]mongodump
[*]mongorestore
[*]bsondump



[*]mongofiles - the GridFS utility


[*]mongostat
  MongoDB has two primary components to the database server.The first is the mongod process which is the core database server.In many cases, mongod may be used as a self-contained system similar to how one would use mysqld on a server.Separate mongod instances on different machines (and data centers) can replicate from one to another.
  Another MongoDB process, mongos, facilitates auto-sharding.mongos can be thought of as a "database router" to make a cluster of mongod processes appear as a single database.See the sharding documentation for more information.
  比较重要的摘录
  Each shard consists of one or more servers and stores data using mongod processes (mongod being the core MongoDB database process). In a production situation, each shard will consist of multiple servers to ensure availability and automated failover. The set of servers/mongod process within the shard comprise a replica set.
  In MongoDB, sharding is the tool for scaling a system, and replication is the tool for data safety, high availability, and disaster recovery. The two work in tandem yet are orthogonal concepts in the design.
  For testing, you can use sharding with a single mongod instance per shard.Production databases typically need redundancy, so they use replica sets.
  全文地址
  示例地址
  实验记录
  root 1839 1 0 10:07 ? 00:00:12 /usr/local/mongodb/bin/mongod --shardsvr --quiet --port=12000 --maxConns=20000 --logpath=/log/mongodb/12000.log --pidfilepath=/usr/local/mongodb/12000.pid --fork --nojournal --logappend --dbpath=/data/db/12000
root      1931   10 10:15 ?      00:00:10 /usr/local/mongodb/bin/mongod --shardsvr --quiet --port=14000 --maxConns=20000 --logpath=/log/mongodb/14000.log --pidfilepath=/usr/local/mongodb/14000.pid --fork --nojournal --logappend --dbpath=/data/db/14000
root      1969   10 10:19 ?      00:00:10 /usr/local/mongodb/bin/mongod --configsvr --quiet --port=16000 --maxConns=20000 --logpath=/log/mongodb/config.log --pidfilepath=/usr/local/mongodb/config.pid --fork --nojournal --logappend --dbpath=/data/db/config
root      1999   10 10:26 ?      00:00:08 /usr/local/mongodb/bin/mongos --quiet --port=18000 --maxConns=20000 --logpath=/log/mongodb/mongos.log --logappend --pidfilepath=/usr/local/mongodb/mongos.pid --fork --configdb=127.0.0.1:16000 --chunkSize=1
root      201614010 10:29 pts/0    00:00:00 /usr/local/mongodb/bin/mongo --port 18000
页: [1]
查看完整版本: mongodb集群