Sunday 13 January 2019

BGP Series 8: eBGP vs iBGP route, Using BGP for Outbound Routing, iBGP BGP Table Entries and Next-Hop issues with iBGP

  • eBGP vs iBGP route:

    • If we learn a route via external neighbor (eBGP), the administrative distance is 20
    • If we learn a route via iBGP, the administrative distance is 200
    • img
    • img

Using BGP for Outbound Routing

  • Comparison: BGP vs Default-route: When an enterprise has a single edge router, we usually use a static default route and advertise that default route into the internal network

  • When there are two internet circuits, we can use static default route or bgp.

  • Here using bgp makes sense, because with bgp, we can prefer one path over the other only for certain set of destinations

  • img

  • Single Homed:

    • Doesn’t need bgp since static default route is enough unless the ISP is asking the enterprise to send all its routes via bgp and the ISP will in-turn send only a default route via bgp instead of the internet routing table
  • Dual Homed:

    • 2 cases

    • 1 case: Single router on edge having two links to same ISP→ even here, bgp is not needed since one is just a backup

    • 2nd case: But, if we have two seperate links to the same ISP, bgp can be useful when one path needs to be preferred over the other for some set of destinations. But, if one link needs to be preferred over other for all destinations, we don’t need bgp much.

iBGP BGP Table Entries and Next-Hop issues with iBGP switching:

  • img

  • ‘r’ on the left of a route means rib-failure. Could happen due to:

    • Another route to the same prefix exists currently in my routing table and it has a lower administrative distance (say, same route was learnt from static, ospf, eigrp,...)
    • Another reason for ‘r’ is if the router is receiving full internet routes and maybe this router does not have enough memory. So, once its memory gets full, it will mark the other routes as ‘r’ since it doesn’t have memory for those
    • Another reason can be if we have configured administrative boundaries on how large the routing table can go .ie. configured the max size of routing table in different VRFs and that limit has been reached.
  • ‘i’ on the left of the network prefix tells that the route is from an iBGP peer

  • Then, if we see the next-hop as 0.0.0.0, it means in my routing table I have this route as a non-BGP route (static/OSPF/…) and then in BGP configuration, I’m using network command to advertise this route to bgp. This is called ‘locally-originated’ route

  • At last, we have AS-path attribute which tells the AS path this route has taken to reach me

    • In this example above, we are seeing the vast majority of routes have no AS-path, which means this route lives in my AS and didnt come from outside AS
    • Also, in above example, we can see that 15.15.0.0/16 is having AS-path as 13 which means it came from AS13

No comments:

Post a Comment