Microk8s: Failed to create pod sandbox: rpc error: code

Asking for help? Comment out what you need so we can get more information to help you!

Cluster information:

Kubernetes version: 1.23
Cloud being used: (put bare-metal if not on a public cloud) : bare-metal
Installation method: Using snap store( sudo microk8s install microk8s --classic)
Host OS: Unbuntu:20.04 LTS
CNI and version:
CRI and version:

sudo microk8s kubectl -n kube-system describe po calico-kube-controllers-89645b65b-6fmhg

 Warning  FailedCreatePodSandBox  103s (x84 over 19m)  kubelet  (combined from similar events): Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox "51d07a480c7556b60ff05682a034092df6f792f12112e5f0f11696a48ad1029d": error getting ClusterInformation: resource does not exist: ClusterInformation(default) with error: clusterinformations.crd.projectcalico.org "default" not found
sudo microk8s kubectl get po -A
NAMESPACE     NAME                                         READY   STATUS              RESTARTS        AGE
kube-system   calico-kube-controllers-89645b65b-6fmhg      0/1     ContainerCreating   0               30m
kube-system   coredns-64c6478b6c-nkdrr                     0/1     ContainerCreating   0               28m
kube-system   dashboard-metrics-scraper-69d9497b54-g5vbd   0/1     ContainerCreating   0               27m
kube-system   metrics-server-679c5f986d-zh5xw              0/1     ContainerCreating   0               27m
kube-system   kubernetes-dashboard-585bdb5648-rw7qt        0/1     ContainerCreating   0               27m
kube-system   calico-node-jr55z                            0/1     CrashLoopBackOff    13 (106s ago)   30m

I think you need to see why calico-node-jr55z is crashlooping. The rest failing is probably due to this pod not setting up the network.

Having the exact same problem.
Like @balchua1 mentioned, it’s the calico-node that’s crashing. I opened a discussion for that.