maas provider assumes machine uses dhcp for eth0

Bug #1361374 reported by Jason Hobbs
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
Critical
Dimiter Naydenov
1.20
Fix Released
Critical
Ian Booth

Bug Description

This is with juju-1.20.5-trusty-amd64

I've configured MAAS to provision a system using static IP addresses. curtins sets up eth0 to be static via /etc/network/interfaces.

When juju starts to setup the system, it fails to setup br0 properly because eth0 is using static, not dhcp. Since juju brings eth0 down first, networking is lost and the system doesn't work.

I also tried having curtin configure br0 itself; juju still brings down eth0, then fails to create br0 because it's already configured, and eth0 is left down.

description: updated
tags: added: addressability maas-provider network
Changed in juju-core:
status: New → Triaged
importance: Undecided → Critical
milestone: none → next-stable
Revision history for this message
Dimiter Naydenov (dimitern) wrote :

In the mid- to long-term juju will be more flexible in the networking setup and allow static IPs and bridges to be configured as needed (not only for MAAS), but this will come along as we implement more of the networking model.

In the short-term, I propose to implement a "safety switch" environment setting (a flag, false by default) "disable-network-management", which when set will prevent juju from trying to configure or manage networking on the machines AT ALL (i.e. the networker will run in safe mode and the maas provider in particular won't change the networking setup during cloudinit). This should fix your immediate issue.

Off-topic: There seems to be some misunderstanding, as as far as I know it was decided to allow juju to manage the networking in a maas environment (at least for this cycle). If both Juju and MAAS try to manage networking there are bound to be issues and we need to work together more closely.

Revision history for this message
John A Meinel (jameinel) wrote :

Just to add a small point.

There is another "be safe in what you do" where if we try to bring something down, and then have a failure, we should *really* try to bring that thing back up again, which I think would actually have fixed the problem here as well.

The other change that I've proposed internally is that we don't try to configure br0 until we actually want LXC machines on a given system, which should also help with this.

Probably this is at least partially hard because we are configuring br0 in cloud init in existing releases, rather than doing it in the agent, though that should be changing for 1.21.

So I'd say we can take a few approaches and we should probably do more than one:

1) our code that tries to configure eth0 should fail safe and not leave eth0 down
2) we can have an environment flag to disable automatic network management
3) we should not reconfigure a bridge until we know that we actually want to put containers on the machine
4) we should be configuring the bridge inside of the jujud agent and not in cloud-init

Changed in juju-core:
assignee: nobody → Dimiter Naydenov (dimitern)
Changed in juju-core:
status: Triaged → In Progress
Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui)
Changed in juju-core:
milestone: next-stable → 1.21-alpha1
Curtis Hovey (sinzui)
Changed in juju-core:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.