all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Gabriel Goller <g.goller@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH common/manager/network/proxmox{-ve-rs,-perl-rs,-widget-toolkit} v3 00/28] SDN VRF support
Date: Thu, 19 Nov 2026 20:40:46 +0100	[thread overview]
Message-ID: <20261119194116.575520-1-g.goller@proxmox.com> (raw)

This series adds VRF support to SDN zones and fabrics.

A simple zone can now use either the default VRF or a dedicated VRF. The
simple zone dialog has a checkbox for this and uses the default VRF by
default. If the checkbox is disabled, the zone creates a dedicated VRF named
`vrf_<zone-name>`. EVPN zones always create a dedicated VRF. BGP and OSPF
fabrics can select a zone and run inside its VRF.

This is the second iteration. The first iteration added VRFs as a separate
SDN object with a distinct GUI subdirectory. This was scrapped because VRFs
are an implementation detail and should not be exposed on their own in the
GUI. Zones already provide a logical L3 building block and should map to VRFs
instead.

Route leaking between VRFs partly depends on the following FRR change, so it
will come a bit later: https://github.com/FRRouting/frr/pull/22426

Static routes on simple zones always require Sys.Modify on '/nodes/<node>'
for all nodes of the zone, in addition to SDN.Allocate on the zone. This
applies when creating or deleting a zone with routes, changing its routes,
and changing the nodes or the dedicated-vrf setting of a zone with routes.
Zones without nodes require Sys.Modify on all cluster nodes. Routes can
change the routing of the host, e.g. via a host interface or the default
routing table, so SDN.Allocate alone is not enough.

Host interfaces can be added to a zone VRF in the host network config, which
is local to each node. Disabling dedicated-vrf, removing a node from the zone,
or deleting the zone removes the VRF on that node, but host interfaces may
still reference it. ifreload then fails to enslave the interface and to add
its gateway, and reports this in the apply log. This is not checked on
purpose: the zone API cannot see the network config of other nodes, and the
failure leaves the main routing table untouched. Users have to remove the
VRF from host interfaces before removing the VRF itself.

As always, thanks to Stefan Hanreich for his help.

Changelog:
v3: (thanks @Stefan)
 * removed SNAT (coming in a subsequent series)
 * removed static routes for EVPN zones (coming in a subsequent series)
 * removed the nexthop-vrf property on the routes (coming in a subsequent series)
 * added dhcp-dns-server option in ui
 * made ipv6 unreachable route add fallible
 * some api permission check updates
 * disable vrfs for ovs interfaces and fabric interfaces
 

v2: (thanks @Stefan)
 * allow interfaces to be added to vrfs
 * allow static routes to be configured on vrfs
 * fix ospf vrf statistics
 * fix dhcp
 * fix snat

RFC (v1):
 * rebase


pve-common:

Gabriel Goller (1):
  interfaces: preserve VRF membership across address family changes

 src/PVE/Network/Interfaces.pm | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)


proxmox-ve-rs:

