As stated earlier in this chapter, BGP is typically used for inter-domain routing, while IGPs are used for intra-domain routing. As is the case with the different IGPs we learned about in previous chapters in this guide, it is important to have a solid understanding of BGP, not just as a Path Vector routing protocol, but as policy control tool. BGP has the following characteristics:
- Reliability
- Stability
- Scalability
- Flexibility
These characteristics are described in detail in the following sections.
Reliability
Unlike OSPF and EIGRP that run directly over IP, BGP runs directly over TCP, using port 179. Because TCP is a reliable, connection-oriented protocol, BGP does not need to worry about update retransmissions, fragmentation, acknowledgements, and sequencing because these are all performed by the underlying protocol, TCP.
Additionally, BGP also establishes a session between BGP speakers. This connection-oriented session is maintained by regular keepalives. When a BGP speaker fails to receive keepalives within a specified interval, the session with the neighbor is closed and all of the BGP routing and forwarding information for that session is cleared by the local BGP speaker.
Unlike traditional IGPs, BGP also incorporates path attributes to ensure protocol reliability and routing information accuracy. In addition to being used to select the best path to a destination prefix, path attributes are also used to prevent routing loops and ensure that the next hop IP address for a specified BGP prefix is reachable before BGP uses the next hop address to forward packets to that destination prefix.
Stability
As was stated in Chapter 1, one of the core objectives of routing protocols is stability. In essence, routing algorithms should be stable enough to accommodate unforeseen network events, such hardware failures, incorrect implementations or even flapping interfaces or routes. Following such network changes, routing protocols must be able to converge quickly in order to avoid the black holing of traffic, or even to avoid routing loops.
Routing protocol convergence and stability is critical in large enterprise networks with a large number of prefixes, and even more so for Internet Service Providers whose routers typically contain a complete or full Internet routing table. BGP provides more features than traditional IGPs that can be used to ensure a stable topology. In addition to timers, BGP can also be configured to monitor routing information for signs of instability using route flap dampening. Route dampening is used to penalize route or prefix entries that are repeatedly transitioning between the up and down states. This is commonly referred to as bouncing or flapping. Route dampening will be described in detail in the following chapter.
BGP also allows for the soft reset of neighbor sessions when routing policy changes and updates need to be sent. Soft resets are used to change the BGP policy without resetting the BGP session. This capability prevents packet loss or even the black holing of traffic if the session is reset and all routing information for that session was flushed.
Scalability
BGP is very scalable. An external BGP (eBGP) implementation does not require all the routers within an autonomous system to participate in the BGP protocol. Only the border routers that provide connectivity between the local autonomous system and its adjacent autonomous system(s) participate in BGP. This allows an eBGP implementation can scale to support hundreds of peer sessions and well over one hundred thousand prefixes (full Internet table).
While there are some scalability issues for internal BGP (iBGP) implementations, wherein all routers within the autonomous system participate in the BGP protocol, several methods are available to address these scalability issues and implement large iBGP networks. These different methods are described in the following chapter on Advanced BGP Design and Implementation.
Flexibility
BGP provides far greater flexibility than traditional IGPs. Flexibility is provided by the number of path attributes that can be used to define BGP policies. It is for this reason that BGP is considered first and foremost a policy tool and then a routing protocol. BGP path attributes can be used to define both routing policies, such as how traffic routes in and out of an administrative domain (autonomous system), and administrative policies, such as limiting the number of prefixes received from a specific autonomous system for example.