1) Inspect the kubelet service to find the container runtime endpoint
Show the kubelet process line and filter for the container runtime flag:- The container runtime endpoint configured for this cluster is:
unix:///var/run/containerd/containerd.sock
You can also inspect the kubelet systemd unit or the kubelet config file (
/var/lib/kubelet/config.yaml) to confirm the container-runtime-endpoint value.2) Path containing CNI plugin binaries
CNI plugin binaries are typically stored in/opt/cni/bin. List the directory to view the installed plugin binaries:
- The path configured for CNI plugin binaries is:
/opt/cni/bin
3) Identify which plugin from the list is not available
From the/opt/cni/bin listing above, many common plugins are present such as bridge, flannel, portmap, and vlan. The plugin named cisco is not present in the listing.
Answer:
- The plugin that is not available on the host is:
cisco
If a plugin referenced in your network configuration conflist is missing from
/opt/cni/bin, pod networking may fail. Ensure required binaries are installed and have executable permissions.4) Determine which CNI plugin is configured for the cluster
Check the CNI network configuration directory:- The CNI plugin configured for this Kubernetes cluster is
flannel. The conflist also includes theportmapplugin to support port mappings.
- When a pod sandbox is created, the container runtime (via the kubelet and CRI) will invoke the CNI plugin binaries listed in the conflist, in order. For this conflist the runtime will execute:
/opt/cni/bin/flannel- then
/opt/cni/bin/portmap(to handle container port mappings)
"type" entries in the conflist and must be present in /opt/cni/bin for CNI setup to succeed.
Quick summary
Links and references
- kubelet reference — Kubernetes documentation
- Container Network Interface (CNI) specification
- Flannel GitHub repository
- ContainerD project