Andrey Smirnov 62c702c4fd fix: remove conflicting etcd member on rejoin with empty data directory
This fixes a scenario when control plane node loses contents of `/var`
without leaving etcd first: on reboot etcd data directory is empty, but
member is already present in the etcd member list, so etcd won't be able
to join because of raft log being empty.

The fix is to remove a member with matching hostname if found in the
etcd member list followed by new member add.

The risk here is removing another member which has same hostname as the
joining node, but having duplicate hostnames for control plane node is a
problem anyways.

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
2021-06-03 15:11:44 -07:00
..
2019-11-05 17:21:38 +03:00
2020-11-09 06:48:07 -08:00
2021-03-12 06:50:02 -08:00
2021-03-12 06:50:02 -08:00