I’m trying to add windows node to Kubernetes cluster v1.29.3, however kube-proxy pods keeps crashing with error in kubelet log :
cni plugin not initialized
any ideas why ?
Can you please provide more details on the environment to help debug? Like, what version of Windows Server? What CNI are you using? Have you followed the guidance from the SIG-Windows docs?
I have the same issue
I followed this guidelines: Adding Windows worker nodes | Kubernetes
First i setup master using kubespray (latest stable is 1.30.4) with calico
then installed the node with .\PrepareNode.ps1 -KubernetesVersion v1.30.4
the i did run on master:
curl -LO https://raw.githubusercontent.com/kubernetes-sigs/sig-windows-tools/master/hostprocess/calico/kube-proxy/kube-proxy.yml
sed -i -E ‘s/image: (.):(.)-(.)-(.)$/image: \1:v1.30.4-\3-\4/g’ kube-proxy.yml
and i see the pod kube-proxy is running on win server
but when i describe the node which is in state not ready i see error:
Ready False Fri, 11 Oct 2024 09:20:20 +0200 Fri, 11 Oct 2024 09:09:36 +0200 KubeletNotReady container runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:Network plugin returns error: cni plugin not initialized
root@czphadevk8sww01:~# kubectl logs kube-proxy-windows-524m8 -n kube-system
WARNING: The names of some imported commands from the module 'hns' include unapproved verbs that might make them less
discoverable. To find the commands with unapproved verbs, run the Import-Module command again with the Verbose
parameter. For a list of approved verbs, type Get-Verb.
Running kub-proxy service.
Waiting for HNS network Calico to be created...
Same here, after using this
https://docs.tigera.io/calico/latest/getting-started/kubernetes/windows-calico/operator and
https://github.com/kubernetes-sigs/sig-windows-tools/blob/master/guides/calico_operator.md
because at the time my script was running, calico-apiserver was not ready.
So try again, after all is done:
kubectl patch ipamconfigurations default --type merge --patch='{"spec": {"strictAffinity": true}}'