Cluster creation fails when the VMware Cloud Director external network has a DNS suffix and the DNS server resolves
localhost.my.suffix to a valid IP.
This is due to a bug in
The main issue is that etcd prioritizes the DNS server over the
/etc/hosts file to resolve hostnames, when the conventional behavior would be to prioritize checking any hosts files before going to the DNS server. This becomes problematic when kubeadm attempts to initialize the control plane node using
localhost. etcd checks the DNS server for any entry like
localhost.suffix, and if this actually resolves to an IP, attempts to do some operations involving that incorrect IP, instead of localhost.
- Create a kubeadm config file, and modify the
kubeadm init command in the VMware Cloud Director Container Service Extension control plane script for the template of the cluster you are attempting to deploy.
- Change the command to the following command:
kubeadm init --config >/path/to/kubeadm.yaml > /root/kubeadm-init.out
Note: The VMware Cloud Director Container Service Extension control plane script is located at
Note: It is necessary to specify the Kubernetes version within the configuration file as
--config are incompatible.