Skip to main content

neutron-bsdbridge

Neutron ML2 mechanism driver, L2 agent, DHCP agent and L3 agent for FreeBSD based on if_bridge(4) and pf(4).

Status

Features

  • ML2 mechanism driver that binds ports with vif_type=bridge and publishes to Nova
  • Implements one bridge per Neutron segment for vlan, flat, vxlan and local networks.
  • L2 agent to manage bridge, taps and security group rules
  • Port security with allowed address pairs
  • DHCP agent running one dnsmasq per network inside separate VNET jails
  • L3 agent running each router inside a VNET jail with SNAT, floating IPs and port forwarding
  • IPv6 subnets in SLAAC, DHCPv6 stateless and DHCPv6 stateful modes, with router advertisements from rtadvd(8) in the router jail
  • IPv6 security group rules and source address filtering

Roadmap

  • metadata agent
  • HA routers (CARP+pfsync)
  • prevent ARP spoofing in port security

Limitations

  • Distributed routers are unlikely to ever be supported
  • Tenant vxlan networks do not forward application broadcast or multicast traffic - only ARP, DHCPv4, DHCPv6 and IPv6 neighbour discovery is relayed
  • A port with port security sends IPv6 only from its fixed addresses, its allowed address pairs and the link-local address derived from its MAC
  • A router takes its IPv6 default route from the gateway of the external subnet, not from router advertisements

Host requirements

Make sure to configure net.link.bridge.pfil_member=1 on the host.

Add to the host pf.conf:

set state-policy if-bound
ether anchor "l2-neutron/port/*"
anchor "l2-neutron/port/*"

For vxlan networks, port 4789 must be open on the host underlay interface (the one assigned [vxlan] local_ip in the config) and allow loopback traffic for the relay service. The L2 agent keeps the tunnel addresses of the other hosts in the l2-neutron-vtep table:

table <l2-neutron-vtep> persist
pass in on vtnet0 proto udp from <l2-neutron-vtep> to port 4789
pass out on vtnet0 proto udp to port 4789
pass on lo0 proto udp to 127.0.0.1

Configuration

neutron.conf

[DEFAULT]
service_plugins = router

ml2_conf.ini

[ml2]
mechanism_drivers = bsdbridge

bsdbridge_agent.ini

[bsdbridge]
physical_interface_mappings = physnet1:ix0

Map the physical network name in OpenStack to the actual uplink/trunk interfaces on the host.

For vlan networks, the L2 agent will create a vlan interface on top of the mapped physical interface and plug it to the respective bridge for you, but make sure that the actual network trunks those VLAN between hosts.

Tenant networks with vlan

You can enable self-service/tenant networks based on VLANs by configuring a range of IDs that can be used:

[ml2]
tenant_network_types = vlan

[ml2_type_vlan]
network_vlan_ranges = physnet1:100:199

Now any networks created in non-admin projects will be allocated a vlan segment automatically (the ix0.<vid> uplink is created and plugged by the L2 agent). Same as above, ensure that the network fabric actually trunks this range of VLAN IDs to the interface on each host which is mapped in physical_interface_mappings.

Tenant networks with vxlan

It is usually better to enable self-service/tenant networks using vxlan, the only requirement is that the hosts can reach each other on UDP port 4789, routed or not.

Set local_ip to the IP assigned to the underlay network interface:

bsdbridge_agent.ini

[vxlan]
local_ip = 192.168.50.150

Enable the vxlan relay on every host running the L2 agent, it runs as the neutron user:

sysrc neutron_bsdbridge_vxlan_relay_enable=YES

Enable the l2population mechanism driver, set the tenant network type to vxlan and configure the VNI range:

ml2_conf.ini

[ml2]
mechanism_drivers = bsdbridge,l2population
type_drivers = local,flat,vlan,vxlan
tenant_network_types = vxlan

[ml2_type_vxlan]
vni_ranges = 1:65535

Note that the MTU in a vxlan neutron network is 1450. If you need a 1500 MTU inside the guests, you can do it by setting global_physnet_mtu = 1550 and enable jumbo frames on the underlay network.

IPv6

In OpenStack tenant IPv6 subnets are routed without translation and there is no support for SNAT or floating IPs for IPv6.

The external network has to route tenant prefixes to the router, either with static routes or with BGP using neutron-dynamic-routing.

Metadata

Release files for neutron-bsdbridge 0.9.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for neutron-bsdbridge 0.9.6
File Size Uploaded Provenance Actions
neutron_bsdbridge-0.9.6.tar.gz 52.4 kB Without provenance Details for neutron_bsdbridge-0.9.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for neutron-bsdbridge 0.9.6
File Interpreter ABI Platform Actions
neutron_bsdbridge-0.9.6-py3-none-any.whl Python 3 none any Details for neutron_bsdbridge-0.9.6-py3-none-any.whl

Total release size: 114.2 kB

Release files / neutron_bsdbridge-0.9.6.tar.gz

Download URL neutron_bsdbridge-0.9.6.tar.gz
Size 52.4 kB
Tags Source
SHA-256 checksum
How to use checksums
7a37532bd0975c0f2854e3cdff21332e93aa3c729e6b0f9d16df5fc63e1d6efb
BLAKE2b-256 checksum
How to use checksums
98f032fd78765abc5bbe682abe02a0a71a58f4a3cc4f5a6ad592427104367778
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / neutron_bsdbridge-0.9.6-py3-none-any.whl

Download URL neutron_bsdbridge-0.9.6-py3-none-any.whl
Size 61.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9290a6ef240c4aa85906e37791bfc7c9a0a640da9c3a79e3b506db401397807f
BLAKE2b-256 checksum
How to use checksums
024545c010e31ebf060291fb6ddd1897b88adc2ddf57e82ac916b80e768215a8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for neutron-bsdbridge 0.9.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page