ipspace / netlab

Making virtual networking labs suck less
https://netlab.tools
Other
439 stars 66 forks source link

EVPN support #136

Closed ipspace closed 2 years ago

ipspace commented 2 years ago

I currently have some topologies using additional ansible templates (linked to groups) and extra attributes to obtain a VXLAN EVPN fabric. Not so elegant, but I could use it as a starting point to implement that, but also L2/L3 services, VLANs, VNIs & co. ( https://github.com/ssasso/netsim-topologies/blob/main/evpn_vxlan_01/topology.yml )

This is overall quite a big "feature", and maybe it's better if we track it down on small steps (i.e. with a mini roadmap). I don't think it could be possible to have it for the next releases, but maybe we can track the required small steps on a dedicated task.

Adding simple initial support for MPLS/LDP (i.e., no L2/L3 services) should be simpler (and a good idea) for now, and I will be happy to extend the templates for mikrotik, vyos, and juniper (if you want) - (I will update #60).

Then in the future we could potentially think at a "common codebase" for L2/L3 VPN services, to be used both with MPLS+VPNv4/v6/VPLS and also with EVPN (both MPLS and VXLAN).

Originally posted by @ssasso in https://github.com/ipspace/netsim-tools/issues/124#issuecomment-1006464309

ipspace commented 2 years ago

Comment in #124 by @jbemmel

For VXLAN/EVPN I'm thinking we would need 2 modules:

  • vxlan: VTEP loopback ip, L2/L3 VNI resources and mappings to VLANs, static vxlan tunnels (on some platforms)
  • evpn: BGP address family, L2/L3 VRF, RT/RDs, EVI

In terms of a mini roadmap, I would suggest to start with L2 services (i.e. extend a VLAN across a L3 fabric). In my mind this requires the modeling of 'services' (which is what Service Router OS and Service Router Linux are about)

Comment in #124 by @ipspace

Need a few hiking days to mull it over, but it seems we need:

  • Generic prefix objects (Add "subnet" objects to be used on links, interfaces, nodes, and elsewhere #103)
  • VLAN support (access VLANs, trunks, VLAN/SVI interfaces)
  • First-hop gateway support (VRRP or anycast gateway)
  • Base VXLAN support: VTEPs, mapping of VLANs into VNIs, static ingress replication based on VLAN/VNI membership (easy to generate -- a beauty of abstract data model)
  • VRF support (regardless of whether it's used for VRF Lite, BGP L3VPN or EVPN)
  • EVPN support

When we have VLANs defined, we can add L2 services.

Any volunteers for the first approximation of a VLAN data model?

ssasso commented 2 years ago

I started the VLAN discussion on a dedicated thread: #143

jbemmel commented 2 years ago

After testing some things out, I ended up with a Minimum Viable Product for the evpn module - which simply enables the EVPN BGP family.

I'm thinking the broader L2/L3 service constructs on top may require a 'service' model / framework, we can leave it as separate scripts in the examples for now

ipspace commented 2 years ago

VXLAN support has been added in 8f3e5a4ebe41c8b0203a41e972c47a99ee3a673d

ipspace commented 2 years ago

EVPN support has been added for multiple platforms.