09-17-2021 01:31 AM
I'm confused about the exact effect of the BGP command 'bgp bestpath compare-routerid'. If you configure this command, it tells the router to use Router ID as the deciding factor in choosing between two identical prefix advertisements. But does that mean it uses Router ID as the first criteria in the Path Selection process? In other words, does this push it to the front, ahead of the usual factors like Weigh, Local Pref, etc.? Or does this just move Router ID up one spot, ahead of Prefer Newer Routes?
09-17-2021 01:52 AM
Hi there,
The documentation states " use the router ID as the tie breaker for best path selection when two identical routes are received from two different peers (all the attributes are the same except for the router ID)" . It can e inferred that is is an additional check used at the end of the normal best-path selection process. It does not replace the entire selection process with a single step.
cheers,
Seb.
https://www.cisco.com/c/en/us/td/docs/ios/iproute_bgp/command/reference/irg_book/irg_bgp1.html
09-17-2021 03:16 AM
Yes, but the Router-ID comparison is itself part of the normal BGP path selection process (the second-to-last one checked). If Router-ID comparison is enabled by default, as part of the normal path selection process, then why specifically have a command telling the router to use it? My guess is that it must have some effect, like maybe moving Router-ID up the list?
09-17-2021 04:12 AM
Enabling that command will cause it to skip step 10 (assuming comparison is between eBGP peers), and jump straight to step 11 (and beyond) for the tie-break.
https://www.cisco.com/c/en/us/support/docs/ip/border-gateway-protocol-bgp/13753-25.html
cheers,
Seb.
09-17-2021 02:45 PM
it is used to skip step of comparing and preferring older routes. this is useful if you worry about route/routers flapping (going up/down) and also increases your BGP network stability.
Also, some books has mentioned that this step of comparing lowest router-id is only active if you have command 'bgp bestpath compare-routerid' turn on, which would indicate to me that some IOS versions and/or routers do not have it on,
Regards, ML
**Please Rate All Helpful Responses **
09-18-2021 11:18 AM
Hello @Martin L ,
my understanding is that without the command, if the two candidate paths are eBGP the older is taken.
So normally the Step 11 would be used as a tie breaker only if the remaining candidate paths are iBGP .
With the command discussed in this threas this critera is used also for the case of eBGP candidate paths skipping Step 10 that would give more importance to the older path a sign of stability.
On the other hand the use of the command bgp bestpath compare-routerid would make the choice of the best path to be more deterministic as BGP Router-IDs are not going to change over time (unless there is a need and a configuration change)
Hope to help
Giuseppe
09-19-2021 06:22 AM
Hello
Instead of selecting two identical routes based on the first route received (oldest path), BGP will select based on the lowest RID of the routes as best path, so in essence step 10 in the bgp best path section process will be skipped when this feature is enabled.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide