-
Notifications
You must be signed in to change notification settings - Fork 18.7k
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
dockerd now requires ip6tables to startup #47895
Comments
We discussed that during the last libnet maintainers call. While this is a breaking change, it might not be as bad as it looks.
'automatic module loading' is already required for Starting with v27.0, users doing DinD with a host Docker daemon < v27.0 or with its Anyway, we'll improve error handling here to allow the daemon to start and instead barf out on network creation if users want an IPv6 network, ip6tables wasn't disabled and the kernel module isn't available. |
Is Also does this require changes in the official DIND image? cc @tianon |
No, I don't think we need to change anything in our packaging:
For the |
We also use a fake shim for We have had a lot of fun with nftables vs xtables (because it's impossible to detect the state of the host accurately from within a container, but if you guess wrong things won't work at best and will break the host at worst; search for nftables/iptables/xtables in our recent issues/PRs if you're curious about the details), but generally this shouldn't be any more broken for any of our users than they might've been before; to put that another way, anyone who is working today, should still be working after this change. 👍 |
Hi all, Does it look similar to the OP's question? |
Hi @hellt ... the issues here should be fixed - the DinD container will try to trigger the host to load the How are you trying to create the rules, and where? Or, do you mean the inner dockerd won't create IPv6 enabled networks, because it can't create its ip6tables rules? What errors are you seeing? |
thanks for coming back @robmry My app is a Go wrapper around docker/moby with a dep on In my app I create a docker network before spawning containers, the network uses both v4 and v6 addresses - I see the error when I run my app in GitHub Codespaces VM. In particular this is the error that I see:
Note, that I do not get this error, if I use docker-ce 26.1.4. Below are the info and version outputs captured from the DinD installation in Github Codespaces VM
|
Thanks @hellt ... if you're not enabling or disabling In that case, if you explicitly disable ip6tables in 27.x you should get the old behaviour. That's (That's all a bit general because I've not played with Codespaces, so don't know what it looks like. It sounds like you've got access to a VM, not a container, and that VM has docker installed ... is that the version you've shown above? Then you're running a DinD image in the VM, and creating an IPv6 network inside the DinD image fails? Does creating an IPv6 enabled bridge network directly in the VM work?) |
@robmry yes, I think my problem is that ip6_tables kernel module is simply not available in the GitHub Codespaces VM... But I might clearly lack the expertise to verify that. If you want to check it out firsthand, then this link - https://github.com/codespaces/new?hide_repo_select=true&ref=test-codespaces-ipv6&repo=894548369&skip_quickstart=true&machine=basicLinux32gb&devcontainer_path=.devcontainer%2Fdocker-in-docker%2Fdevcontainer.json&geo=EuropeWest - will open up the github codespaces launch menu where you can click the region you want to boot a VM in and this will start building a CodeSpaces VM with DinD 27.3.1 in it. It is free for all GitHub account holders and limited to 120 cpu-hours/mo I am not sure if this is a "proper" VM, maybe a micro-vm. It uses the same infra as GitHub actions hosted runners. Most likely I won't be ablet to respin the Is there a way to disable ip6 rule setup from the API perspective? |
Interesting, thank you! I haven't quite figured out how it all fits together ... but running So, if you can persuade that command to run before the docker daemon starts via your devcontainer config, it should be ok - running it after dockerd starts is no good, because dockerd doesn't initialise its ip6tables properly. Also, the entrypoint script |
Thanks a lot @robmry I will see if at first we could fix the moby azure packages #48987 so that I can pin to 26.1.4 for some more months. |
Ah, yes - thank you ... that does look like an option that'll end up setting the env-var. Loading the I'll ask around in Docker too, others will know a lot more about this stuff than I do. |
Description
With the code recently merged to master dockerd now requires ip6tables in order to start.
This is a new requirement that is almost certainly a breaking change as it even broke my vanilla Ubuntu 22.04 setup (w/ Azure kernel) since the ip6_tables module was not being loaded at startup.
Reproduce
N/A
Expected behavior
No response
docker version
docker info
Additional Info
No response
The text was updated successfully, but these errors were encountered: