Forwarding. Internet routing architecture. • Lecture 2: Intra-domain routing with. “
shortest paths”. Link-state vs. distance- vector. • Lecture 3 : Inter-domain routing.
Internet Routing Protocols Lecture 01 Advanced Systems Topics Lent Term, 2008 Timothy G. Griffin Computer Lab Cambridge UK
Common View of the Telco Network
Brick
1
Common View of the IP Network (Layer 3)
IP routing is the little bit-o-smarts left in the IP network layer • Dynamic Routing protocols are used to implement and maintain connectivity in the Internet. • Which protocols are used? • How do they work? • How do they behave? • What are some of the fundamental tradeoffs in the design space of routing protocols?
2
Outline
• Lecture 1 : Routing vs. Forwarding. Internet routing architecture • Lecture 2: Intra-domain routing with “shortest paths”. Link-state vs. distancevector. • Lecture 3 : Inter-domain routing. The Border Gateway Protocol (BGP) • Lecture 4 : BGP continued • Lecture 5 : BGP dynamics • Lecture 6 : BGP routing anomalies
3
4
GARR-B
5
wiscnet.net UW-Superior
Rice Lake Rhinelander
UW-Stout
Stiles Jct.
Wausau
Marshfield
UW-River Falls UW-Eau Claire
Qwest and Other Provider(s)
(Su
Clintonville
) mmer '02
UW-Stevens Point UW-Green Bay (Summer
'02)
Fox Valley TC um
(Summer '03)
(S
UW-Oshkosh
m er '02
UW-La Crosse
)
La Crosse
Internet 2 & Qwest
Portage
Dodgeville
UW-Platteville
Genuity
UW-Madison (Summer '03)
UW-Milwaukee
UW-Whitewater
UW-Parkside
(Winter '02)
GO BUCKY! Gigabit Ethernet OC-12 (622Mbps) OC-3 (155Mbps) DS-3 (45Mbps) T1 (1.5Mbps)
Chicago ! ! ! ! ! !
Peering - Public and Private Commodity Internet Transit Internet2 Merit and Other State Networks National Education Network Regional Research Peers
(Win
ter
'02)
Chicago - 2 (Winter '02)
Chicago - 1
6
WorldCom (UUNet)
Internet Initiative Japan (IIJ)
7
Telstra international
AT&T IP Backbone
Anchorage, AK
Year end 2001
Seattle
Spokane
Portland
Portland Manchester
Worcester
Minneapolis
R
St. Paul Milwaukee
Glenvie w
Rochester
Madison Rolling Meadows
Des Moines
Sacramento
R
San San Francisco Francisco
R
Salt Lake City
Kansas City
Redwood City
Los Angeles
Albuquerque
Sherman Oaks
San Bernardino
LA-Airport Blvd Garden a
Chicago
Denver
Oklahom a City
Phil
Arlington Norfolk
Louisville
Nashville
Richmond
R
Rochelle Pk Hamilton Square
R
Baltimore Newark Bohemia
Florissant
Tulsa
Cambridge Framingham Providence Stamford Providence Bridgepor t New Brunswick White Plains Cedar Knolls
NYC
Wash. DC
Silver Springs
Camden, NJ
Freehold
R
NYCBdwy
Raleigh
Greensboro Charlotte
Little Rock Memphis
Phoenix
Gateway Node Ft. Worth
Birmingham Norcross
Columbia Dunwoody
Atlanta
Dallas
Backbone Node
R
R R
Harrisburg
Dayto Columbus n Cincinnati
St Louis
Anaheim
San Diego
R
Indianapolis
Hartford Wayne
Pittsburgh Cleveland Akron
South Bend
Albany
Syracuse
Buffalo
Detroit Plymouth
Chicago
Colorado Springs
Honolulu
Oak Brook
Omaha
Las Vegas
R San Jose
Oakland
Davenport
R
Grand Rapids Birmingham
Remote GSR Access Router
Jacksonville New Orleans
Austin
Remote Access Router
Orlando
Houston San Antonio
N X DS3 N X OC3 N X OC12 N X OC48 NX OC192
R
Note: Connectivity and nodes shown are targeted for deployment; actual deployment may vary. Maps should not be used to predict service availability.
Tampa
R
Ft. Lauderdale
W. Palm Beach Ft. Lauderdale Ojus Miami San Juan PR
Rev. 6-4-01
8
Architecture of Dynamic Routing IGP
BGP
AS 1 IGP = Interior Gateway Protocol. Metric based. OSPF, IS-IS, RIP, EIGRP (cisco)
IGP
AS 2
EGP = Exterior Gateway Protocol. Policy Based. Only one: BGP The Routing Domain of BGP is the entire Internet
How many ASN are used today? http://bgp.potaroo.net
Jan 28. 2008
9
Routers Talking to Routers (The “control plane”) Routing info
Routing info
• Routing computation is distributed among routers within a routing domain • Computation of best next hop based on routing information is the most CPU/memory intensive task on a router • Routing messages are usually not routed, but exchanged via layer 2 between physically adjacent routers (internal BGP and multi-hop external BGP are exceptions)
Technology of Distributed Routing Link State • Topology information is flooded within the routing domain • Best end-to-end paths are computed locally at each router. • Best end-to-end paths determine next-hops. • Based on minimizing some notion of distance • Works only if policy is shared and uniform • Examples: OSPF, IS-IS
Vectoring • Each router knows little about network topology • Only best next-hops are chosen by each router for each destination network. • Best end-to-end paths result from composition of all nexthop choices • Does not require any notion of distance • Does not require uniform policies at all routers • Examples: RIP, BGP
10
The Gang of Four Link State
IGP
OSPF IS-IS
Vectoring
RIP BGP
EGP
The standard model data received
data sent
Application
Application
Presentation
Presentation
Session
Session
Transport
Transport
Network
Network
DataLink
DataLink
Physical
Physical
22
11
All Hail the IP Datagram! H E A D E R D A T A
0 1 2 3 01234567890123456789012345678901 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |Version| IHL | Service Type | Total Length | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Identification |Flags| Fragment Offset | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Time to Live | Protocol | Header Checksum | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Source Address | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Destination Address | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Options | Padding | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ : : | + | + | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
... up to 65,515 octets of data ...
shaded fields little-used today
1981, RFC 791
: : | + | + | 23
IP Hour Glass Networking Applications Remote Access Voice e-stuff email file transfer Multimedia TCP
Web
VPN
IP
Minimalist network layer
Frame X.25
SONET
ATM DWDM
Ethernet FDDI
Networking Technologies 24
12
Best Effort, Connectionless, Connectivity IP traffic 135.207.49.8
192.0.2.153
The is the fundamental service provided by Internet Service Providers (ISPs) All other IP services depend on connectivity: DNS, email, VPNs, Web Hosting, …
IP is a Network Layer Protocol
Application
Separate physical networks glued together into one Application logical network
Router
Presentation
Presentation
Session
Session
Transport
Transport Network
Network
Network
DataLink 1
DataLink 1 DataLink 2
DataLink 2
Physical 1
Physical 1 Physical 2
Physical 2
Medium 1
Medium 2
26
13
Hosts, Networks, and Routers Host 7 Host 1 Network A Host 2 Host 1 Router
Network C
Network B
Unique IP Address = Network Number + Host Number Host 12
Host 2
27
Actually, IP addresses Identify Interfaces Host 7 Host 1 Network C, Host 3
Network A
Host 1
Host 2
Network A, Host 3 Network B, Host 77
Network B
Host 12
Host 2
Network C
Machines can have more than one IP address. 28 All routers do!
14
IP Forwarding Table Destination Net A Net B Net C, Host 3 Net C
A destination is usually a network. May also be a host, or a “gateway of last resort” (default)
Next Hop
Interface
Router 1 Direct Router 2 Router 1
INT 7 INT 4 INT 3 INT 7
The next hop is either a directly connected network or a router on a directly connected network
A physical interface
29
IP Forwarding Process 1. Remove a packet from an input queue
2. Check for sanity, decrement TTL field
4. Place packet on correct output queue
Forwarding Process If queues get full, just drop packets!
3. Match packet’s destination to a table entry
If queues get full, just drop packets!
IP Forwarding Table Router 30
15
IPv4 Addresses are 32 Bit Values 11111111 00010001 10000111 00000000 255
17
134
0
255.17.134.0 Dotted quad notation IPv6 addresses have 128 bits 31
IP Addresses come in two parts 11111111 00010001 10000111 00000000 Network Number
Host Number
Where is this dividing line? Well, that depends .... 32
16
Classful Addresses Class A
0nnnnnnn hhhhhhhh hhhhhhhh hhhhhhhh
Class B
10nnnnnn nnnnnnnn hhhhhhhh hhhhhhhh
Class C
110nnnnn nnnnnnnn nnnnnnnn hhhhhhhh n = network address bit
h = host identifier bit
Leads to a rigid, flat, inefficient use of address space …
33
RFC 1519: Classless Inter-Domain Routing (CIDR) Use two 32 bit numbers to represent a network. Network number = IP address + Mask
IP Address : 12.4.0.0 Address
Mask
IP Mask: 255.254.0.0
00001100 00000100 00000000 00000000 11111111 11111110 00000000 00000000 Network Prefix
for hosts
Usually written as 12.4.0.0/15
34
17
Which IP Addresses are Covered by a Prefix?
12.5.9.16 is covered by prefix 12.4.0.0/15 12.5.9.16
12.4.0.0/15
00001100 00000101 00001001 00010000 00001100 00000100 00000000 00000000 11111111 11111110 00000000 00000000
12.7.9.16
00001100 00000111 00001001 00010000
12.7.9.16 is not covered by prefix 12.4.0.0/15
CIDR allows Hierarchy in Addressing 12.0.0.0/16 12.1.0.0/16 12.2.0.0/16 12.3.0.0/16 12.0.0.0/8
: : : 12.253.0.0/16 12.254.0.0/16
12.3.0.0/24 12.3.1.0/24
: :
: : :
12.3.254.0/24 12.253.0.0/19 12.253.32.0/19 12.253.64.0/19 12.253.96.0/19 12.253.128.0/19 12.253.160.0/19 12.253.192.0/19 36
18
Classless Forwarding
Destination =12.5.9.16 ------------------------------payload
OK better
Prefix
Next Hop
Interface
0.0.0.0/0
10.14.11.33
ATM 5/0/9
12.0.0.0/8
10.14.22.19
ATM 5/0/8
even better
12.4.0.0/15 10.1.3.77
Ethernet 0/1/3
best!
12.5.8.0/23 attached
Serial 1/0/7
IP Forwarding Table
How Are Forwarding Tables Populated to implement Routing? Statically Administrator manually configures forwarding table entries + More control + Not restricted to destination-based forwarding - Doesn’t scale - Slow to adapt to network failures
Dynamically Routers exchange network reachability information using ROUTING PROTOCOLS. Routers use this to compute best routes + Can rapidly adapt to changes in network topology + Can be made to scale well - Complex distributed algorithms - Consume CPU, Bandwidth, Memory - Debugging can be difficult - Current protocols are destination-based
In practice : a mix of these. Static routing mostly at the “edge”
38
19
Routing vs. Forwarding Net Default to upstream router
A
A B C D E default
B R R2 R
R4
D
R3 R
R1
Nxt Hop R1 Direct R3 R1 R3 R1
C
R5 Net
E
Forwarding: determine next hop Routing: establish end-to-end paths
A B C D E default
Net
Nxt Hop
A B C D E default
R2 R2 Direct R5 R5 R2
Nxt Hop Forwarding always works
R4 R3 R3 R4 Direct R4
Routing can be badly broken 39
Happy Packets: The Internet Does Not Exist Only to Populated Routing Tables
BGP
RIP Process
BGP Process
RIP Routing tables
BGP Routing tables
OSPF Process OSPF Routing tables
RIP Domain
OSPF Domain
Forwarding Table Manager
Forwarding Table 40
20
Before We Go Any Further … IP ROUTING PROTOCOLS DO NOT DYNAMICALLY ROUTE AROUND NETWORK CONGESTION • IP traffic can be very bursty • Dynamic adjustments in routing typically operate more slowly than fluctuations in traffic load • Dynamically adapting routing to account for traffic load can lead to wild, unstable oscillations of routing system
Next Lecture: Shortest Path Routing B
Dest. Nxt Hop 100
B
C
C D
C D
E
D
55
20
100
20
35
A
35
35
C
20
20 20
10 20
20 D
10
10
30 E
10
This is what IS-IS, OSPF, and RIP do, more or less.
42
21