From 526d7ceed4cd78475019cb2f40463e4fa381780e Mon Sep 17 00:00:00 2001 From: Alok Singh <55465637+alokstech@users.noreply.github.com> Date: Mon, 26 Aug 2024 02:16:14 +0530 Subject: [PATCH] Correcting etcd backup command for hosted cluster The command is referencing the wrong CA cert /etc/etcd/tls/client/etcd-client.crt which doesn't exist in the pods and hence the execution fails. The actual CA cert to be used with etcdctl command is /etc/etcd/tls/etcd-ca/ca.crt. --- modules/backup-etcd-hosted-cluster.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/backup-etcd-hosted-cluster.adoc b/modules/backup-etcd-hosted-cluster.adoc index 90d29d5695..2a479ee740 100644 --- a/modules/backup-etcd-hosted-cluster.adoc +++ b/modules/backup-etcd-hosted-cluster.adoc @@ -33,7 +33,7 @@ $ oc scale deployment -n --replicas=0 kube-apiserver + [source,terminal] ---- -$ oc exec -it -n -- env ETCDCTL_API=3 /usr/bin/etcdctl --cacert /etc/etcd/tls/client/etcd-client-ca.crt --cert /etc/etcd/tls/client/etcd-client.crt --key /etc/etcd/tls/client/etcd-client.key --endpoints=localhost:2379 snapshot save /var/lib/data/snapshot.db +$ oc exec -it -n -- env ETCDCTL_API=3 /usr/bin/etcdctl --cacert /etc/etcd/tls/etcd-ca/ca.crt --cert /etc/etcd/tls/client/etcd-client.crt --key /etc/etcd/tls/client/etcd-client.key --endpoints=localhost:2379 snapshot save /var/lib/data/snapshot.db ---- . To check the snapshot status, use the `exec` command in each etcd container by running the following command: