Introduction to BGP
The Border Gateway Protocol (BGP) is the main protocol used for inter-domain traffic (inter-AS traffic) and therefore the protocol that Internet is built upon today.
There are two types of the BGP protocol: Internal BGP (IBGP) which is used when two routers are connected within the same AS domain, and External BGP (EBGP) which is used when two routers from different ASs are connected. Any BGP connection between two routers is called a BGP session or BGP peering, whereas the routers themselves are called BGP neighbors or peers. BGP is configured along with the AS Number (ASN) that the router belongs to. It uses this information to determine if two neighbors belong to the same AS or not.
For the establishment of a BGP session, two routers need to exchange BGP messages and updates; therefore they must have IP connectivity between them via a routing protocol other than BGP. Usually for IBGP sessions, an IGP protocol is used for this purpose whereas for EBGP sessions the routers need to be directly connected (for indirect connection, multihop BGP can be configured). The picture below depicts an example of BGP implementations:
When configuring a BGP session, the neighbors’ IP addresses are commonly configured in a loopback interface (virtual interface) in order to ensure stability in the session (because otherwise if a physical interface is used, the BGP session is going to break every time the interface goes down).
The BGP protocol will be analyzed extensively in later posts.
- Internet Overview (telconotes.wordpress.com)