Lab5 “Shadow RR”

Load lab5.init.cfg

#R1, R6
configure replace unix:lab5.init.cfg

#R2-R5, R7, R8
configure
load bootflash:lab5.init.cfg
commit replace
y

R8 has been introduced as a second RR.

  • Configure this as a shadow RR so that R8 advertises the backup path via R5 to all route-reflector clients.

    • The second RR session has already been configured on all routers within 65000.

  • R3 is already configured for iBGP multipath.

  • Ensure that the RRs make the same bestpath decision, no matter where they are placed in the IGP topology.

Answer

https://www.youtube.com/watch?v=LB08hAqTQVQ&list=PL3Y9eZjZCcsejbVWD3wJIePqe3NiImqxB&index=7

#R7
router bgp 65000
 bgp bestpath igp-metric ignore

#R8
route-policy SELECT_BACKUP
 set path-selection backup 1 advertise
end-policy
!
route-policy ADVERTISE_BACKUP_ONLY
 if destination is-backup-path then pass endif
end-policy
!
router bgp 65000
 bgp bestpath igp-metric ignore
 address-family ipv4 unicast
  additional-paths send
  additional-paths selection route-policy SELECT_BACKUP
 add ipv6 unicast
  additional-paths send
  additional-paths selection route-policy SELECT_BACKUP
 !
 neighbor-group IBGP_V4
  address-family ipv4 unicast
   route-policy ADVERTISE_BACKUP_ONLY out
 !
 neighbor-group IBGP_V6
  address-family ipv6 unicast
   route-policy ADVERTISE_BACKUP_ONLY out

#R2, R3, R4, R5
router bgp 65000
 add ipv4 uni
  additional-paths receive
 add ipv6 uni
  additional-paths receive

Explanation

To guarantee that the two RRs (R7 and R8) will choose the same primary bestpath no matter where they are in the topology, we must disable the IGP metric comparison in the bestpath decision process. This ensures that the RRs always select the same bestpath.

#R7, R8
router bgp 65000
 bgp bestpath igp-metric ignore

Next, on R8, we must only advertise the diverse backup path to all RR clients. On IOS-XE we could simply use “advertise diverse-path backup” without needing Add-Path. However, this is not an option on IOS-XR. Instead, we can run Add-Path and use an RPL that matches only the backup path.

#R8
route-policy SELECT_BACKUP
 set path-selection backup 1 advertise
end-policy
!
route-policy ADVERTISE_BACKUP_ONLY
 if destination is-backup-path then pass endif
end-policy
!
router bgp 65000
 address-family ipv4 unicast
  additional-paths send
  additional-paths select SELECT_BACKUP
 !
 add ipv6 unicast
  additional-paths send
  additional-paths select SELECT_BACKUP
 !
 neighbor-group IBGP_V4
  address-family ipv4 unicast
   route-policy ADVERTISE_BACKUP_ONLY out
 !
 neighbor-group IBGP_V6
  address-family ipv4 unicast
   route-policy ADVERTISE_BACKUP_ONLY out

Verification

Before making any changes, we see that R3 is receiving two copies of each path, one from each RR:

Next we add Add-Path on all routers (except R7) and reset all BGP peerings on R8. Now R3 receivings only one path from R8 - the single backup path for R6 via R5.

Strangely, on R8, it does not show any advertised routes to its peers.

However, if we look at R6’s prefix, we can see that the bestpath is not advertised, but the backup path is advertised.

On R3, we see that the path is clearly received from R8 though, so this just appears to be a bug. The multipath configuration was already pre-loaded, so R3 is doing multipath.

Last updated