L3 agent config option to pass provider:physical_network while creating HA network
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
New
|
Undecided
|
Unassigned |
Bug Description
In a customer environment, they are using sriov and openvswitch like below
mechanism_drivers = openvswitch,
[ml2_type_vlan]
network_
but sriov is enabled only on compute nodes and openvswitch on controllers.
When first HA router is created on a tenant, l3 agent is creating new HA tenant network with segmentation_id from ovs driver.
But when no more vlan ids available on ovs, it is picking up segmentation_id from sriov for later HA tenant networks.
As ovs agent in controllers only supporting ovs and not sriov, binding for HA router network port(i.e device_owner as router_
As HA network creation and HA router creation was succeful, but keepalived was not spawned, confusing admins why it was not spawned.
So we need to enhance l3 agent to pass "provider:
In this case, if l3 agent was able to pass provider:
ion will fail and admin can debug the failure easily.
Binding failure errors
2017-10-24 04:47:04.835 411054 DEBUG neutron.
2017-10-24 04:47:04.836 411054 DEBUG neutron.
2017-10-24 04:47:04.836 411054 ERROR neutron.
[stack@
+------
| Field | Value |
+------
| admin_state_up | True |
| availability_
| availability_zones | |
| created_at | 2017-10-
| description | |
| id | d439f80d-
| ipv4_address_scope | |
| ipv6_address_scope | |
| mtu | 9200 |
| name | HA network tenant ca7ceaf971014d0
| port_security_
| project_id | |
| provider:
| provider:
| provider:
| qos_policy_id | |
| revision_number | 5 |
| router:external | False |
| shared | False |
| status | ACTIVE |
| subnets | 4bdaed16-
| tags | |
| tenant_id | |
| updated_at | 2017-10-
+------
tags: | added: l3-ha |
I want to introduce new l3 agent config options, like PROVIDER_ NETWORK_ TYPE=vlan PROVIDER_ PHYSICAL_ NETWORK= ovs
HA_NETWORK_
HA_NETWORK_
then while creating HA network, l3 agent will pass them like below, at [1]
args = {'network':
{'name' : n_const. HA_NETWORK_ NAME % tenant_id,
'tenant_ id': '',
'shared' : False,
'admin_ state_up' : True}}
if conf.HA_ NETWORK_ PROVIDER_ NETWORK_ TYPE and conf.HA_ NETWORK_ PROVIDER_ PHYSICAL_ NETWORK:
args[ 'provider: network_ type'] = conf.HA_ NETWORK_ PROVIDER_ NETWORK_ TYPE
args[ 'provider: physical_ network' ] = conf.HA_ NETWORK_ PROVIDER_ PHYSICAL_ NETWORK
creation = functools.
[1] https:/ /github. com/openstack/ neutron/ blob/master/ neutron/ db/l3_hamode_ db.py#L224