kubernetes-sigs / cluster-api-provider-vsphere

Apache License 2.0
372 stars 295 forks source link

Failed to create management cluster by kind #450

Closed yktsubo closed 5 years ago

yktsubo commented 5 years ago

/kind bug

What steps did you take and what happened: [A clear and concise description of what the bug is.]

Followed getting started and failed to deploy management cluster by kind. In clusterclt create process, those errors were seen.

$ clusterctl create cluster \
  --provider vsphere \
  --bootstrap-type kind \
  --cluster management-cluster/cluster.yaml \
  --machines management-cluster/machines.yaml \
  --provider-components management-cluster/provider-components.yaml \
  --addon-components management-cluster/addons.yaml \
  --kubeconfig-out management-cluster/kubeconfig
I0724 22:13:16.426231   63431 createbootstrapcluster.go:27] Creating bootstrap cluster
I0724 22:14:19.007648   63431 clusterdeployer.go:79] Applying Cluster API stack to bootstrap cluster
I0724 22:14:19.007668   63431 applyclusterapicomponents.go:26] Applying Cluster API Provider Components
I0724 22:14:20.000114   63431 clusterdeployer.go:84] Provisioning target cluster via bootstrap cluster
I0724 22:14:20.003969   63431 applycluster.go:36] Creating cluster object yktsubo-1 in namespace "default"
I0724 22:14:20.009632   63431 clusterdeployer.go:93] Creating control plane yktsubo-1-controlplane-1 in namespace "default"
I0724 22:14:20.014593   63431 applymachines.go:36] Creating machines in namespace "default"
I0724 22:18:00.032213   63431 clusterdeployer.go:98] Updating bootstrap cluster object for cluster yktsubo-1 in namespace "default" with control plane endpoint running on yktsubo-1-controlplane-1
I0724 22:18:00.130477   63431 createbootstrapcluster.go:36] Cleaning up bootstrap cluster.
F0724 22:18:04.274980   63431 create_cluster.go:61] unable to update bootstrap cluster endpoint: unable to get cluster endpoint: could not get IP

What did you expect to happen:

Management cluster is successfully deployed.

Anything else you would like to add: [Miscellaneous information that will assist in solving the issue.]

When bootstrapping management cluster, I did the following command. It seems that cluster could get kubeconfig of management cluster but clusterctl failed.

$ docker ps
CONTAINER ID        IMAGE                  COMMAND                  CREATED             STATUS              PORTS                                  NAMES
f40d71fd56c2        kindest/node:v1.14.2   "/usr/local/bin/entr…"   46 seconds ago      Up 34 seconds       45047/tcp, 127.0.0.1:45047->6443/tcp   clusterapi-control-plane

$ docker exec -it f40d71fd56c2 /bin/bash -c 'kubectl --kubeconfig /etc/kubernetes/admin.conf get secret yktsubo-1-kubeconfig  -o jsonpath="{.data.value}"' | base64 -d > /tmp/test2.kconfig; kubectl --kubeconfig /tmp/test2.kconfig get node -o wide
NAME                       STATUS     ROLES    AGE   VERSION   INTERNAL-IP     EXTERNAL-IP     OS-IMAGE             KERNEL-VERSION      CONTAINER-RUNTIME
yktsubo-1-controlplane-1   NotReady   master   17s   v1.13.6   10.16.181.139   10.16.181.139   Ubuntu 18.04.2 LTS   4.15.0-51-generic   containerd://1.2.5

Environment:

timmycarr commented 5 years ago

I was able to complete a cluster build with 1.15.0. using v0.4.1 release.

yktsubo commented 5 years ago

Thanks for the comment. I changed the version and don't see this issue any more. So I would like to close this.