Ask Your Question

Openvswitch VLAN tagged external uplink

asked 2015-05-07 04:16:41 -0500

anonymous user


updated 2015-05-08 01:02:08 -0500


We have a OpenStack environment with 4 compute nodes and 2 network nodes. All of them is running CentOS with OpenStack Juno.

We use GRE for tunnels with tenant networks (tenant_network_types=gre). What we want to do is have VLAN tagged uplinks for our external network (that goes up to our external production routers).

This is what I currently have, but I have some questions because it's not working correctly. The VLAN we want to use for external uplink is 2652. Bond1 is the CentOS bond of physical 10gbit interface p2p1 and p2p2.


type_drivers = vlan,gre,flat
tenant_network_types = gre
mechanism_drivers = openvswitch
network_vlan_ranges = external:2652:2654
local_ip =
enable_tunneling = True
network_vlan_ranges = external:2652:2654
bridge_mappings = external:br-ex


debug = False
verbose = True
interface_driver = neutron.agent.linux.interface.OVSInterfaceDriver
use_namespaces = True
external_network_bridge = br-ex
router_delete_namespaces = True
agent_mode = legacy


Bridge br-ex
        Port patch-to-br-uplink
            Interface patch-to-br-uplink
                type: patch
                options: {peer=patch-to-br-ex}
        Port phy-br-ex
            Interface phy-br-ex
                type: patch
                options: {peer=int-br-ex}
        Port "qg-e104cb7c-e2"
            Interface "qg-e104cb7c-e2"
                type: internal
        Port br-ex
            Interface br-ex
                type: internal


Bridge br-uplink
        Port patch-to-br-ex
            Interface patch-to-br-ex
                type: patch
                options: {peer=patch-to-br-uplink}
        Port "bond1"
            trunks: [2652]
            Interface "bond1"
        Port br-uplink
            Interface br-uplink
                type: internal

Created with commands like this:

ovs-vsctl add-br br-ex
ovs-vsctl add-br br-uplink
ovs-vsctl add-port br-uplink bond1
ovs-vsctl set port bond1 vlan_mode=trunk trunk=2652
ovs-vsctl add-port br-ex patch-to-br-uplink
ovs-vsctl add-port br-uplink patch-to-br-ex
ovs-vsctrl set interface patch-to-br-uplink type=patch options:peer=patch-to-br-ex
ovs-vsctl set interface patch-to-br-ex type=patch options:peer=patch-to-br-uplink

Do I need to set the VLAN on the patch ports or will they be trunks automatically?

To create the network in OpenStack I did the following, edit ml2 config on controller node and run command

type_drivers = flat,vlan,gre
tenant_network_types = gre
mechanism_drivers = openvswitch
network_vlan_ranges = external:2652:2654

Creating the network

neutron net-create public --router:external True --provider:physical_network external --provider:network_type vlan --provider:segmentation_id 2652 --shared


[root@controller ~]# neutron net-show public
| Field                     | Value                                |
| admin_state_up            | True                                 |
| id                        | 9fc39c41-57eb-48d6-9240-340f7771d746 |
| name                      | public                               |
| provider:network_type     | vlan                                 |
| provider:physical_network | external                             |
| provider:segmentation_id  | 2652                                 |
| router:external           | True                                 |
| shared                    | True                                 |
| status                    | ACTIVE                               |
| subnets                   | fe11ce91-4360-4be9-9648-ba8750481c83 |
| tenant_id                 | e7b79b45a67e4dc1908a459e98da6afb     |

What am I missing? Do I need to make the patch ports between br-uplink and br-ex to trunks with VLAN 2652? Why is the gateway for my router in br-ex not tagged with VLAN 2652, should it not be? (see below)

Bridge br-ex
        Port "qg-e104cb7c-e2"
            Interface "qg-e104cb7c-e2"
                type: internal

Thanks for any help. Best regards

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2015-05-07 09:07:15 -0500

jdexter gravatar image

In the l3-agent.ini, set "external_network_bridge ="

edit flag offensive delete link more


Hello jdexter, Thanks for your reply.

The external_network_bridge is already set in l3_agent.ini on the network nodes. external_network_bridge = br-ex

I have added the complete l3_agent.ini to the answer. Any other clues?

Tobias Urdin gravatar imageTobias Urdin ( 2015-05-08 01:01:31 -0500 )edit

Oh I should explictly set "external_network_bridge =" in l3_agent.ini Doesn't seem to make any difference tho, I have recreated the router, must I recreate the external network too?

Tobias Urdin gravatar imageTobias Urdin ( 2015-05-08 02:43:22 -0500 )edit

The solution for my problem was to set the following in l3_agent.ini on the network nodes and also making sure the ml2 configuration on the controller nodes where identical.

external_network_bridge =

gateway_external_network_id =

Thanks to jdexter!

Tobias Urdin gravatar imageTobias Urdin ( 2015-05-08 03:50:20 -0500 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower


Asked: 2015-05-07 04:16:41 -0500

Seen: 4,411 times

Last updated: May 08 '15