Gabriel Goller (6):
  frr: add VRF-aware OSPF rendering
  sdn: add zone references to OSPF and BGP fabrics
  sdn: generate fabric routing configuration in zone VRFs
  sdn: fix VRF route-map scoping and zone ID validation
  tests: fabrics: add tests for fabrics in VRFs
  sdn: allow static routes in simple zone VRFs

 proxmox-frr-templates/templates/bgpd.jinja    |   7 +-
 .../templates/frr.conf.jinja                  |   3 +-
 .../templates/interface.jinja                 |   6 +-
 .../templates/ip_routes.jinja                 |  13 +-
 proxmox-frr-templates/templates/ospfd.jinja   |  14 +-
 .../templates/protocol_routemaps.jinja        |  13 +
 proxmox-frr/src/ser/mod.rs                    |  27 +-
 proxmox-frr/src/ser/ospf.rs                   |   5 +-
 proxmox-ve-config/src/sdn/fabric/frr.rs       | 123 +++++---
 proxmox-ve-config/src/sdn/fabric/mod.rs       |  24 +-
 .../src/sdn/fabric/section_config/fabric.rs   |  12 +-
 .../sdn/fabric/section_config/protocol/bgp.rs |  10 +
 .../fabric/section_config/protocol/ospf.rs    |  10 +
 proxmox-ve-config/src/sdn/mod.rs              |  12 +
 proxmox-ve-config/src/sdn/static_route.rs     | 181 ++++++++++++
 .../tests/fabric/cfg/vrf/fabrics.cfg          |  43 +++
 .../tests/fabric/cfg/vrf/route-maps.cfg       |  15 +
 .../tests/fabric/cfg/vrf_default/fabrics.cfg  |  37 +++
 .../tests/fabric/cfg/vrf_ipv6/fabrics.cfg     |  25 ++
 .../tests/fabric/cfg/vrf_ipv6/route-maps.cfg  |   7 +
 .../fabric/cfg/vrf_redistribute/fabrics.cfg   |  23 ++
 .../cfg/vrf_redistribute/route-maps.cfg       |   7 +
 .../fabric/cfg/vrf_route_filter/fabrics.cfg   |  23 ++
 .../cfg/vrf_route_filter/prefix-lists.cfg     |   8 +
 proxmox-ve-config/tests/fabric/helper.rs      |  40 +++
 proxmox-ve-config/tests/fabric/main.rs        | 275 +++++++++++++++++-
 .../snapshots/fabric__vrf_default_pve.snap    | 113 +++++++
 .../snapshots/fabric__vrf_ipv6_pve.snap       | 102 +++++++
 .../fabric/snapshots/fabric__vrf_pve.snap     | 134 +++++++++
 .../fabric__vrf_redistribute_pve.snap         |  74 +++++
 .../fabric__vrf_route_filter_pve.snap         |  85 ++++++
 .../tests/static_routes/cfg/fabrics.cfg       |  19 ++
 .../tests/static_routes/cfg/zones.json        |  20 ++
 proxmox-ve-config/tests/static_routes/main.rs | 188 ++++++++++++
 ...c_routes__preserve_legacy_evpn_routes.snap |  12 +
 ...tatic_routes__simple_zone_routes_pve1.snap |  20 ++
 ...tatic_routes__simple_zone_routes_pve2.snap |  10 +
 ...outes__vrf_fabrics_with_static_routes.snap |  70 +++++
 38 files changed, 1739 insertions(+), 71 deletions(-)
 create mode 100644 proxmox-ve-config/src/sdn/static_route.rs
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf/route-maps.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_default/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_ipv6/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_ipv6/route-maps.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_redistribute/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_redistribute/route-maps.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_route_filter/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/cfg/vrf_route_filter/prefix-lists.cfg
 create mode 100644 proxmox-ve-config/tests/fabric/snapshots/fabric__vrf_default_pve.snap
 create mode 100644 proxmox-ve-config/tests/fabric/snapshots/fabric__vrf_ipv6_pve.snap
 create mode 100644 proxmox-ve-config/tests/fabric/snapshots/fabric__vrf_pve.snap
 create mode 100644 proxmox-ve-config/tests/fabric/snapshots/fabric__vrf_redistribute_pve.snap
 create mode 100644 proxmox-ve-config/tests/fabric/snapshots/fabric__vrf_route_filter_pve.snap
 create mode 100644 proxmox-ve-config/tests/static_routes/cfg/fabrics.cfg
 create mode 100644 proxmox-ve-config/tests/static_routes/cfg/zones.json
 create mode 100644 proxmox-ve-config/tests/static_routes/main.rs
 create mode 100644 proxmox-ve-config/tests/static_routes/snapshots/static_routes__preserve_legacy_evpn_routes.snap
 create mode 100644 proxmox-ve-config/tests/static_routes/snapshots/static_routes__simple_zone_routes_pve1.snap
 create mode 100644 proxmox-ve-config/tests/static_routes/snapshots/static_routes__simple_zone_routes_pve2.snap
 create mode 100644 proxmox-ve-config/tests/static_routes/snapshots/static_routes__vrf_fabrics_with_static_routes.snap


