This message was deleted.
# rancher-desktop
a
This message was deleted.
m
I just tried with the daemon.json set to:
Copy code
{
  "default-address-pools": [
    {
      "base": "172.27.0.0/12",
      "size": 20
    },
    {
      "base": "192.168.0.0/16",
      "size": 24
    }
  ]
}
that didn't work either
Any help would be appreciated.
j
I assume you're creating these files inside the rancher desktop WSL distribution? Otherwise it wouldn't make sense. But if you're doing that, I'm not sure how that would affect the host networking. I'm not familiar with Windows networking - @calm-sugar-3169 do you have any idea how to get this to work?
m
Yes, these files are in the WSL2 as I found no other instructions on how to configure it
Ok, I'm not seeing anything posted on how to solve this. I'll have to try either Docker or another alternative to see if I can get it to work
c
@mysterious-controller-97665 have you tried adding the
--bip 192.168.0.0/16
argument directly to dockerd in the docker startup service to see if that makes any difference?
m
@calm-sugar-3169 where would I set that in Rancher? I tried setting that in the /etc/default/docker file in WSL2
r
I'm not sure with Docker Desktop's moby, but when I was having problems with a cluster of CentOS 7 with Docker CE 19 I found https://docs.docker.com/v17.09/engine/userguide/networking/default_network/custom-docker0/ as official doc & https://serverfault.com/questions/916941/configuring-docker-to-not-use-the-172-17-0-0-range mentioned another useful option, so I ended up with
/etc/docker/daemon.json
like:
Copy code
{
  "live-restore": false,
  "bip": "192.168.1.1/24",
  "default-address-pools": [
    {
      "base": "192.168.2.0",
      "size": 24
    },
    {
      "base": "192.168.3.0",
      "size": 24
    }
  ]
}
That worked well enough for me. The docker0: interface in this example would get 192.168.1.0/24 net, and the first two
docker network create
commands would get the other two networks (if something did a third one it'd go back to 172.17.0.1, though so periodically we did end up with odd issues from that).
(This was for a DC/OS cluster, a distribution of Apache Mesos which is cluster orchestration that generally lost to Kubernetes, so that's why I did the live-restore false as well as we were getting zombie containers if the docker daemon got restarted from Mesos starting it elsewhere while the original one was kept alive.)
230 Views