k8snetworkplumbingwg / multus-cni

A CNI meta-plugin for multi-homed pods in Kubernetes
Apache License 2.0
2.36k stars 585 forks source link

multus v4 thick mode breaks NetworkAttachmentDefinition with CNI config file #1238

Closed leerin-ruby closed 3 months ago

leerin-ruby commented 7 months ago

What happend: I used multus + istio cni for app sidecar injection, while for the injection, pod reports error with "ERRORED: error configuring pod [nrd/nrd-v1-77c6dbbd48-586x5] networking: Multus: [nrd/nrd-v1-77c6dbbd48-586x5/4c1a126c-c889-472e-9e44-46193c8cfaa3]: error loading k8s delegates k8s args: TryLoadPodDelegates: error in getting k8s network for pod: GetNetworkDelegates: failed getting the delegate: GetCNIConfig: err in GetCNIConfigFromFile: no network available in the name istio-cni in cni dir /host/etc/cni/net.d"

Seems multus CNI directory where other CNI that is used by multus as net-attach-def without config was changed from "/etc/cni/multus/net.d" to "/host/etc/cni/net.d" in multus v4 thick mode.

What you expected to happen: keep the directory as "/etc/cni/multus/net.d" the same as v3 and v4 thin mode

How to reproduce it (as minimally and precisely as possible): install multus v4 thick install istio with cni enabled install a app with sidecar injection

Anything else we need to know?: from the source code, seems the "confDir" in deamonset config is change to "/host/etc/cni/net.d" in v4.0.2 and was removed in master

Environment: tanzu2.5

dougbtv commented 6 months ago

I think that what you should do is modify the daemonset to add another mount point that points at /etc/cni/multus/net.d

github-actions[bot] commented 3 months ago

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.