proxmox-perl-rs:

Gabriel Goller (5):
  pve-rs: fabrics: assign network interfaces to configured VRFs
  pve-rs: fabrics: make per-fabric status queries VRF-aware
  pve-rs: fabrics: include VRF routes in aggregate status
  pve-rs: fabrics: expose host interface membership
  sdn: expose static routes for simple zone uplinks

 pve-rs/src/bindings/sdn/fabrics.rs | 407 +++++++++++++++++++----------
 pve-rs/src/bindings/sdn/mod.rs     |  18 +-
 pve-rs/src/sdn/status.rs           | 149 +++++++++--
 3 files changed, 402 insertions(+), 172 deletions(-)


pve-network:

Gabriel Goller (10):
  sdn: evpn: add unreachable IPv6 default route to zone VRFs
  sdn: add optional VRFs for simple zones
  sdn: allow fabrics to use simple zone VRFs
  sdn: require underlay fabrics to use the default VRF
  sdn: move full range CIDR formats into a separate module
  sdn: simple: support static routes in zone routing tables
  sdn: dhcp: only configure DHCP for zones on the local node
  sdn: dhcp: run dnsmasq in the zone VRF
  sdn: dhcp: fix DNS server option for IPv4 subnets without gateway
  sdn: evpn: no exit node null routes for simple zone VRFs

 src/PVE/API2/Network/SDN/Fabrics/Fabric.pm    |  56 +++-
 .../API2/Network/SDN/Fabrics/FabricNode.pm    |  20 ++
 src/PVE/API2/Network/SDN/Zones.pm             |  58 ++++
 src/PVE/Network/SDN.pm                        |  22 +-
 src/PVE/Network/SDN/Controllers/BgpPlugin.pm  |   2 +-
 src/PVE/Network/SDN/Controllers/EvpnPlugin.pm |  12 +-
 src/PVE/Network/SDN/Dhcp.pm                   |  14 +-
 src/PVE/Network/SDN/Dhcp/Dnsmasq.pm           |  70 +++-
 src/PVE/Network/SDN/Fabrics.pm                |  49 +++
 src/PVE/Network/SDN/Formats.pm                |  51 +++
 src/PVE/Network/SDN/Makefile                  |   1 +
 src/PVE/Network/SDN/PrefixLists.pm            |  40 +--
 src/PVE/Network/SDN/SubnetPlugin.pm           |   8 +-
 src/PVE/Network/SDN/Zones.pm                  |  59 +++-
 src/PVE/Network/SDN/Zones/EvpnPlugin.pm       |  12 +-
 src/PVE/Network/SDN/Zones/Plugin.pm           |  72 ++++
 src/PVE/Network/SDN/Zones/SimplePlugin.pm     |  33 +-
 src/PVE/Network/SDN/Zones/VxlanPlugin.pm      |   5 +
 src/test/Makefile                             |   8 +-
 src/test/run_test_fabric_host_vrf.pl          |  93 ++++++
 src/test/run_test_static_routes.pl            | 313 ++++++++++++++++++
 src/test/run_test_vnets_blackbox.pl           |  42 +++
 .../advertise_subnets/expected_sdn_interfaces |   1 +
 .../evpn/auto_mode/expected_sdn_interfaces    |   1 +
 .../evpn/bgp_ebgp/expected_sdn_interfaces     |   1 +
 .../bgp_ebgp_multihop/expected_sdn_interfaces |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../evpn/bgp_fabric/expected_sdn_interfaces   |   1 +
 .../evpn/bgp_loopback/expected_sdn_interfaces |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../combined_bgp_isis/expected_sdn_interfaces |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../zones/evpn/ebgp/expected_sdn_interfaces   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   2 +
 .../ebgp_loopback/expected_sdn_interfaces     |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   2 +
 .../evpn/exitnode/expected_sdn_interfaces     |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../exitnode_primary/expected_sdn_interfaces  |   1 +
 .../exitnode_snat/expected_sdn_interfaces     |   1 +
 .../exitnodenullroute/expected_sdn_interfaces |   2 +
 .../expected_controller_config                |  78 +++++
 .../expected_sdn_interfaces                   |  67 ++++
 .../exitnodenullroute_simple_vrf/interfaces   |   7 +
 .../exitnodenullroute_simple_vrf/sdn_config   |  47 +++
 .../frr_local_merge/expected_sdn_interfaces   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../zones/evpn/ipv4/expected_sdn_interfaces   |   1 +
 .../evpn/ipv4ipv6/expected_sdn_interfaces     |   1 +
 .../ipv4ipv6nogateway/expected_sdn_interfaces |   1 +
 .../zones/evpn/ipv6/expected_sdn_interfaces   |   1 +
 .../evpn/ipv6underlay/expected_sdn_interfaces |   1 +
 .../zones/evpn/isis/expected_sdn_interfaces   |   1 +
 .../isis_loopback/expected_sdn_interfaces     |   1 +
 .../multipath_relax/expected_sdn_interfaces   |   1 +
 .../multiplezones/expected_sdn_interfaces     |   2 +
 .../openfabric_fabric/expected_sdn_interfaces |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../evpn/ospf_fabric/expected_sdn_interfaces  |   1 +
 .../evpn/routemap/expected_sdn_interfaces     |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../expected_sdn_interfaces                   |   1 +
 .../evpn/rt_import/expected_sdn_interfaces    |   1 +
 .../evpn/vxlanport/expected_sdn_interfaces    |   1 +
 .../hetzner-vrf/expected_sdn_interfaces       |  27 ++
 src/test/zones/simple/hetzner-vrf/interfaces  |   6 +
 src/test/zones/simple/hetzner-vrf/sdn_config  |  34 ++
 .../simple/vrf-empty/expected_sdn_interfaces  |   7 +
 src/test/zones/simple/vrf-empty/interfaces    |   2 +
 src/test/zones/simple/vrf-empty/sdn_config    |  12 +
 .../zones/simple/vrf/expected_sdn_interfaces  |  14 +
 src/test/zones/simple/vrf/interfaces          |   2 +
 src/test/zones/simple/vrf/sdn_config          |  17 +
 79 files changed, 1330 insertions(+), 78 deletions(-)
 create mode 100644 src/PVE/Network/SDN/Formats.pm
 create mode 100755 src/test/run_test_fabric_host_vrf.pl
 create mode 100644 src/test/run_test_static_routes.pl
 create mode 100644 src/test/zones/evpn/exitnodenullroute_simple_vrf/expected_controller_config
 create mode 100644 src/test/zones/evpn/exitnodenullroute_simple_vrf/expected_sdn_interfaces
 create mode 100644 src/test/zones/evpn/exitnodenullroute_simple_vrf/interfaces
 create mode 100644 src/test/zones/evpn/exitnodenullroute_simple_vrf/sdn_config
 create mode 100644 src/test/zones/simple/hetzner-vrf/expected_sdn_interfaces
 create mode 100644 src/test/zones/simple/hetzner-vrf/interfaces
 create mode 100644 src/test/zones/simple/hetzner-vrf/sdn_config
 create mode 100644 src/test/zones/simple/vrf-empty/expected_sdn_interfaces
 create mode 100644 src/test/zones/simple/vrf-empty/interfaces
 create mode 100644 src/test/zones/simple/vrf-empty/sdn_config
 create mode 100644 src/test/zones/simple/vrf/expected_sdn_interfaces
 create mode 100644 src/test/zones/simple/vrf/interfaces
 create mode 100644 src/test/zones/simple/vrf/sdn_config


