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

NetworkDriver.CreateNetwork: 172.20.0.1/16 has host bits set #7

Open
adrian-stephens opened this issue Dec 2, 2020 · 1 comment
Open

Comments

@adrian-stephens
Copy link

Fresh git clone of project
make install
docker network create -d devplayer0/net-dhcp:latest --ipam-driver=null -o bridge=br0 test-net

returns: Error response from daemon: NetworkDriver.CreateNetwork: 172.20.0.1/16 has host bits set
The address is that of my docker0 network.
644: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
link/ether 02:42:6c:62:49:62 brd ff:ff:ff:ff:ff:ff
inet 172.20.0.1/16 brd 172.20.255.255 scope global docker0
valid_lft forever preferred_lft forever

docker --version: Docker version 19.03.8, build afacb8b7f0

I realise this is not enough to work on. Happy to provide additional information, I'm just not sure what would be useful here.

@devplayer0
Copy link
Owner

Hmmmm, it would seem the Subnet value for the IPAM section of the built-in Docker network has an IP set somehow (my Python code assumes it's only ever a CIDR subnet without the host bits set). The Go code I've written so far should ™️ account for this.

reserved_nets = set(map(ipaddress.ip_network, map(lambda c: c['Subnet'], \

I'll see if I can reproduce this behaviour with Docker on my end and test it. If you're still interested, would you mind describing your Docker environment (OS, have you made any config changes etc).

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

No branches or pull requests

2 participants