[os-net-config] add VLAN interface to OVS bridge
Tony Liu
tonyliu0592 at hotmail.com
Mon May 10 02:17:35 UTC 2021
Hi,
I want to have a VLAN interface on a OVS bridge without tagging.
Can that be done by os-net-config?
I tried couple things.
1) Define a VLAN interface as a member of OVS bridge.
In this case, VLAN interface is created and added on OVS bridge,
but with the tag of VLAN ID.
```
{"network_config": [
{
"type": "ovs_bridge",
"name": "br-test",
"use_dhcp": false,
"addresses": [{"ip_netmask": "10.250.1.5/24"}],
"members": [
{
"type": "vlan",
"device": "eno4",
"vlan_id": 100,
"primary": true
}
]
}
]}
```
2) Define a VLAN interface out of OVS bridge and reference that
VLAN interface as the type of "interface" in the member. This doesn't
work unless the VLAN interface exists before running os-net-config.
```
{"network_config": [
{
"type": "vlan",
"vlan_id": 100,
"device": "eno4",
"addresses": [{"ip_netmask": "10.250.1.5/24"}]
},
{
"type": "ovs_bridge",
"name": "br-test",
"use_dhcp": false,
"members": [
{
"type": "interface",
"name": "vlan100",
"primary": true
}
]
}
]}
```
Anything else I can try?
Thanks!
Tony
More information about the openstack-discuss
mailing list