proxmox-widget-toolkit:

Gabriel Goller (1):
  ui: network: allow selecting a VRF for host interfaces

 src/node/NetworkEdit.js | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)


pve-manager:

Gabriel Goller (5):
  ui: sdn: add VRF zone selection for fabrics
  network: allow setting the VRF of host interfaces
  ui: sdn: allow static routes for Simple zone VRFs
  network: generate SDN DHCP config after ifreload
  ui: sdn: subnet: allow setting the DHCP DNS server

 PVE/API2/Network.pm                    |  60 +++++--
 bin/pve-sdn-commit                     |   5 +-
 www/manager6/Makefile                  |   1 +
 www/manager6/Toolkit.js                |   2 +-
 www/manager6/form/SDNZoneSelector.js   |  46 ++++-
 www/manager6/node/Config.js            |  12 ++
 www/manager6/sdn/StaticRoutes.js       | 222 +++++++++++++++++++++++++
 www/manager6/sdn/SubnetEdit.js         |  15 ++
 www/manager6/sdn/fabrics/FabricEdit.js |  15 ++
 www/manager6/sdn/zones/Base.js         |  22 ++-
 www/manager6/sdn/zones/SimpleEdit.js   |  21 +++
 11 files changed, 404 insertions(+), 17 deletions(-)
 create mode 100644 www/manager6/sdn/StaticRoutes.js


