Is this a valid backup strategy for MongoDB?
- by James Simpson
I've got a single dedicated server with a MongoDB database of around 10GB. I need to do daily backups, but I can't have downtime with the database. Is it possible to use a replica set on a single disk (with 2 instances of mongod running on different ports), and simply take the secondary one offline and backup the data files to an offsite storage such as S3 (journaling is turned on)? Or would using master/slave be better than a replica set?
Is this viable, and if so, what potential problems could I have? If not, how do I conceptualize this to work?