[2.0b8] Unable to set default gateway interface
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
High
|
Unassigned | ||
2.0 |
Fix Released
|
High
|
Unassigned |
Bug Description
Hi there
I am testing MAAS 2.0 in a proof of concept environment, and my networking configuration looks like this:
eno1: MAAS PXE interface, untagged, MAAS DHCP managed
eno2: Office/Internet facing interface, untagged, external DHCP
bond0: Multiple tagged VLAN interfaces for workload segregation, all managed by MAAS DHCP
This naming and configuration is shared by the MAAS node and by the nodes it manages. By default after acquiring, commissioning and deploying a node, eno1 is set as the default gateway interface but I would like eno2 to be the default.
Attached is the output of:
"maas xxx interfaces read 4y3h7q"
where "4y3h7q" is one of the nodes managed by MAAS, but the output for eno2 specifically is:
{
"params": "",
"links": [
{
},
}
],
"tags": [],
"vlan": {
"name": "untagged",
"mtu": 1500,
"id": 5013,
"vid": 0,
},
"name": "eno2",
{
},
}
],
"type": "physical",
"children": [],
"id": 43,
"parents": [],
"enabled": true
},
Attempting to set the default gateway interface of the node via:
"maas XXX interface set-default-gateway 4y3h7q 43"
results in the following:
{"__all__": ["This interface has no usable gateways."]}
Attempting to provide the link_id via:
"maas XXX interface set-default-gateway 4y3h7q 43 link_id=101"
results in:
{"link_id": ["'101' is not a valid link_id. It should be one of: ."], "__all__": ["This interface has no usable gateways."]}
If you need any further debugging, logs or info please let me know, and thanks!
Matthew
edit: edited for clarity of the commands used and their output
Related branches
- Gavin Panella (community): Approve
-
Diff: 39 lines (+17/-1)2 files modifiedsrc/maasserver/forms_interface_link.py (+4/-1)
src/maasserver/tests/test_forms_interface_link.py (+13/-0)
- Blake Rouse (community): Approve
-
Diff: 39 lines (+17/-1)2 files modifiedsrc/maasserver/forms_interface_link.py (+4/-1)
src/maasserver/tests/test_forms_interface_link.py (+13/-0)
Changed in maas: | |
importance: | Undecided → High |
milestone: | none → 2.0.0 |
status: | New → In Progress |
milestone: | 2.0.0 → 2.1.0 |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
status: | Fix Committed → Fix Released |
milestone: | 2.0.1 → none |
The issue here is that your are trying to set the default gateway to an interface that is set to DHCP. MAAS in this case will not allow you because we have no way of saying this interface should have the default gateway since it will DHCP. To better understand think of the case where you had 2 interfaces that you wanted to DHCP, we have no way to ensure that the gateway from the DHCP server will be set as the default, either one of those interfaces could be set as the default gateway.