Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use etcdutl instead of etcdctl for restoring an etcd cluster #44216

Closed
adityasamant25 opened this issue Dec 5, 2023 · 6 comments · Fixed by #44050
Closed

Use etcdutl instead of etcdctl for restoring an etcd cluster #44216

adityasamant25 opened this issue Dec 5, 2023 · 6 comments · Fixed by #44050
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug. language/en Issues or PRs related to English language sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. sig/etcd Categorizes an issue or PR as relevant to SIG Etcd. triage/accepted Indicates an issue or PR is ready to be actively worked on.

Comments

@adityasamant25
Copy link
Contributor

This is a Bug Report

Problem:
This issue refers to the page
Kubernetes Documentation > Tasks > Administer a Cluster > Operating etcd clusters for Kubernetes
https://kubernetes.io/docs/tasks/administer-cluster/configure-upgrade-etcd/

In the section titled "Restoring an etcd cluster", the commands use the etcdctl utility to restore from an existing snapshot.
Using etcdctl for restoring snapshots is deprecated since etcd version 3.5.x
Usage of this command displays a deprecation warning and suggests to use etcdutl utility instead as shown below.

ubuntu@kubemaster:~$ etcdctl version
etcdctl version: 3.5.10
API version: 3.5
ubuntu@kubemaster:~$ ETCDCTL_API=3 etcdctl --endpoints 10.2.0.9:2379 snapshot restore snapshot.db
Deprecated: Use `etcdutl snapshot restore` instead.

I feel this change is necessary as the etcd official documentation has already changed to reflect the use of the etcdutl utility, as can be seen in the etcd documentation referenced in this section - https://etcd.io/docs/v3.6/op-guide/recovery/#restoring-a-cluster.

Proposed Solution:
I have raised a PR to depict the use of the etcdutl utility for restoring from an existing snapshot.
#44050

Before submitting the PR, I have tested the changes on a local Kubernetes cluster for v1.28.0 and I can confirm everything works as expected.

Page to Update:
https://kubernetes.io/docs/tasks/administer-cluster/configure-upgrade-etcd/

Kubernetes Version: 1.28.x and above

@adityasamant25 adityasamant25 added the kind/bug Categorizes issue or PR as related to a bug. label Dec 5, 2023
@k8s-ci-robot k8s-ci-robot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Dec 5, 2023
@adityasamant25
Copy link
Contributor Author

/assign

@adityasamant25
Copy link
Contributor Author

I have raised a PR to depict the use of the etcdutl utility for restoring from an existing snapshot.
#44050

Any comments or improvements are welcome.

@dipesh-rawat
Copy link
Member

/retitle Use etcdutl instead of etcdctl for restoring an etcd cluster
/language en

@k8s-ci-robot k8s-ci-robot changed the title Use etcdutl instead of etcdctl for restoring an etcd cluster. Use etcdutl instead of etcdctl for restoring an etcd cluster Dec 5, 2023
@k8s-ci-robot k8s-ci-robot added the language/en Issues or PRs related to English language label Dec 5, 2023
@dipesh-rawat
Copy link
Member

/sig etcd

@k8s-ci-robot k8s-ci-robot added the sig/etcd Categorizes an issue or PR as relevant to SIG Etcd. label Dec 5, 2023
@divya-mohan0209 divya-mohan0209 added the sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. label Dec 7, 2023
@divya-mohan0209
Copy link
Contributor

/triage accepted

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Dec 7, 2023
@sftim
Copy link
Contributor

sftim commented Jun 10, 2024

Also see #46757

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug. language/en Issues or PRs related to English language sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. sig/etcd Categorizes an issue or PR as relevant to SIG Etcd. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants