Conversation
Bump libnetwork to 430c00a6a6b3dfdd774f21e1abd4ad6b0216c629. This includes the following moby-affecting changes: * Update vendoring for go-sockaddr (8df9f31a) * Fix inconsistent subnet allocation by preventing allocation of overlapping subnets (8579c5d2) * Handle IPv6 literals correctly in port bindings (474fcaf4) * Update vendoring for miekg/dns (8f307ac8) * Avoid subnet reallocation until required (9756ff7ed) * Bump libnetwork build to use go version 1.10.2 (603d2c1a) * Unwrap error type returned by PluginGetter (aacec8e1) * Update vendored components to match moby (d768021dd) * Add retry field to cluster-peers probe (dbbd06a7) * Fix net driver response loss on createEndpoint (1ab6e506) (fixes docker/for-linux#348) Signed-off-by: Chris Telfer <ctelfer@docker.com>
The TestDockerNetworkIPAMMultipleNetworks test allocates several networks simultaneously with overlapping IP addresses. Libnetwork now forbids this. Adjust the test case to use distinct IP ranges for the networks it creates. Signed-off-by: Chris Telfer <ctelfer@docker.com>
Codecov Report
@@ Coverage Diff @@
## master #37371 +/- ##
==========================================
- Coverage 34.95% 34.94% -0.01%
==========================================
Files 609 609
Lines 44832 44832
==========================================
- Hits 15669 15666 -3
- Misses 27051 27053 +2
- Partials 2112 2113 +1 |
|
Pushed a 2nd commit to adjust a unit test that employed overlapping subnets. |
This may be a breaking change for people using that as a feature, or did this never work properly? |
|
@abhi and @fcrisciani can elaborate, but as I understand it this did not work properly, especially for swarm. In swarm mode it would accept the configuration as allowable, but when trying to create tasks in a service it would fail the network allocation and just leave the service pretty much in limbo. |
|
@thaJeztah do you know the real use case/history of overlapping subnet ? |
|
Not sure if there's a real use case (as in "need to have these networks in the same range"), but (just from the top of my head) thinking of users that have a template / compose file to create networks with an IP-range, and may be using the same template / compose file for multiple stacks. |
|
PowerPC failure looks unrelated; there was an old issue for this test #34988, but should've been fixed by #35173. Not sure if it's a different issue now |
|
@thaJeztah I am not sure if someone would intentionally use the subnet for multiple networks unless they used it accidentally ? |
|
Agreed that it could be accidentally; curious: what happens with existing networks (that have overlapping subnets) after upgrading? |
|
Discussing this with @fcrisciani and @ctelfer; although a corner-case, there may be users out there that currently have overlay network that have an overlapping subnet; for those, it will be needed to re-create the network, so for Docker we need a mention in the changelog |
Bump libnetwork to 430c00a6a6b3dfdd774f21e1abd4ad6b0216c629.
Full diff: moby/libnetwork@19279f0...430c00a
Relevant changes:
overlapping subnets (8579c5d2)
(fixes driver.CreateEndpoint response are going to be lost. docker/for-linux#348)
Signed-off-by: Chris Telfer ctelfer@docker.com