Hi guys,
running into a new issue for me. Have docker installed on Debian. All containers running fine in host mode. While in Bridge mode all containers cannot acces internet. Did bash into them. Nameserver is set correctly. Cannot Ping towards domain nor ip. Did rebuild bridge which did not solve the problem. Any help is greatly appreciated.
“nameserver 127.0.0.11” is just fine, if the dns server in the hosts /etc/resolv.conf points to a valid dns server that is able to resolve the query (in other words: if name resolution works on the host, it should do the same in the container). Sounds like something doesn’t work as suppossed in docker’s network magic. Can you tell wether your system uses nftables or iptables? See: iptables - Debian Wiki. Afaik, it needs to be iptables. I am not sure wether you need to restart the docker engine after switching to iptables.
I Think i did.
Here is my input file:
{
“iptables”: true,
“default-gateway”: “192.168.2.1”,
“dns”: [“1.1.1.1”, “8.8.8.8”],
“data-root”: “/var/lib/docker”
}
When I restart docker i get the following error:
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2020-06-09 13:12:14 CEST; 8s ago
Docs: https://docs.docker.com
Process: 10937 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
Main PID: 10937 (code=exited, status=1/FAILURE)
Jun 09 13:12:14 TOM-HC1 systemd[1]: docker.service: Service RestartSec=2s expired, scheduling restart.
Jun 09 13:12:14 TOM-HC1 systemd[1]: docker.service: Scheduled restart job, restart counter is at 3.
Jun 09 13:12:14 TOM-HC1 systemd[1]: Stopped Docker Application Container Engine.
Jun 09 13:12:14 TOM-HC1 systemd[1]: docker.service: Start request repeated too quickly.
Jun 09 13:12:14 TOM-HC1 systemd[1]: docker.service: Failed with result ‘exit-code’.
Jun 09 13:12:14 TOM-HC1 systemd[1]: Failed to start Docker Application Container Engine.
I even cannot make the file original. Docker stil does not start. I have to do a reinstall basiclly in the webinterface:
Docker storage :: /var/lib/docker
Agent port:: 8000
Web port:: 9000
Opt-out :: 1
arch :: armhf
option :: docker
state :: install
extras :: 5.3.3
DNS OK.
Create override file …
Reload systemd daemon …
Skipping docker restart.
Done.
Your daemon.json looks about right. Though, I didn’t add any of those settings to my daemon.json. Mine only has data-root and a couple of settings to trim and locate the json logs.
There is definitly something fishy. I won’t be of any help here… good luck!