Closed jimmycuadra closed 7 years ago
Thanks all for help.
Finally fully working k8s 1.6.1 with flannel. Everything is now in ansible playbooks.
Tested on Centos/RHEL. Preparations started for Debian based also (e.g. Ubuntu), but there might needs some refining.
https://github.com/ReSearchITEng/kubeadm-playbook/blob/master/README.md
PS: work based on sjenning/kubeadm-playbook - Many thanks @sjenning
Geeting this for joining into a cluster: [discovery] Created cluster-info discovery client, requesting info from "https://10.100.2.158:6443" [discovery] Failed to request cluster info, will try again: [configmaps "cluster-info" is forbidden: User "system:anonymous" cannot get configmaps in the namespace "kube-public"] [discovery] Failed to request cluster info, will try again: [configmaps "cluster-info" is forbidden: User "system:anonymous" cannot get configmaps in the namespace "kube-public"]
I started the node as SelfHosting.
What keywords did you search in Kubernetes issues before filing this one? (If you have found any duplicates, you should instead reply there.): kubeadm
Is this a BUG REPORT or FEATURE REQUEST? (choose one): bug report
Kubernetes version (use
kubectl version
): 1.6.0Environment:
uname -a
): 4.4.50-hypriotos-v7+What happened:
Following the kubeadm getting started guide exactly:
That last message, "First node has registered, but is not ready yet" repeats infinitely, and kubeadm never finishes. I connected to the master server in another session to see if all the Docker containers were running as expected and they are:
I copied the admin kubeconfig to my local machine and used kubectl (1.6.0) to see what was going on with the node kubeadm was claiming was registered:
This uncovered the reason the kubelet was not ready:
"runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:docker: network plugin is not ready: cni config"
In my experiments with kubeadm 1.5, CNI was not needed to bring up the master node, so this is surprising. Even the getting started guide suggests that
kubeadm init
should finish successfully before you move on to deploying a CNI plugin.Anyway, I deployed flannel using kubectl from my local machine:
Where the contents of the file was:
But it never scheduled:
I tried to join one of the other servers anyway, just to see what would happen. I used
kubeadm token create
to manually create a token that I could use from another machine. On the other machine:And the final message repeated forever.
What you expected to happen:
kubeadm init
should complete and produce a bootstrap token.