Configuring the Underlay Network

The BGP EVPN underlay network must be configured to build Layer 3 connectivity among VTEPs and intermediate routers. Loopback interface addresses, used as VTEP and BGP peer endpoints, must be routable in the underlay. While an Interior Gateway Protocol (IGP) such as OSPF or RIP can be enabled for underlay routing, it is recommended to employ OSPF for optimal underlay routing.
The following task shows how to configure EVPN for one VTEP (VTEP 1.1.1.1).
Note: Enabling OSPF for the underlay is recommended.
  1. Enter global configuration mode.
    device# configure terminal
  2. Configure a Virtual Ethernet interface.
    device(config)# interface ve 2
  3. Assign IP addresses to the VE interface.
    device(config-vif-2)# ip address 2.0.0.1 255.255.255.0
  4. Assign the VE interface to an OSPF area.
    device(config-vif-2)# ip ospf area 0
  5. Configure a loopback interface on the VE interface.
    device(config-vif-2)# interface loopback 1
  6. Assign IP addresses to the loopback interface.
    device(config-lbif-1)# ip address 1.1.1.1 255.255.255.255
  7. Assign the loopback interface to an OSPF area.
    device(config-lbif-1)# ip ospf area 0
  8. Set the loopback interface as passive.
    device(config-lbif-1)# ip ospf passive
  9. Return to global configuration mode.
    device(config-lbif-1)# exit
    device(config)#
  10. Enable OSPF, and enter OSPF VRF router configuration mode
    device(config)# router ospf
  11. Configure an OSPF area.
    device(config-ospf-router)# area 0
    

The following is an example showing EVPN configuration for two VTEPs and an RR on a spine for a BGP EVPN underlay network.

VTEP-1(1.1.1.1) — ve2 — RR :

device(config)# interface ve 2
device(config-vif-2)# ip address 2.0.0.1 255.255.255.0
device(config-vif-2)# ip ospf area 0
device(config-vif-2)# interface loopback 1
device(config-lbif-1) ip address 1.1.1.1 255.255.255.255
device(config-lbif-1) ip ospf area 0
device(config-lbif-1) ip ospf passive
device(config-lbif-1)# exit
device(config)# router ospf
device(config-ospf-router)# area 0

VTEP-2(2.2.2.2)--- ve3 — RR :

device(config)# interface ve 3
device(config-vif-3)# ip address 3.0.0.1 255.255.255.0
device(config-vif-3)# ip ospf area 0
device(config-vif-3)# interface loopback 1
device(config-lbif-1) ip address 2.2.2.2 255.255.255.255
device(config-lbif-1) ip ospf area 0
device(config-lbif-1) ip ospf passive
device(config-lbif-1)# exit
device(config)# router ospf
device(config-ospf-router)# area 0

VTEP-1 <----- ve2----> RR(3.3.3.3) <--- ve3---> VTEP-2:

device(config)# interface ve 2
device(config-vif-2)# ip address 2.0.0.100 255.255.255.0
device(config-vif-2)# ip ospf area 0
device(config-vif-2)# interface ve 3
device(config-vif-3)# ip address 3.0.0.100 255.255.255.0
device(config-vif-3)# ip ospf area 0
device(config-vif-3)# interface loopback 1
device(config-lbif-1) ip address 3.3.3.3 255.255.255.255
device(config-lbif-1) ip ospf area 0
device(config-lbif-1) ip ospf passive
device(config-lbif-1)# exit
device(config)# router ospf
device(config-ospf-router)# area 0