You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[rootless] bridge network degrading ending in failure to expose port #3488
nerdctl run -d --name bar -p 5003:80 nginx
6c1fa26eba42ff417d193acd3b7097ba33a3764a8a52efad49c4a1a99c8c4435
curl localhost:5003
curl: (56) Recv failure: Connection reset by peer
This is specific to that port - that has been used (past tense) by other containers (not specific to 5003 - just specific to whichever port has been used heavily).
It looks like after these containers got destroyed, something in cni (?) does not completely release the port (maybe in iptables?).
This is tricky to reproduce - I usually trigger this with repeatedly running test suite.
changed the title [-]Bridge network degrading ending in failure to expose port[/-][+][rootless] bridge network degrading ending in failure to expose port[/+]on Oct 2, 2024
I have been running qkboy patch for a few hours.
It is making things better, but is not a full fix, and I still end-up with the same issue(s) in the end.
At this point, I am not convinced that the PR opened on cni plugins will fully address this - I think containers get destroyed without iptables NAT entries getting cleaned - either inside the CNI plugins, or somehow inside nerdctl.
To be completely honest, oci-hooks + binary networking plugins does not feel like a good solution.
oci-hooks are confusing to use, and do not properly allow for full lifecycle management (there is no "onStop", actually "onStop" == "onDelete"), and whatever happens in cni plugins between bridge and firewall is heinous to debug.
Anyhow, once done with the testing cleanup, rethinking/fixing networking should be top priority (along with login...).
Activity
apostasie commentedon Oct 2, 2024
Restarting containerd does fix the issue - until repeat usage will trigger it again.
@AkihiroSuda is containerd maintaining the list of mapped ports?
Any pointer for me on this issue?
[-]Bridge network degrading ending in failure to expose port[/-][+][rootless] bridge network degrading ending in failure to expose port[/+]apostasie commentedon Oct 2, 2024
I am very much out of my comfort zone.
Is this just the rootless variant of #3253 ?
AkihiroSuda commentedon Oct 2, 2024
No, the daemon doesn't care about ports
Maybe?
apostasie commentedon Oct 3, 2024
@AkihiroSuda
I have been running qkboy patch for a few hours.
It is making things better, but is not a full fix, and I still end-up with the same issue(s) in the end.
apostasie commentedon Oct 3, 2024
Notes.
Clearly, the issue comes from iptables getting clobbered.
This:
With
./reset_iptables.shWill immediately fix the issue when it happens.
At this point, I am not convinced that the PR opened on cni plugins will fully address this - I think containers get destroyed without iptables NAT entries getting cleaned - either inside the CNI plugins, or somehow inside nerdctl.
To be completely honest, oci-hooks + binary networking plugins does not feel like a good solution.
oci-hooks are confusing to use, and do not properly allow for full lifecycle management (there is no "onStop", actually "onStop" == "onDelete"), and whatever happens in cni plugins between bridge and firewall is heinous to debug.
Anyhow, once done with the testing cleanup, rethinking/fixing networking should be top priority (along with login...).