BGP

A standardized exterior gateway protocol designed to exchange routing and reachability information among autonomous systems (AS) on the Internet.

BGP (Border Gateway Protocol) is the fundamental path-vector routing protocol that connects the global internet. It facilitates the exchange of reachability information between Autonomous Systems (AS), which are individual networks managed by ISPs, universities, or large corporations. BGP uses TCP port 179 to ensure reliable delivery of routing updates between peers.

How it works

BGP routers establish peering sessions to exchange network prefixes. Unlike internal protocols that focus on shortest path metrics, BGP uses policy-based routing. Decisions are made using attributes like AS_PATH, which prevents loops by tracking every AS a route has traversed, and LOCAL_PREF, which determines the preferred exit point from a network.

  • eBGP (External BGP): Used for routing between different autonomous systems.
  • iBGP (Internal BGP): Used to distribute external routing information within a single AS.

The protocol is essential for multi-homing, allowing a network to connect to multiple ISPs for redundancy. As of 2024, the global IPv4 routing table contains over 900,000 prefixes. BGP convergence depends on timers such as Keepalive and Hold-time, which are typically configured to 60 and 180 seconds respectively to maintain session stability.