etcdadm is a command-line tool for managing an etcd cluster. It makes it easy to create a new cluster, add a member to, or remove a member from an existing cluster. Its user experience is inspired by kubeadm.
go get -u github.com/platform9/etcdadm
- Copy
etcdadm
to each machine that will become a member. - Choose one machine and run
etcdadm init
- Copy the CA certificate and key from any machine in the cluster to the machine being added.
- Choose a cluster endpoint (i.e. client URL of some member) and run
etcdadm join <endpoint>
On the machine being removed, run
etcdadm reset
If you have an existing etcd snapshot, you can use it to create a new cluster:
etcdadm init --snapshot /path/to/etcd.snapshot
- Must run as root. (This is because etcdadm creates a systemd service)
- Does not support etcd v2.