Mini Introduction To BGP: Michalis Faloutsos
Mini Introduction To BGP: Michalis Faloutsos
Michalis Faloutsos
What Is BGP?
Border Gateway Protocol BGP-4 The de-facto interdomain routing protocol BGP enables policy in routing:
BGP is a Distance Vector like protocol Within an AS, Internal Gateway Protocol (IGP or I-BGP)
AS 4
AS 3
Each AS has designated BGP routers BGP routers of an AS communicate internally with another protocol (IGP)
AS 1
Superlinear growth
IP addresses have 32 bits: 4 octets of bits (IPv4) A prefix is a group of IP addresses 128.32.101.5 is an IP address (32 bits) 128.32.0.0/16 is a prefix of the 16 first bits:
128.32.0.0 128.32.255.255
(2^16 addresses)
A BGP Routing table has prefixes for entries For a IP address of a packet, find longest match Example: packet IP 128.32.101.1 128.32.0.0/16 match for 16 bits 128.32.101.0/24 is a longer match No matches:
128.1.1.4 128.32.5.0/24
packet IP 128.32.101.1 With 128.32.0.0/16 IP : 01000000. 001000000. 01100101 .00000001 Mask : 11111111. 111111111. 00000000 .00000000 AND : 01000000. 001000000. 00000000 .00000000 Prefix : 01000000. 001000000. 00000000. 00000000 Equal? Yes
Origin AS
123 123
Path
14 56 123 34 101 203 123 50 15 15
128.32.101.0/24
15
Route Advertising
Distance Vector style protocol Hear advertisements: IP prefix, AS-path Filter if desired (i.e. ignore) Append yourself: IP prefix, myAS+AS-path Forward to appropriate ASs
Basic AS relationships
Customer Provider
Customer pays Provider for service The Customer is always right Ex. MCI and AT&T
Ex. AT&T research and AT&T wireless
Sibling-Sibling
Provider Peer
Customer Peer
Traffic engineering
AS Relationships
100 200
Provider Customer
10
11 1 2 12 13 4
Peer
Peer
Customer Provider: customer pays and is always right Peer to Peer: Exchange traffic only between their customers Sibling-Sibling: Exchange traffic at will
100 10 11 12 3
200
Peer
Peer
13 4
Path Properties:
2 Routing rules:
Advertise to all (customers, peers, providers) Advertise to customer only (and possibly siblings) Advertise to customer only (and possibly siblings)
Advertise to all
A Provider will get rid of traffic as soon as possible, But a Provider will carry the traffic for its customer Did anyone say traffic is asymmetric?
ISP2 Customer 2