Summary over all repositories:
  133 files changed, 3907 insertions(+), 339 deletions(-)

-- 
Generated by murpp 0.11.0




             reply	other threads:[~2026-11-19 19:43 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-19 19:40 Gabriel Goller [this message]
2026-11-19 19:40 ` [PATCH pve-common v3 01/28] interfaces: preserve VRF membership across address family changes Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 02/28] frr: add VRF-aware OSPF rendering Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 03/28] sdn: add zone references to OSPF and BGP fabrics Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 04/28] sdn: generate fabric routing configuration in zone VRFs Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 05/28] sdn: fix VRF route-map scoping and zone ID validation Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 06/28] tests: fabrics: add tests for fabrics in VRFs Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-ve-rs v3 07/28] sdn: allow static routes in simple zone VRFs Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-perl-rs v3 08/28] pve-rs: fabrics: assign network interfaces to configured VRFs Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-perl-rs v3 09/28] pve-rs: fabrics: make per-fabric status queries VRF-aware Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-perl-rs v3 10/28] pve-rs: fabrics: include VRF routes in aggregate status Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-perl-rs v3 11/28] pve-rs: fabrics: expose host interface membership Gabriel Goller
2026-11-19 19:40 ` [PATCH proxmox-perl-rs v3 12/28] sdn: expose static routes for simple zone uplinks Gabriel Goller
2026-11-19 19:40 ` [PATCH pve-network v3 13/28] sdn: evpn: add unreachable IPv6 default route to zone VRFs Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 14/28] sdn: add optional VRFs for simple zones Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 15/28] sdn: allow fabrics to use simple zone VRFs Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 16/28] sdn: require underlay fabrics to use the default VRF Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 17/28] sdn: move full range CIDR formats into a separate module Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 18/28] sdn: simple: support static routes in zone routing tables Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 19/28] sdn: dhcp: only configure DHCP for zones on the local node Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 20/28] sdn: dhcp: run dnsmasq in the zone VRF Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 21/28] sdn: dhcp: fix DNS server option for IPv4 subnets without gateway Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-network v3 22/28] sdn: evpn: no exit node null routes for simple zone VRFs Gabriel Goller
2026-11-19 19:41 ` [PATCH proxmox-widget-toolkit v3 23/28] ui: network: allow selecting a VRF for host interfaces Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-manager v3 24/28] ui: sdn: add VRF zone selection for fabrics Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-manager v3 25/28] network: allow setting the VRF of host interfaces Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-manager v3 26/28] ui: sdn: allow static routes for Simple zone VRFs Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-manager v3 27/28] network: generate SDN DHCP config after ifreload Gabriel Goller
2026-11-19 19:41 ` [PATCH pve-manager v3 28/28] ui: sdn: subnet: allow setting the DHCP DNS server Gabriel Goller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261119194116.575520-1-g.goller@proxmox.com \
    --to=g.goller@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal