lxd broker does not handle "No more IPs available" and falls back to lxdbr0
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Fix Released
|
High
|
Unassigned |
Bug Description
I setup a /28 subnet, some IPs are reserved and there is a dynamic range set aside too. The nett result is that there is a limited set of IPs for static address allocation. I added 10 containers:
$ juju add-machine lxd:2 --constraints spaces=teeny
and I see containers on the LXD bridge - which should never happen:
$ juju status
Model Controller Cloud/Region Version
controller maas21-daily maas21-daily 2.1-rc1.3
App Version Status Scale Charm Store Rev OS Notes
Unit Workload Agent Machine Public address Ports Message
Machine State DNS Inst id Series AZ
0 started 172.16.101.201 cn3bat xenial default
2 started 172.16.101.28 67gtpx xenial default
2/lxd/0 started 172.16.106.4 juju-1da816-2-lxd-0 xenial
2/lxd/1 started 172.16.106.6 juju-1da816-2-lxd-1 xenial
2/lxd/2 started 172.16.106.7 juju-1da816-2-lxd-2 xenial
2/lxd/3 started 172.16.106.8 juju-1da816-2-lxd-3 xenial
2/lxd/4 started 172.16.106.9 juju-1da816-2-lxd-4 xenial
2/lxd/5 started 10.0.0.96 juju-1da816-2-lxd-5 xenial
2/lxd/6 started 172.16.106.14 juju-1da816-2-lxd-6 xenial
2/lxd/7 started 172.16.106.5 juju-1da816-2-lxd-7 xenial
2/lxd/8 started 10.0.0.194 juju-1da816-2-lxd-8 xenial
2/lxd/9 started 10.0.0.195 juju-1da816-2-lxd-9 xenial
Looking through the logs I see:
2017-01-13 07:34:58 WARNING juju.provisioner lxd-broker.go:73 failed to prepare container "2/lxd/8" network config: linking device interface "eth0" to subnet "172.16.106.0/28" failed: No more IPs available in subnet: 172.16.106.0/28
We should not fallback to using the lxd bridge.
Changed in juju: | |
assignee: | nobody → Andrew McDermott (frobware) |
Changed in juju: | |
status: | New → Triaged |
importance: | Undecided → High |
milestone: | none → 2.2.0 |
Changed in juju: | |
assignee: | Andrew McDermott (frobware) → nobody |
Changed in juju: | |
milestone: | 2.2-beta1 → 2.2-beta2 |
Changed in juju: | |
milestone: | 2.1.3 → 2.1.2 |
Related bugs: https:/ /bugs.launchpad .net/juju/ +bug/1651886