Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagebash
titleRestore snapshot
# The destination directory must be empty and obviously have write permissions
$ etcdctl [--data-dir <data_dir>] snapshot restore <snapshot>
$ etcdctl --data-dir /tmp/snap_dir snapshot restore snapshot.db
# Paste the snapshot into the path where the etcd node data are stored
$ cp -r /tmp/snap_dir/member /var/lib/etcd/

BackUp CronJob

Ho trovato e sto provando questo To make a periodic backup of the etcd node(s), try using this Helm Chart.

Code Block
languagebash
titleHelm Chart
# Add and update repository
$ helm repo add adfinis https://charts.adfinis.com
$ helm repo update
# Customize and install chart
$ helm show values adfinis/openshift-etcd-backup > etcd_values.yaml
$ helm install etcd-backup adfinis/openshift-etcd-backup --namespace etcd-backup --create-namespace --values etcd_values.yaml
# Upgrade or uninstall chart
$ helm upgrade etcd-backup adfinis/openshift-etcd-backup -n etcd-backup
$ helm uninstall etcd-backup -n etcd-backup