Open mathias-ioki opened 3 months ago
Can take a look
@dcantah thx for taking care! Do you already have an update on this topic? Looks like, there was already some implementation for that back in the days: https://github.com/containerd/containerd/blob/841c693710531d1de475de191f5b1c17cc5faba7/pkg/cri/server/sandbox_run.go#L339-L345 Not sure, if this is helpful or related at all.
@mathias-ioki I'm looking tonight, should have an update tomorrow morning
@mathias-ioki Can you try out https://github.com/containerd/containerd/pull/10400? It seems to properly save the IP info after restart now, but I'm just doing local crictl testing.
Hey @dcantah, I was able to test your change now and looks really good! I can't reproduce the issue anymore with your fix included.
The version of my containerd build looks a bit odd (containerd github.com/containerd/containerd/v2 v1.3.0-8814-g51dbc981d 51dbc981dd8b4623130dbc60ea7ed86fe7fad66e
), but I guess this is "normal". If it really would be an old version, namespaces wouldn't work at all.
Anyway, many thanks for looking into it!
Description
We are using containerd (2.0) in combination with standalone kubelet and user namespaces.
When we do a restart of containerd and after that a restart of kubelet, all pods are getting restarted as well. The reason for that is pretty much the same as described here: https://github.com/containerd/containerd/issues/7843
After restarting containerd, all network informations for the pod sandbox are gone. As kubelet is checking these infos at start and can't find them, it will force a re-create of the sandbox.
But this happens only in combination with user namespaces. Without enabling user namespaces, everything works as expected.
Steps to reproduce the issue
Describe the results you received and expected
Result I get:
Result I expect:
What version of containerd are you using?
containerd github.com/containerd/containerd/v2 v2.0.0-rc.3 27de5fea738a38345aa1ac7569032261a6b1e562
Any other relevant information
Tested with runc release candidate and latest crun:
Show configuration if it is related to CRI plugin.