X-Git-Url: https://git.proxmox.com/?p=pve-docs.git;a=blobdiff_plain;f=vxlan-and-evpn.adoc;h=9cd55fc2d9690d26e7d4426dda486bb9a67b4d25;hp=fd7f27455c5747b2c6d92e944be01d49c527cacd;hb=a45c999b4586734621bbc968d67f87390739b270;hpb=76b6e85702ca4a98efd11d225b9acf9dc7614a45 diff --git a/vxlan-and-evpn.adoc b/vxlan-and-evpn.adoc index fd7f274..9cd55fc 100644 --- a/vxlan-and-evpn.adoc +++ b/vxlan-and-evpn.adoc @@ -16,6 +16,9 @@ while accommodating a very large number of tenants. It is defined in RFC 7348. Each overlay network is known as a VXLAN Segment and identified by a unique 24-bit segment ID called a VXLAN Network Identifier (VNI). +VXLAN encapsulation add 50bytes overhead, so you need to increase mtu on your host +physical interfaces to 1550 at minimum. (or decrease mtu inside your vms to 1450) + For BUM traffic (broadcast / unknown unicast traffic, multicast), we have 3 differents vxlan setup modes : multicast, unicast, bgp-evpn @@ -36,6 +39,7 @@ remote VTEPs will get the packet and answer accordingly direct to the originatin ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -47,6 +51,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -58,6 +63,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -74,6 +80,7 @@ iface vmbr3 inet manual ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -85,6 +92,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -97,6 +105,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -113,6 +122,7 @@ iface vmbr3 inet manual ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -124,6 +134,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -136,6 +147,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-svcnodeip 225.20.1.1 vxlan-physdev eno1 @@ -161,6 +173,7 @@ The VXLAN device will still learn remote addresses automatically using source-ad ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -173,6 +186,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan_remoteip 192.168.0.2 vxlan_remoteip 192.168.0.3 @@ -186,6 +200,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan2 inet manual + vxlan-id 3 vxlan_remoteip 192.168.0.2 vxlan_remoteip 192.168.0.3 @@ -203,6 +218,7 @@ iface vmbr3 inet manual ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -214,6 +230,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan_remoteip 192.168.0.1 vxlan_remoteip 192.168.0.3 @@ -227,6 +244,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan2 inet manual + vxlan-id 3 vxlan_remoteip 192.168.0.1 vxlan_remoteip 192.168.0.3 @@ -244,6 +262,7 @@ iface vmbr3 inet manual ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -255,6 +274,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan_remoteip 192.168.0.2 vxlan_remoteip 192.168.0.3 @@ -268,6 +288,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan2 inet manual + vxlan-id 3 vxlan_remoteip 192.168.0.2 vxlan_remoteip 192.168.0.3 @@ -296,6 +317,7 @@ it's possible to use external bgp route reflector servers. ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -307,6 +329,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -323,6 +346,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -363,6 +387,7 @@ line vty ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -374,6 +399,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -389,6 +415,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -429,6 +456,7 @@ line vty ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -440,6 +468,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -455,6 +484,7 @@ iface vmbr2 inet manual auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -526,6 +556,7 @@ net.ipv6.conf.all.forwarding=1 ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -537,6 +568,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -556,6 +588,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -600,6 +633,7 @@ line vty ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -611,6 +645,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -630,6 +665,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -674,6 +710,7 @@ line vty ---- auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -685,6 +722,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -704,6 +742,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -765,11 +804,6 @@ sysctl.conf tuning #enable routing net.ipv4.ip_forward=1 net.ipv6.conf.all.forwarding=1 -#disable reverse path filtering -net.ipv4.conf.default.rp_filter=0 -net.ipv4.conf.all.rp_filter=0 -#allow frr to work with vrf (kernel >4.14 bug) -net.ipv4.tcp_l3mdev_accept=1 ---- * node1 @@ -781,6 +815,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -792,6 +827,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -810,6 +846,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -829,6 +866,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -890,6 +928,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -901,6 +940,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -919,6 +959,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -938,6 +979,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1000,6 +1042,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1011,6 +1054,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1029,6 +1073,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1048,6 +1093,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1120,6 +1166,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1140,6 +1187,7 @@ iface eno2 auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1158,6 +1206,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1177,6 +1226,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1239,6 +1289,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1250,6 +1301,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1268,6 +1320,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1287,6 +1340,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1349,6 +1403,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1360,6 +1415,7 @@ iface vmbr0 inet static auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1378,6 +1434,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1397,6 +1454,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1467,6 +1525,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1481,12 +1540,14 @@ iface eno2 address 172.16.0.1 netmask 255.255.255.0 vrf vrf1 + mtu 1550 post-up ip route add default via 172.16.0.254 dev eno2 vrf vrf1 #if you have multiple external routers, you can use ecmp balancing #post-up route add default nexthop via 172.16.0.253 dev eno2 vrf vrf1 nexthop via 172.16.0.254 dev eno2 vrf vrf1 auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1505,6 +1566,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1524,6 +1586,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.1 bridge-learning off bridge-arp-nd-suppress on @@ -1586,6 +1649,7 @@ iface vrf1 auto eno1 iface eno1 inet manual + mtu 1550 auto vmbr0 iface vmbr0 inet static @@ -1600,12 +1664,14 @@ iface eno2 address 172.16.0.3 netmask 255.255.255.0 vrf vrf1 + mtu 1550 post-up ip route add default via 172.16.0.254 dev eno2 vrf vrf1 #if you have multiple external routers, you can use ecmp balancing #post-up route add default nexthop via 172.16.0.253 dev eno2 vrf vrf1 nexthop via 172.16.0.254 dev eno2 vrf vrf1 auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1624,6 +1690,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1643,6 +1710,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.2 bridge-learning off bridge-arp-nd-suppress on @@ -1706,7 +1774,8 @@ iface vrf1 auto eno1 iface eno1 inet manual - + mtu 1550 + auto vmbr0 iface vmbr0 inet static address 192.168.0.3 @@ -1720,12 +1789,14 @@ iface eno2 address 172.16.0.3 netmask 255.255.255.0 vrf vrf1 + mtu 1550 post-up ip route add default via 172.16.0.254 dev eno2 vrf vrf1 #if you have multiple external routers, you can use ecmp balancing #post-up route add default nexthop via 172.16.0.253 dev eno2 vrf vrf1 nexthop via 172.16.0.254 dev eno2 vrf vrf1 auto vxlan2 iface vxlan2 inet manual + vxlan-id 2 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1744,6 +1815,7 @@ iface vmbr2 inet static auto vxlan3 iface vxlan3 inet manual + vxlan-id 3 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1763,6 +1835,7 @@ iface vmbr3 inet static #interconnect vxlan-vfr l3vni auto vxlan4000 iface vxlan4000 inet manual + vxlan-id 4000 vxlan-local-tunnelip 192.168.0.3 bridge-learning off bridge-arp-nd-suppress on @@ -1834,6 +1907,7 @@ iface eno2 address 172.16.0.1 netmask 255.255.255.0 vrf vrf1 + mtu 1550 post-up ip route add default via 172.16.0.254 dev eno2 vrf vrf1 vrrp-id 1 vrrp-priority 1 @@ -1847,6 +1921,7 @@ auto eno2 iface eno2 address 172.16.0.2 netmask 255.255.255.0 + mtu 1550 vrf vrf1 post-up ip route add default via 172.16.0.254 dev eno2 vrf vrf1 vrrp-id 1