简体   繁体   中英

Kubernetes mongodb with replicasets backup

can someone please help me to take mongodb backup with replicasets. We are using kubernetest which is deployed in AWS, I deployed mongodb with replicasets in kubernetes using helm chart and tried to take backup using velero and restic, I could able to take backup of mongodb but when I restore sometime pods are not coming up and errors are like corrupted db or checksum did not match etc.

Can someone please let me know how to take mongodb backup in kubernetes without stopping mongodb server ie hot backup. Appreciate your inputs.

use mongodump with --oplog option for point in time hot backups. See https://docs.mongodb.com/manual/reference/program/mongodump/#cmdoption-mongodump-oplog . This option is not available on a stand-alone. Even if you only have a single server you can convert to a single member replica set for oplog functionality.

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