MAAS 1.8 fails to find a cluster interface when an off-network node boots

Bug #1519177 reported by Mike Pontillo on 2015-11-24
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
High
Mike Pontillo

Bug Description

Observed behavior[1]:

  File "/usr/lib/python2.7/dist-packages/metadataserver/api.py", line 450, in read
    user_data = get_curtin_userdata(node)
  File "/usr/lib/python2.7/dist-packages/maasserver/preseed.py", line 226, in get_curtin_userdata
    network_config = compose_curtin_network_preseed_for(node)
  File "/usr/lib/python2.7/dist-packages/maasserver/networking_preseed.py", line 356, in compose_curtin_network_preseed_for
    'netmasks': map_netmasks(node),
  File "/usr/lib/python2.7/dist-packages/maasserver/networking_preseed.py", line 334, in map_netmasks
    interfaces, IPAddress(sip.ip))
  File "/usr/lib/python2.7/dist-packages/maasserver/models/macaddress.py", line 69, in find_cluster_interface_responsible_for_ip
    if ip_address in interface.network:
TypeError: argument of type 'NoneType' is not iterable

Expected behavior:

MAAS finds the cluster interface based on the fact that it is within an unmanged dynamic range.

[1]:
http://paste.ubuntu.com/13487469/

Related branches

Mike Pontillo (mpontillo) wrote :

After I worked around this issue (by changing find_cluster_interface_responsible_for_ip() to ignore networks whose value is None, and checking the static/dynamic range for each cluster interface), I found that I could not delete nodes on this unmanaged subnet, because I would get this error:

Node failed to be deleted, because of the following error: DHCPv4 server is disabled.

From regiond.log:

2015-11-23 19:31:44 [HTTPChannel,0,172.16.100.10] Unhandled Error
        Traceback (most recent call last):
        Failure: provisioningserver.rpc.exceptions.CannotRemoveHostMap: DHCPv4 server is disabled.

Mike Pontillo (mpontillo) wrote :

It turns out that I was getting that error because I had originally deployed with a static range defined on that cluster interface (which MAAS does not support for unmanaged interfaces).

Since I only had one node on this MAAS, I was able to fix the situation by doing some minor surgery on the database and removing the rows in the following two tables:

maasserver_macstaticipaddresslink
maasserver_staticipaddress

While MAAS 1.9 is able to deploy onto a static range for an unmanaged interface, MAAS 1.8 should ignore the static range on unmanaged interfaces.

Changed in maas:
milestone: none → 1.8.4
Mike Pontillo (mpontillo) wrote :

By the way, in order to test this (by putting my MAAS server on a routable host on a different subnet than a DD-WRT router), I configured the following under "Additional DNSMasq Options" in DD-WRT (under the "Services" page):

dhcp-boot=pxelinux.0,,172.16.100.10

Where 172.16.100.10 was the IP address of my MAAS server.

Since MAAS does not allow configuring a cluster interface without an interface name, the interface name "bogus0" was able to get me going.

Changed in maas:
assignee: nobody → Mike Pontillo (mpontillo)
Changed in maas:
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers