Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serialize non-atomic jump rule programming in bridge #1658

Merged
merged 1 commit into from
Feb 22, 2017
Merged

Serialize non-atomic jump rule programming in bridge #1658

merged 1 commit into from
Feb 22, 2017

Conversation

aboch
Copy link
Contributor

@aboch aboch commented Feb 21, 2017

Related to moby/moby/issues/25393

  • The per-host same iptables rule programming done by ensureJumpRule()
    is processed for each network create.
    Concurrent networks creations sometimes exposes the non-atomicity of the
    function causing the network creation to fail.
  • I opted for a minimal impact fix which serializes the function executions.

Signed-off-by: Alessandro Boch aboch@docker.com

@sanimej
Copy link

sanimej commented Feb 22, 2017

We do something similar for DOCKER-INGRESS chain in the filter table, https://github.com/docker/libnetwork/blob/master/controller.go#L744

I think this needs to be taken care of as well.

@aboch
Copy link
Contributor Author

aboch commented Feb 22, 2017

True, but in that case it would just log a warn log and the network creation won't fail.
Although, we may end up with a duplicate rule. I will take care of that. Thanks.

Signed-off-by: Alessandro Boch <aboch@docker.com>
@sanimej
Copy link

sanimej commented Feb 22, 2017

LGTM. CI is complete, but the status still shows its running.. merging..

@sanimej sanimej merged commit 530e1d9 into moby:master Feb 22, 2017
@tomwillfixit
Copy link

Thanks for this. We run 5 docker-compose ups concurrently and we hit this error intermittently "unable to remove jump to DOCKER-ISOLATION rule in FORWARD chain: (iptables failed: iptables --wait -D FORWARD -j DOCKER-ISOLATION: iptables: No chain/target/match by that name." Applied this fix and haven't encountered the issue since.

@thaJeztah
Copy link
Member

cherry-pick for 17.03.2 #1750

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants