How to restore a Kubernetes cluster after IP change
Recently I had to fix a kubernetes cluster which had its IP addresses changed. The team that changed the IP address on the machines also replaced the hostname in /etc/hosts. However, this is not enough. In order to restore the cluster, you also have to change the IP address in kubernetes cluster manifest files. [root@k8s-master ~]# cat /etc/hosts 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 11.11.112.42 k8s-master 11.11.112.43 worker-k8s2 11.11.112.44 worker-k8s3 11.11.112.42 worker-k8s-control First I confirmed the manifest files include the old IP address of the master node (10.10.138.42): ...