简体   繁体   中英

Mongodb Sharding Backup / Restore

We are using mongodb sharding in production server and having 2 sharding and 3 replica set including arbitor on each shard. Records also distributed based on write request. But we have to know how will take a backup, because we are having more then 50Lks records in mondodb. So we need to take a records. Actually at present we are taking backup using mongodump in each shard server using primary IP and port.

Each time we need to take a backup on each shard server, incase on future i will add one more shard the same process we need to do on that server also. So please share your input if any other possiblities using mongos.

Regards, Kumaran

下面是一些使用LVM快照创建一致的mongodb分片群集备份的python代码: https//github.com/knyar/mongoclusterscripts/tree/master/mongo-backup

Take a look at this:

Backing Up Sharded Cluster .

In short:

  • for small clusters you can just use mongodump against mongos .

  • backing up larger clusters will involve running mongodump on individual shards.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM