Networks Horizon

share

Friday 24 February 2012


Continue....
Border Gateway Protocol 
BGP-version 4- Part 4



BGP Next Hop Processing

  1. BGP next hop is set to router’s own address on EBGP sessions. Or you can say, next hop address is changed on eBGP advertisement.

For example, when PE-B sends BGP prefix 10.0.1.0/24 (with next-hop 10.0.0.1) to X3, it sets BGP next hop to 192.168.2.1.


But, we can always set the BGP next hop to any value you like with an outbound route-map. But, First reason, we do not prefer it because, it is risky (because it is hard to check whether the next hop you advertise is actually reachable) and second reason is that you do not want neighboring AS to know your internal next hop addresses.






Exceptions:


EBGP next hop is not changed if the BGP next hop in the BGP table belongs to the same IP subnet as the EBGP neighbor to which the update is sent. 


Example: X1 sends BGP prefix 172.16.0.0/16 to PE-A. Next hop is set to the source address of the EBGP session between X1 and PE-A (192.168.0.1). When PE-A propagates the BGP prefix to X2, it does not change the next hop (X1, PE-A and X2 are in the same subnet).


If you still want to change next hop in this case, next-hop-self command can be used towards eBGP session where you want to advertise the routes.


Example: Assuming neighbor 192.168.0.2 next-hop-self is configured on PE-A, the BGP next hop of all BGP routes sent to X2 from PE-A will be 192.168.0.3 and the traffic between X1 and X2 will flow through PE-A.


   2.  For iBGP route advertisement, next hop address will not be change.


All routers within an autonomous system are assumed to be able to reach the same set of subnets (advertised through IGP). Therefore, when an AS edge router propagates external BGP prefixes to internal BGP peers, it does not change the BGP next hop.


example: X1 sends BGP prefix 172.16.0.0/16 with next hop 192.168.0.1 to PE-A. Assuming neighbor 10.0.0.2 next-hop-self has been configured on PE-A, the BGP next hop of the BGP route sent to RR will be 10.0.0.1.
So you have two options:
  • Redistribute external subnet (eBGP next hop) into IGP.it is never a good idea to allow external links.
  • Alternatively, we can use next-hop-self on ingress router towards iBGP session. Along with, we also require to set the next hop address as loopback address of ingress router.
Second method is most preferred.


Other important info to note about next hop processing:


BGP next hop is set to 0.0.0.0 for routes with unknown next hops, connected interfaces, static routes to null 0 or summary routes configured with aggregate-address router configuration command. 


BGP route reflectors should not change any attribute of the routes they reflect. Thus all BGP attributes including next hop advertised by an edge router is reflected unchanged by Route Reflectors.




                    Please read BGP-version 4- Part 5 for more information.

No comments:

Post a Comment