docker can not delete endpoint when allocateNetwork fail #33470
Labels
area/networking
kind/bug
Bugs are bugs. The cause may or may not be known at triage time so debugging may be needed.
Description
when allocate network for a new container, after CreateEndpoint in daemon/containers_operations.go, docker will call ep.Join to join sandbox, in sbJoin function, according to logic now, it will update endpoint's sandbox info in datastore, if any step fail(in my position, it fails at allocate ports), it just set ep.sandboxID = "", but bot update this info into datastore.
update endpoint info with sanbox in function sbJoin
set ep.sandboxID="" in function sbJoin after any step fails
Describe the results you received:
in my test-integration-cli, this problem cause stale endpoint leave in datastore.
for eg, a container named fail got this problem, and leave endpoint info in datastore, when i want to create a container with name fail, it will got this error
my fix:
i modify my code in function sbJoin , it will fix my problem
I wonder if i am right , can someone help me
Output of
docker version
:i do some modify in my docker, but allocate network logic not have lots different with moby
The text was updated successfully, but these errors were encountered: