Primary IP addresses
A primary IP address (PIP) is a VTEP configuration attribute on vPC-enabled leaf or border leaf switches that
-
serves as the BGP next-hop for certain Layer-3 routes
-
ensures that traffic is forwarded to the correct vPC-enabled switch, and
-
provides an alternative to the virtual IP address (VIP) for specific routing scenarios.
Reference Information for Advertising Primary IP Address
In Cisco data center environments using vPC-enabled leaf or border leaf switches, Layer-3 routes are typically advertised with the secondary IP address (VIP) of the VTEP as the BGP next-hop. However, prefix routes and routes generated by the leaf switch are not synchronized between vPC peers. Using the VIP as the next-hop for these routes can result in traffic being sent to the wrong switch and potentially being dropped (black-holed).
The provision to use the primary IP address (PIP) as the BGP next-hop for prefix routes and loopback interface routes allows for more precise traffic engineering. It ensures that traffic destined for these routes always reaches the correct vPC-enabled leaf or border leaf switch.
The configuration command for advertising the PIP is advertise-pip .
-
On the Cisco Nexus 9300-FX2 switch, the advertise-pip command was not supported prior to Cisco NX-OS Release 7.0(3)I7(4). For more information, see CSCvi42831.
-
advertise-pip : Lets BGP use the PIP as next-hop when advertising externally learned routes or for the redistributed direct routes if vPC is enabled.
-
For proper route advertisement, enable or disable advertise virtual-rmac and advertise-pip together. Configuring only one is considered invalid and may cause unexpected behavior.
For Cisco Nexus 9504 and 9508 switches with -R line cards, always configure advertise virtual-rmac without advertise-pip .
Example: Advertising PIP in BGP
The configuration command to enable advertising the PIP as the BGP next-hop is:
switch(config)# router bgp 65536
address-family 12vpn evpn
advertise-pip
interface nve 1
advertise virtual-rmac
With both advertise-pip and advertise virtual-rmac enabled, type 5 routes are advertised with the PIP and type 2 routes are still advertised with the VIP. The system MAC is
used with the PIP, and the virtual MAC (VMAC) is used with the VIP.
If only advertise-pip or advertise virtual-rmac is enabled (but not both), the configuration is invalid and proper route advertisement does not occur.
Feedback