cni
cni copied to clipboard
Recommended way for CNI plugin logging
Hello CNI maintainers,
I found a similar question that was closed last year: https://github.com/containernetworking/plugins/issues/502, but wanted to ask this in a slightly generic way.
During the process of debugging the CNI plugins in our kubernetes environment (either the commonly used plugins or a few new ones), we found it not so intuitive that the plugin logs aren't always available. When the CNI plugin errors out, there might be more logs available. But in a working case, we don't seem to see any logs during the process (e.g. add network for a pod).
The question being - is there a recommended way for CNI plugin logging (e.g is printing to stdout/stderr sufficient)? Should we expect no logs from the plugin unless the execution fails? Or is there a way to surface informational logs from the plugin if needed?
(I'm also curious if this varies between different calling processes - e.g. dockershim, containerd and others).
Thanks!
cc @sypakine