Search code examples
kubernetesdevopsetcd

Backup Kubernetes Cluster


  • Kubernetes version: 1.21.0

  • Cloud being used: bare-metal

  • Installation method: kubeadm

  • Host OS: centos 7

  • CNI version: Flannel v0.3.1

  • CRI and version: Docker v20.10.7

How to backup etcd in my current setup?

The etcdcl command gives an error:

-bash: etcdctl: command not found

The etcdctl command doesn’t work in my current setup please help. Thanks


Solution

  • You need to install etcdctl on your local machine.

    Please follow etcd installation documentation.

    For instance you can find v.3.5.0 here with instuctions.


    As for backing up the etcd you can refer to kubernetes documentation - Backing up an etcd cluster

    Also you may consider using some dedicated solutions to fully backup kubernetes cluster. One of the examples is Velero