Prevent deadlock on --net=container:<self> #12799

Merged
merged 1 commit into from Apr 27, 2015

Conversation

Projects
None yet
4 participants
@aidanhs
Contributor

aidanhs commented Apr 27, 2015

Fixes #12606.
At least, it would have prevented the deadlock I saw.

To be honest, I don't know why there were containers being created on my machine attempting to --net=container:<self> in the first place. Other people have access to the daemon, but inspect output was indicating that the full container id had been used (i.e. --net=container:<cid>) which is obviously impossible because you can't know the cid before you create the container.
So I wonder if there's a second bug which has been auto-populating that field? It'll be interesting to see if people start hitting this new error message.

@aidanhs

This comment has been minimized.

Show comment
Hide comment
@aidanhs

aidanhs Apr 27, 2015

Contributor

cc @LK4D4

Contributor

aidanhs commented Apr 27, 2015

cc @LK4D4

@aidanhs aidanhs changed the title from Prevent deadlock on --net=container:self to Prevent deadlock on --net=container:<self> Apr 27, 2015

@aidanhs

This comment has been minimized.

Show comment
Hide comment
@aidanhs

aidanhs Apr 27, 2015

Contributor

Are windows tests known to be a bit flaky?
TestContainerApiStartVolumesFrom failed (but seemed unrelated) so I pushed a style tweak I wanted anyway and now the windows build is fine...

Contributor

aidanhs commented Apr 27, 2015

Are windows tests known to be a bit flaky?
TestContainerApiStartVolumesFrom failed (but seemed unrelated) so I pushed a style tweak I wanted anyway and now the windows build is fine...

Prevent deadlock on attempt to use own net
Signed-off-by: Aidan Hobson Sayers <aidanhs@cantab.net>
@estesp

This comment has been minimized.

Show comment
Hide comment
@estesp

estesp Apr 27, 2015

Contributor

@aidanhs thanks for updating the test--this is a good catch!

LGTM

Contributor

estesp commented Apr 27, 2015

@aidanhs thanks for updating the test--this is a good catch!

LGTM

@LK4D4

This comment has been minimized.

Show comment
Hide comment
@LK4D4

LK4D4 Apr 27, 2015

Contributor

Lol :)
LGTM

Contributor

LK4D4 commented Apr 27, 2015

Lol :)
LGTM

LK4D4 added a commit that referenced this pull request Apr 27, 2015

Merge pull request #12799 from aidanhs/aphs-fix-net-container-deadlock
Prevent deadlock on --net=container:<self>

@LK4D4 LK4D4 merged commit 02d73d9 into moby:master Apr 27, 2015

3 checks passed

docker/dco-signed All commits signed
Details
janky Jenkins build Docker-PRs 6819 has succeeded
Details
windows Jenkins build Windows-PRs 3782 has succeeded
Details

@aidanhs aidanhs deleted the aidanhs:aphs-fix-net-container-deadlock branch Apr 27, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment