0
votes

I want to make continuous backup of my Sharded Cluster on a single MongoDB server somewhere else.

So, is it possible to create Replica Set with Sharded Cluster (mongos instance) and single MongoDB server?

Did anyone experience creating Replica Sets with two Sharded Clusters or with one Sharded Cluster and one Single Server?

How does it work?

2
Please rephrase your question. It is not clear what is to be done.vmr
@vmr sorry. What is not clear? In which way you suggest to rephrase it?Yurij
Do you want to continuously backup your data?vmr
What do you mean by single server, are you running the cluster on single server? Or are you looking to backup the cluster to single server?Sammaye

2 Answers

2
votes

By the way, the best (and for now, the only) way to continuously backup Sharded Cluster is by using MongoDB Management Service (MMS).

1
votes

I were also facing the same issue sometime back. I wanted to take replica of all sharded cluster into one MongoDB. But, i didn't found any solution for this scenario, and I think this is true, because -

If you configure the multiple shard server (say 2 shard server) with one replica set, then this will not work because in a replica set (say rs0) only 1-primary member is possible. And In this scenario, we will have multiple primary depend on number of shard server.

To take the backup of your whole sharded cluster, you must stop all writes to the cluster. You can refer to MongoDB documentation on this - http://docs.mongodb.org/manual/tutorial/backup-sharded-cluster-with-database-dumps/