clean:
rm -rf *~ *.deb *.changes ${PACKAGE}-* *.buildinfo *.dsc *.tar.gz
-.PHONY: check
-check:
- $(MAKE) -C test check
+.PHONY: test
+test:
+ $(MAKE) -C test
.PHONY: install
install:
--- /dev/null
+all: test
+
+test: test_zones
+
+test_zones: run_test_zones.pl
+ ./run_test_zones.pl
--- /dev/null
+Here a sample of command with pvesh to manage the sdn.
+
+
+#create a vlan transportzone
+pvesh create /cluster/sdn/zones/ --zone vlanzone --type vlan --ipam pve --bridge vmbr0
+#create a vnet on vlanzone
+pvesh create /cluster/sdn/vnets/ --vnet vnet100 --type vnet --zone vlanzone --tag 100
+#create a subnet on vlanzone
+pvesh create /cluster/sdn/vnets/vnet100/subnets/ --type subnet --subnet 192.168.0.0/24 --gateway 192.168.0.1
+
+
+#create a layer2 vxlan unicast transportzone
+pvesh create /cluster/sdn/zones/ --zone vxlanunicastzone --type vxlan --ipam pve --peers 192.168.0.1,192.168.0.2,192.168.0.3
+
+#create an evpn controller
+pvesh create /cluster/sdn/controllers/ --controller evpn1 --type evpn --peers 192.168.0.1,192.168.0.2,192.168.0.3 --asn 1234
+
+#add a ebgp peer
+pvesh create /cluster/sdn/controllers/ --controller bgp1 --type bgp --peers 192.168.0.253,192.168.0.254 --asn 1234 --ebgp --node pxnode1
+
+#create a layer2 vxlan bgpevpn transportzone
+pvesh create /cluster/sdn/zones/ --zone layer2evpnzone --type evpn --ipam pve --controller evpn1
+
+#create a layer3 routable vxlan bgpevpn transportzone + exit-nodes
+pvesh create /cluster/sdn/zones/ --zone layer3evpnzone --type evpn --ipam pve --controller evpn1 --vrf-vxlan 4000 --exit-nodes pxnode1,pxnode2
+
+
+
+#create a vnet in the transportzone
+pvesh create /cluster/sdn/vnets/ --vnet vnet10 --type vnet --zone vlanzone --tag 10
+
+#create a vnet in the transportzone with subnets for evpn routing
+pvesh create /cluster/sdn/vnets/ --vnet vnet11 --type vnet --zone layer3evpnzone --tag 11 --mac c8:1f:66:f8:62:8d
+pvesh create /cluster/sdn/vnets/vnet11/subnets/ --type subnet --subnet 10.0.0.0/24 --gateway 10.0.0.1
+pvesh create /cluster/sdn/vnets/ --vnet vnet12 --type vnet --zone layer3evpnzone --tag 12 --mac c8:1f:66:f8:62:8e
+pvesh create /cluster/sdn/vnets/vnet11/subnets/ --type subnet --subnet 10.0.1.0/24 --gateway 10.0.1.1
+
+#display running configuration
+pvesh get /cluster/sdn/vnets --running
+pvesh get /cluster/sdn/zones --running
+pvesh get /cluster/sdn/controllers --running
+pvesh get /cluster/sdn/vnets/vnetX/subnets --running
+
+
+#display pending configuration
+pvesh get /cluster/sdn/vnets --pending
+pvesh get /cluster/sdn/zones --pending
+pvesh get /cluster/sdn/controllers --pending
+pvesh get /cluster/sdn/vnets/vnetX/subnets --pending
+
+
+#apply changes from /etc/pve/sdn.cfg.new to /etc/pve/sdn.cfg
+pvesh set /cluster/sdn
+
+
+#generate local /etc/network/interfaces.d/sdn and reload (need to be called on each node)
+ pvesh set /nodes/<node>/network
+
+
+display transporzone status on all cluster nodes
+#pvesh get /cluster/resources
+┌────────────────────────────────────┬─────────┬───────┬───────────┬─────────┬───────┬────────┬─────────────┬────────────┬────────────┬───────────────┬──────┬───────────┬──────────────┬────────────────┐
+│ id │ type │ cpu │ disk │ hastate │ level │ maxcpu │ maxdisk │ maxmem │ mem │ node │ pool │ status │ storage │ uptime │
+│ sdn/node1/transportzone10 │ sdn │ │ │ │ │ │ │ │ │ kvmformation1 │ │ error │ │ │
+├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
+│ sdn/node1/zone1 │ sdn │ │ │ │ │ │ │ │ │ node1 │ │ available │ │ │
+├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
+│ sdn/node1/zone4 │ sdn │ │ │ │ │ │ │ │ │ node1 │ │ available │ │ │
+├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
+
+
+
+
+#list all transport zones of a node
+
+pvesh get /nodes/<node>/sdn/zones/
+ ┌─────────────────┬───────────┐
+ │ sdn │ status │
+ ├─────────────────┼───────────┤
+ │ transportzone10 │ error │
+ ├─────────────────┼───────────┤
+ │ zone1 │ available │
+ ├─────────────────┼───────────┤
+ │ zone4 │ available │
+ └─────────────────┴───────────┘
+
+
+#list all vnet status from a node transportzone
+
+pveset get /nodes/<node>/sdn/zones/<transportzone>/content
+
+ ┌─────────┬────────┐
+ │ vnet │ status │
+ ├─────────┼────────┤
+ │ vnet100 │ error │
+ ├─────────┼────────┤
+ │ vnet101 │ error │
+ └─────────┴────────┘
+
+
+
+
--- /dev/null
+use strict;
+use warnings;
+use File::Copy;
+use PVE::Cluster qw(cfs_read_file);
+
+use PVE::Network::SDN;
+use PVE::Network::SDN::Zones;
+use PVE::Network::SDN::Controllers;
+use Data::Dumper;
+
+PVE::Network::SDN::commit_config();
+my $network_config = PVE::Network::SDN::Zones::generate_etc_network_config();
+
+PVE::Network::SDN::Zones::write_etc_network_config($network_config);
+print "/etc/network/interfaces.d/sdn\n";
+print $network_config;
+print "\n";
+
+my $controller_config = PVE::Network::SDN::Controllers::generate_controller_config();
+
+if ($controller_config) {
+ print Dumper($controller_config);
+ PVE::Network::SDN::Controllers::write_controller_config($controller_config);
+}
--- /dev/null
+use strict;
+use warnings;
+use PVE::Network::SDN;
+use Data::Dumper;
+
+my ($transport_status, $vnet_status) = PVE::Network::SDN::status();
+
+print Dumper($vnet_status);
+print Dumper($transport_status);
+++ /dev/null
-Here a sample of command with pvesh to manage the sdn.
-
-
-#create a vlan transportzone
-pvesh create /cluster/sdn/zones/ --zone vlanzone --type vlan --ipam pve --bridge vmbr0
-#create a vnet on vlanzone
-pvesh create /cluster/sdn/vnets/ --vnet vnet100 --type vnet --zone vlanzone --tag 100
-#create a subnet on vlanzone
-pvesh create /cluster/sdn/vnets/vnet100/subnets/ --type subnet --subnet 192.168.0.0/24 --gateway 192.168.0.1
-
-
-#create a layer2 vxlan unicast transportzone
-pvesh create /cluster/sdn/zones/ --zone vxlanunicastzone --type vxlan --ipam pve --peers 192.168.0.1,192.168.0.2,192.168.0.3
-
-#create an evpn controller
-pvesh create /cluster/sdn/controllers/ --controller evpn1 --type evpn --peers 192.168.0.1,192.168.0.2,192.168.0.3 --asn 1234
-
-#add a ebgp peer
-pvesh create /cluster/sdn/controllers/ --controller bgp1 --type bgp --peers 192.168.0.253,192.168.0.254 --asn 1234 --ebgp --node pxnode1
-
-#create a layer2 vxlan bgpevpn transportzone
-pvesh create /cluster/sdn/zones/ --zone layer2evpnzone --type evpn --ipam pve --controller evpn1
-
-#create a layer3 routable vxlan bgpevpn transportzone + exit-nodes
-pvesh create /cluster/sdn/zones/ --zone layer3evpnzone --type evpn --ipam pve --controller evpn1 --vrf-vxlan 4000 --exit-nodes pxnode1,pxnode2
-
-
-
-#create a vnet in the transportzone
-pvesh create /cluster/sdn/vnets/ --vnet vnet10 --type vnet --zone vlanzone --tag 10
-
-#create a vnet in the transportzone with subnets for evpn routing
-pvesh create /cluster/sdn/vnets/ --vnet vnet11 --type vnet --zone layer3evpnzone --tag 11 --mac c8:1f:66:f8:62:8d
-pvesh create /cluster/sdn/vnets/vnet11/subnets/ --type subnet --subnet 10.0.0.0/24 --gateway 10.0.0.1
-pvesh create /cluster/sdn/vnets/ --vnet vnet12 --type vnet --zone layer3evpnzone --tag 12 --mac c8:1f:66:f8:62:8e
-pvesh create /cluster/sdn/vnets/vnet11/subnets/ --type subnet --subnet 10.0.1.0/24 --gateway 10.0.1.1
-
-#display running configuration
-pvesh get /cluster/sdn/vnets --running
-pvesh get /cluster/sdn/zones --running
-pvesh get /cluster/sdn/controllers --running
-pvesh get /cluster/sdn/vnets/vnetX/subnets --running
-
-
-#display pending configuration
-pvesh get /cluster/sdn/vnets --pending
-pvesh get /cluster/sdn/zones --pending
-pvesh get /cluster/sdn/controllers --pending
-pvesh get /cluster/sdn/vnets/vnetX/subnets --pending
-
-
-#apply changes from /etc/pve/sdn.cfg.new to /etc/pve/sdn.cfg
-pvesh set /cluster/sdn
-
-
-#generate local /etc/network/interfaces.d/sdn and reload (need to be called on each node)
- pvesh set /nodes/<node>/network
-
-
-display transporzone status on all cluster nodes
-#pvesh get /cluster/resources
-┌────────────────────────────────────┬─────────┬───────┬───────────┬─────────┬───────┬────────┬─────────────┬────────────┬────────────┬───────────────┬──────┬───────────┬──────────────┬────────────────┐
-│ id │ type │ cpu │ disk │ hastate │ level │ maxcpu │ maxdisk │ maxmem │ mem │ node │ pool │ status │ storage │ uptime │
-│ sdn/node1/transportzone10 │ sdn │ │ │ │ │ │ │ │ │ kvmformation1 │ │ error │ │ │
-├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
-│ sdn/node1/zone1 │ sdn │ │ │ │ │ │ │ │ │ node1 │ │ available │ │ │
-├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
-│ sdn/node1/zone4 │ sdn │ │ │ │ │ │ │ │ │ node1 │ │ available │ │ │
-├────────────────────────────────────┼─────────┼───────┼───────────┼─────────┼───────┼────────┼─────────────┼────────────┼────────────┼───────────────┼──────┼───────────┼──────────────┼────────────────┤
-
-
-
-
-#list all transport zones of a node
-
-pvesh get /nodes/<node>/sdn/zones/
- ┌─────────────────┬───────────┐
- │ sdn │ status │
- ├─────────────────┼───────────┤
- │ transportzone10 │ error │
- ├─────────────────┼───────────┤
- │ zone1 │ available │
- ├─────────────────┼───────────┤
- │ zone4 │ available │
- └─────────────────┴───────────┘
-
-
-#list all vnet status from a node transportzone
-
-pveset get /nodes/<node>/sdn/zones/<transportzone>/content
-
- ┌─────────┬────────┐
- │ vnet │ status │
- ├─────────┼────────┤
- │ vnet100 │ error │
- ├─────────┼────────┤
- │ vnet101 │ error │
- └─────────┴────────┘
-
-
-
-
+++ /dev/null
-use strict;
-use warnings;
-use File::Copy;
-use PVE::Cluster qw(cfs_read_file);
-
-use PVE::Network::SDN;
-use PVE::Network::SDN::Zones;
-use PVE::Network::SDN::Controllers;
-use Data::Dumper;
-
-PVE::Network::SDN::commit_config();
-my $network_config = PVE::Network::SDN::Zones::generate_etc_network_config();
-
-PVE::Network::SDN::Zones::write_etc_network_config($network_config);
-print "/etc/network/interfaces.d/sdn\n";
-print $network_config;
-print "\n";
-
-my $controller_config = PVE::Network::SDN::Controllers::generate_controller_config();
-
-if ($controller_config) {
- print Dumper($controller_config);
- PVE::Network::SDN::Controllers::write_controller_config($controller_config);
-}
--- /dev/null
+#!/usr/bin/perl
+
+use strict;
+use warnings;
+
+use lib qw(..);
+use File::Slurp;
+
+use Test::More;
+use Test::MockModule;
+
+use PVE::Network::SDN;
+use PVE::Network::SDN::Zones;
+use PVE::Network::SDN::Controllers;
+use PVE::INotify;
+
+sub read_sdn_config {
+ my ($file) = @_;
+
+ # Read structure back in again
+ open my $in, '<', $file or die $!;
+ my $sdn_config;
+ {
+ local $/; # slurp mode
+ $sdn_config = eval <$in>;
+ }
+ close $in;
+
+ return $sdn_config;
+}
+
+
+my @tests = grep { -d } glob './zones/*/*';
+
+foreach my $test (@tests) {
+
+ my $sdn_config = read_sdn_config ("./$test/sdn_config");
+
+ open my $fh1, '<', "./$test/interfaces" or die "can't read interfaces file";
+ my $interfaces_config = PVE::INotify::__read_etc_network_interfaces($fh1, undef, undef);
+ close $fh1;
+
+ my $pve_common_inotify;
+ $pve_common_inotify = Test::MockModule->new('PVE::INotify');
+ $pve_common_inotify->mock(
+ nodename => sub {
+ return 'localhost';
+ },
+ read_file => sub {
+ return $interfaces_config;
+ },
+ );
+
+ my $pve_sdn_subnets;
+ $pve_sdn_subnets = Test::MockModule->new('PVE::Network::SDN::Subnets');
+ $pve_sdn_subnets->mock(
+ config => sub {
+ return $sdn_config->{subnets};
+ },
+ );
+
+ my $pve_sdn_zones_plugin;
+ $pve_sdn_zones_plugin = Test::MockModule->new('PVE::Network::SDN::Zones::Plugin');
+ $pve_sdn_zones_plugin->mock(
+ get_local_route_ip => sub {
+ my $outiface = "vmbr0";
+ my $outip = $interfaces_config->{ifaces}->{$outiface}->{address};
+ return ($outip, $outiface);
+ },
+ is_vlanaware => sub {
+ return $interfaces_config->{ifaces}->{vmbr0}->{'bridge_vlan_aware'};
+ },
+ is_ovs => sub {
+ return 1 if $interfaces_config->{ifaces}->{vmbr0}->{'type'} eq 'OVSBridge';
+ },
+ get_bridge_ifaces => sub {
+ return ('eth0');
+ },
+ find_bridge => sub {
+ return;
+ }
+ );
+
+ my $sdn_module = Test::MockModule->new("PVE::Network::SDN");
+ $sdn_module->mock(
+ config => sub {
+ return $sdn_config;
+ },
+ );
+
+ my $name = $test;
+ my $expected = read_file("./$test/expected_sdn_interfaces");
+
+ my $result = "";
+ eval {
+ $result = PVE::Network::SDN::Zones::generate_etc_network_config();
+ };
+
+ if (my $err = $@) {
+ fail($name);
+ } else {
+ is ($result, $expected, $name);
+ }
+
+ if ($sdn_config->{controllers}) {
+ my $expected = read_file("./$test/expected_controller_config");
+ my $controller_rawconfig = "";
+
+ eval {
+ my $config = PVE::Network::SDN::Controllers::generate_controller_config();
+ $controller_rawconfig = PVE::Network::SDN::Controllers::generate_controller_rawconfig($config);
+ };
+
+ if (my $err = $@) {
+ fail($name);
+ } else {
+ is ($controller_rawconfig, $expected, $name);
+ }
+ }
+}
+
+done_testing();
+
+
+++ /dev/null
-use strict;
-use warnings;
-use PVE::Network::SDN;
-use Data::Dumper;
-
-my ($transport_status, $vnet_status) = PVE::Network::SDN::status();
-
-print Dumper($vnet_status);
-print Dumper($transport_status);
--- /dev/null
+log syslog informational
+ip forwarding
+ipv6 forwarding
+frr defaults datacenter
+service integrated-vtysh-config
+hostname localhost
+!
+!
+vrf vrf_myzone
+ vni 1000
+exit-vrf
+!
+router bgp 65001
+ bgp router-id 192.168.0.1
+ no bgp default ipv4-unicast
+ coalesce-time 1000
+ neighbor VTEP peer-group
+ neighbor VTEP remote-as external
+ neighbor VTEP bfd
+ neighbor 192.168.0.2 peer-group VTEP
+ neighbor 192.168.0.3 peer-group VTEP
+ no bgp ebgp-requires-policy
+ neighbor BGP peer-group
+ neighbor BGP remote-as external
+ neighbor BGP bfd
+ neighbor 192.168.0.252 peer-group BGP
+ neighbor 192.168.0.253 peer-group BGP
+ !
+ address-family ipv4 unicast
+ neighbor BGP activate
+ neighbor BGP soft-reconfiguration inbound
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ neighbor VTEP activate
+ advertise-all-vni
+ autort as 65000
+ exit-address-family
+!
+router bgp 65001 vrf vrf_myzone
+ no bgp ebgp-requires-policy
+ !
+ address-family l2vpn evpn
+ route-target import 65000:1000
+ route-target export 65000:1000
+ exit-address-family
+!
+line vty
+!
\ No newline at end of file
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrf_myzone
+iface vrf_myzone
+ vrf-table auto
+
+auto vrfbr_myzone
+iface vrfbr_myzone
+ bridge-ports vrfvx_myzone
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrfvx_myzone
+iface vrfvx_myzone
+ vxlan-id 1000
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", zone => "myzone" },
+ },
+ },
+
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "evpn", controller => "evpnctl", 'vrf-vxlan' => 1000 } },
+ },
+ controllers => {
+ ids => {
+ evpnctl => { type => "evpn", 'peers' => '192.168.0.1,192.168.0.2,192.168.0.3', asn => "65000" },
+ localhost => { type => "bgp", 'peers' => '192.168.0.252,192.168.0.253', ebgp => "1", asn => "65001", node => "localhost" },
+ },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ }
+ }
+ }
+}
+
+
--- /dev/null
+log syslog informational
+ip forwarding
+ipv6 forwarding
+frr defaults datacenter
+service integrated-vtysh-config
+hostname localhost
+!
+!
+vrf vrf_myzone
+ vni 1000
+exit-vrf
+!
+router bgp 65001
+ bgp router-id 192.168.0.1
+ no bgp default ipv4-unicast
+ coalesce-time 1000
+ neighbor VTEP peer-group
+ neighbor VTEP remote-as external
+ neighbor VTEP bfd
+ neighbor VTEP ebgp-multihop 10
+ neighbor VTEP update-source dummy1
+ neighbor 192.168.0.2 peer-group VTEP
+ neighbor 192.168.0.3 peer-group VTEP
+ no bgp ebgp-requires-policy
+ bgp disable-ebgp-connected-route-check
+ neighbor BGP peer-group
+ neighbor BGP remote-as external
+ neighbor BGP bfd
+ neighbor 172.16.0.254 peer-group BGP
+ neighbor 172.17.0.254 peer-group BGP
+ !
+ address-family ipv4 unicast
+ network 192.168.0.1/32
+ neighbor BGP activate
+ neighbor BGP soft-reconfiguration inbound
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ neighbor VTEP activate
+ advertise-all-vni
+ autort as 65000
+ exit-address-family
+!
+router bgp 65001 vrf vrf_myzone
+ no bgp ebgp-requires-policy
+ !
+ address-family l2vpn evpn
+ route-target import 65000:1000
+ route-target export 65000:1000
+ exit-address-family
+!
+line vty
+!
\ No newline at end of file
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrf_myzone
+iface vrf_myzone
+ vrf-table auto
+
+auto vrfbr_myzone
+iface vrfbr_myzone
+ bridge-ports vrfvx_myzone
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrfvx_myzone
+iface vrfvx_myzone
+ vxlan-id 1000
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
--- /dev/null
+auto eth0
+iface eth0 inet static
+ address 172.16.0.1/24
+
+auto eth1
+iface eth1 inet static
+ address 172.17.0.1/24
+
+auto dummy1
+iface dummy1 inet static
+ address 192.168.0.1/32
+ link-type dummy
+
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", zone => "myzone" },
+ },
+ },
+
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "evpn", controller => "evpnctl", 'vrf-vxlan' => 1000 } },
+ },
+ controllers => {
+ ids => {
+ evpnctl => { type => "evpn", 'peers' => '192.168.0.1,192.168.0.2,192.168.0.3', asn => "65000" },
+ localhost => { type => "bgp", 'peers' => '172.16.0.254,172.17.0.254', ebgp => "1", asn => "65001", loopback => 'dummy1', node => "localhost" },
+ },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ }
+ }
+ }
+}
+
+
--- /dev/null
+log syslog informational
+ip forwarding
+ipv6 forwarding
+frr defaults datacenter
+service integrated-vtysh-config
+hostname localhost
+!
+!
+vrf vrf_myzone
+ vni 1000
+exit-vrf
+!
+router bgp 65000
+ bgp router-id 192.168.0.1
+ no bgp default ipv4-unicast
+ coalesce-time 1000
+ neighbor VTEP peer-group
+ neighbor VTEP remote-as 65000
+ neighbor VTEP bfd
+ neighbor 192.168.0.2 peer-group VTEP
+ neighbor 192.168.0.3 peer-group VTEP
+ !
+ address-family ipv4 unicast
+ import vrf vrf_myzone
+ exit-address-family
+ !
+ address-family ipv6 unicast
+ import vrf vrf_myzone
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ neighbor VTEP activate
+ advertise-all-vni
+ exit-address-family
+!
+router bgp 65000 vrf vrf_myzone
+ !
+ address-family ipv4 unicast
+ redistribute connected
+ exit-address-family
+ !
+ address-family ipv6 unicast
+ redistribute connected
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ default-originate ipv4
+ default-originate ipv6
+ exit-address-family
+!
+line vty
+!
\ No newline at end of file
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrf_myzone
+iface vrf_myzone
+ vrf-table auto
+
+auto vrfbr_myzone
+iface vrfbr_myzone
+ bridge-ports vrfvx_myzone
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrfvx_myzone
+iface vrfvx_myzone
+ vxlan-id 1000
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", zone => "myzone" },
+ },
+ },
+
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "evpn", controller => "evpnctl", 'vrf-vxlan' => 1000, exitnodes => { 'localhost' => 1 } } },
+ },
+ controllers => {
+ ids => { evpnctl => { type => "evpn", 'peers' => '192.168.0.1,192.168.0.2,192.168.0.3', asn => "65000" } },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ }
+ }
+ }
+}
+
+
--- /dev/null
+log syslog informational
+ip forwarding
+ipv6 forwarding
+frr defaults datacenter
+service integrated-vtysh-config
+hostname localhost
+!
+!
+vrf vrf_myzone
+ vni 1000
+exit-vrf
+!
+router bgp 65000
+ bgp router-id 192.168.0.1
+ no bgp default ipv4-unicast
+ coalesce-time 1000
+ neighbor VTEP peer-group
+ neighbor VTEP remote-as 65000
+ neighbor VTEP bfd
+ neighbor 192.168.0.2 peer-group VTEP
+ neighbor 192.168.0.3 peer-group VTEP
+ !
+ address-family ipv4 unicast
+ import vrf vrf_myzone
+ exit-address-family
+ !
+ address-family ipv6 unicast
+ import vrf vrf_myzone
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ neighbor VTEP activate
+ advertise-all-vni
+ exit-address-family
+!
+router bgp 65000 vrf vrf_myzone
+ !
+ address-family ipv4 unicast
+ redistribute connected
+ exit-address-family
+ !
+ address-family ipv6 unicast
+ redistribute connected
+ exit-address-family
+ !
+ address-family l2vpn evpn
+ default-originate ipv4
+ default-originate ipv6
+ exit-address-family
+!
+line vty
+!
\ No newline at end of file
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j SNAT --to-source 192.168.0.1
+ post-down iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j SNAT --to-source 192.168.0.1
+ post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
+ post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrf_myzone
+iface vrf_myzone
+ vrf-table auto
+
+auto vrfbr_myzone
+iface vrfbr_myzone
+ bridge-ports vrfvx_myzone
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrfvx_myzone
+iface vrfvx_myzone
+ vxlan-id 1000
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", zone => "myzone" },
+ },
+ },
+
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "evpn", controller => "evpnctl", 'vrf-vxlan' => 1000, exitnodes => { 'localhost' => 1 } } },
+ },
+ controllers => {
+ ids => { evpnctl => { type => "evpn", 'peers' => '192.168.0.1,192.168.0.2,192.168.0.3', asn => "65000" } },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ 'snat' => 1
+ }
+ }
+ }
+}
+
+
--- /dev/null
+log syslog informational
+ip forwarding
+ipv6 forwarding
+frr defaults datacenter
+service integrated-vtysh-config
+hostname localhost
+!
+!
+vrf vrf_myzone
+ vni 1000
+exit-vrf
+!
+router bgp 65000
+ bgp router-id 192.168.0.1
+ no bgp default ipv4-unicast
+ coalesce-time 1000
+ neighbor VTEP peer-group
+ neighbor VTEP remote-as 65000
+ neighbor VTEP bfd
+ neighbor 192.168.0.2 peer-group VTEP
+ neighbor 192.168.0.3 peer-group VTEP
+ !
+ address-family l2vpn evpn
+ neighbor VTEP activate
+ advertise-all-vni
+ exit-address-family
+!
+router bgp 65000 vrf vrf_myzone
+!
+line vty
+!
\ No newline at end of file
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrf_myzone
+iface vrf_myzone
+ vrf-table auto
+
+auto vrfbr_myzone
+iface vrfbr_myzone
+ bridge-ports vrfvx_myzone
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+ vrf vrf_myzone
+
+auto vrfvx_myzone
+iface vrfvx_myzone
+ vxlan-id 1000
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan-local-tunnelip 192.168.0.1
+ bridge-learning off
+ bridge-arp-nd-suppress on
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", zone => "myzone" },
+ },
+ },
+
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "evpn", controller => "evpnctl", 'vrf-vxlan' => 1000 } },
+ },
+ controllers => {
+ ids => { evpnctl => { type => "evpn", 'peers' => '192.168.0.1,192.168.0.2,192.168.0.3', asn => "65000" } },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ }
+ }
+ }
+}
+
+
--- /dev/null
+#version:1
+
+auto cv_myvnet
+iface cv_myvnet
+ vlan-raw-device sv_myvnet
+ vlan-id 100
+
+auto myvnet
+iface myvnet
+ bridge_ports cv_myvnet
+ bridge_stp off
+ bridge_fd 0
+
+auto sv_myvnet
+iface sv_myvnet
+ vlan-raw-device eth0
+ vlan-id 10
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports vmbr0.10
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
+ bridge-vids 2-4094
+ bridge-vlan-aware 1
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports vmbr0.10
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
+ bridge-vids 2-4094
+ bridge-vlan-aware 1
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", vlanaware => "1", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+
+auto vmbr0
+iface vmbr0
+ bridge-vlan-protocol 802.1ad
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports vmbr0.10
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
+ bridge-vids 2-4094
+ bridge-vlan-aware 1
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, 'vlan-protocol' => '802.1ad', ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto cv_myvnet
+iface cv_myvnet
+ vlan-raw-device sv_myvnet
+ vlan-id 100
+
+auto myvnet
+iface myvnet
+ bridge_ports cv_myvnet
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
+
+auto sv_myvnet
+iface sv_myvnet
+ vlan-raw-device eth0
+ vlan-id 10
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", vlanaware => "1", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto cv_myvnet
+iface cv_myvnet
+ vlan-raw-device sv_myvnet
+ vlan-id 100
+
+auto myvnet
+iface myvnet
+ bridge_ports cv_myvnet
+ bridge_stp off
+ bridge_fd 0
+
+auto sv_myvnet
+iface sv_myvnet
+ vlan-raw-device eth0
+ vlan-id 10
+ vlan-protocol 802.1ad
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, 'vlan-protocol' => '802.1ad', ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+
+auto sv_myzone
+iface sv_myzone
+ ovs_type OVSIntPort
+ ovs_bridge vmbr0
+ ovs_options vlan_mode=dot1q-tunnel tag=10 other_config:qinq-ethtype=802.1q
+
+auto vmbr0
+iface vmbr0
+ ovs_ports sv_myzone
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports sv_myzone
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto eth0
+iface eth0 inet manual
+ ovs_type OVSPort
+ ovs_bridge vmbr0
+
+auto vmbr0
+iface vmbr0 inet manual
+ ovs_type OVSBridge
+ ovs_ports eth0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
+
+auto sv_myzone
+iface sv_myzone
+ ovs_type OVSIntPort
+ ovs_bridge vmbr0
+ ovs_options vlan_mode=dot1q-tunnel tag=10 other_config:qinq-ethtype=802.1q
+
+auto vmbr0
+iface vmbr0
+ ovs_ports sv_myzone
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports sv_myzone
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto eth0
+iface eth0 inet manual
+ ovs_type OVSPort
+ ovs_bridge vmbr0
+
+auto vmbr0
+iface vmbr0 inet manual
+ ovs_type OVSBridge
+ ovs_ports eth0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", vlanaware => "1", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports z_myzone.100
+ bridge_stp off
+ bridge_fd 0
+
+auto sv_myzone
+iface sv_myzone
+ ovs_type OVSIntPort
+ ovs_bridge vmbr0
+ ovs_options vlan_mode=dot1q-tunnel tag=10 other_config:qinq-ethtype=802.1ad
+
+auto vmbr0
+iface vmbr0
+ ovs_ports sv_myzone
+
+auto z_myzone
+iface z_myzone
+ bridge-stp off
+ bridge-ports sv_myzone
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto eth0
+iface eth0 inet manual
+ ovs_type OVSPort
+ ovs_bridge vmbr0
+
+auto vmbr0
+iface vmbr0 inet manual
+ ovs_type OVSBridge
+ ovs_ports eth0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", tag => 10, 'vlan-protocol' => '802.1ad', ipam => "pve", type => "qinq" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports none
+ bridge_stp off
+ bridge_fd 0
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "simple" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 192.168.0.1/24
+ bridge_ports none
+ bridge_stp off
+ bridge_fd 0
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "simple" } },
+ },
+
+ subnets => {
+ ids => { 'myzone-192.168.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '192.168.0.1',
+ }
+ }
+ }
+}
+
+
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ address 10.0.0.1/24
+ post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j SNAT --to-source 192.168.0.1
+ post-down iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j SNAT --to-source 192.168.0.1
+ post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
+ post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
+ bridge_ports none
+ bridge_stp off
+ bridge_fd 0
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "simple" } },
+ },
+
+ subnets => {
+ ids => { 'myzone-10.0.0.0-24' => {
+ 'type' => 'subnet',
+ 'vnet' => 'myvnet',
+ 'gateway' => '10.0.0.1',
+ 'snat' => 1
+ }
+ }
+ }
+}
+
+
--- /dev/null
+#version:1
+
+auto ln_myvnet
+iface ln_myvnet
+ link-type veth
+ veth-peer-name pr_myvnet
+
+auto myvnet
+iface myvnet
+ bridge_ports ln_myvnet
+ bridge_stp off
+ bridge_fd 0
+
+auto pr_myvnet
+iface pr_myvnet
+ link-type veth
+ veth-peer-name ln_myvnet
+
+auto vmbr0v100
+iface vmbr0v100
+ bridge_ports eth0.100 pr_myvnet
+ bridge_stp off
+ bridge_fd 0
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", ipam => "pve", type => "vlan" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports vmbr0.100
+ bridge_stp off
+ bridge_fd 0
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
+ bridge-vids 2-4094
+ bridge-vlan-aware 1
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", ipam => "pve", type => "vlan" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports vmbr0.100
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
--- /dev/null
+auto vmbr0
+iface vmbr0 inet manual
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4096
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => "100", type => "vnet", vlanaware => 1, zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", ipam => "pve", type => "vlan" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto ln_myvnet
+iface ln_myvnet
+ ovs_type OVSIntPort
+ ovs_bridge vmbr0
+ ovs_options tag=100
+
+auto myvnet
+iface myvnet
+ bridge_ports ln_myvnet
+ bridge_stp off
+ bridge_fd 0
+
+auto vmbr0
+iface vmbr0
+ ovs_ports ln_myvnet
--- /dev/null
+auto eth0
+iface eth0 inet manual
+ ovs_type OVSPort
+ ovs_bridge vmbr0
+
+auto vmbr0
+iface vmbr0 inet manual
+ ovs_type OVSBridge
+ ovs_ports eth0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", ipam => "pve", type => "vlan" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto ln_myvnet
+iface ln_myvnet
+ ovs_type OVSIntPort
+ ovs_bridge vmbr0
+ ovs_options vlan_mode=dot1q-tunnel other_config:qinq-ethtype=802.1q tag=100
+
+auto myvnet
+iface myvnet
+ bridge_ports ln_myvnet
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
+
+auto vmbr0
+iface vmbr0
+ ovs_ports ln_myvnet
--- /dev/null
+auto eth0
+iface eth0 inet manual
+ ovs_type OVSPort
+ ovs_bridge vmbr0
+
+auto vmbr0
+iface vmbr0 inet manual
+ ovs_type OVSBridge
+ ovs_ports eth0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", vlanaware => "1", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { bridge => "vmbr0", ipam => "pve", type => "vlan" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan_remoteip 192.168.0.2
+ vxlan_remoteip 192.168.0.3
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "vxlan", peers => "192.168.0.1,192.168.0.2,192.168.0.3" } },
+ },
+}
--- /dev/null
+#version:1
+
+auto myvnet
+iface myvnet
+ bridge_ports vxlan_myvnet
+ bridge_stp off
+ bridge_fd 0
+ bridge-vlan-aware yes
+ bridge-vids 2-4094
+ mtu 1450
+
+auto vxlan_myvnet
+iface vxlan_myvnet
+ vxlan-id 100
+ vxlan_remoteip 192.168.0.2
+ vxlan_remoteip 192.168.0.3
+ mtu 1450
--- /dev/null
+auto vmbr0
+iface vmbr0 inet static
+ address 192.168.0.1/24
+ gateway 192.168.0.254
+ bridge-ports eth0
+ bridge-stp off
+ bridge-fd 0
--- /dev/null
+{
+ version => 1,
+ vnets => {
+ ids => {
+ myvnet => { tag => 100, type => "vnet", vlanaware => "1", zone => "myzone" },
+ },
+ },
+ zones => {
+ ids => { myzone => { ipam => "pve", type => "vxlan", peers => "192.168.0.1,192.168.0.2,192.168.0.3" } },
+ },
+}