27
Routing Routing Jennifer Rexford Jennifer Rexford Advanced Computer Networks Advanced Computer Networks http://www.cs.princeton.edu/courses/archive/ http://www.cs.princeton.edu/courses/archive/ fall08/cos561/ fall08/cos561/ Tuesdays/Thursdays 1:30pm-2:50pm Tuesdays/Thursdays 1:30pm-2:50pm

Routing Jennifer Rexford Advanced Computer Networks Tuesdays/Thursdays 1:30pm-2:50pm

  • View
    214

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

RoutingRouting

Jennifer RexfordJennifer Rexford

Advanced Computer NetworksAdvanced Computer Networkshttp://www.cs.princeton.edu/courses/archive/fall08/http://www.cs.princeton.edu/courses/archive/fall08/

cos561/cos561/Tuesdays/Thursdays 1:30pm-2:50pmTuesdays/Thursdays 1:30pm-2:50pm

Page 2: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Goals of Today’s Lecture

• Routing– Routing vs. forwarding– Properties of routing protocols

• Internet routing architecture– Separation of intradomain and interdomain– Intra: metric-based and router level– Inter: policy-based at Autonomous System

level

• Measuring the routing system– Challenges of measuring a decentralized,

heterogeneous system– Discussion of Paxson97 (Labovitz98 next time)

Page 3: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Routing

Page 4: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

What is a Route?

•A famous quotation from RFC 791 “A name indicates what we seek.An address indicates where it is.A route indicates how we get there.” -- Jon Postel

Page 5: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Forwarding vs. Routing

•Forwarding: data plane– Directing a data packet to an outgoing

link– Individual router using a forwarding

table

•Routing: control plane– Computing paths the packets will follow– Routers talking amongst themselves– Individual router creating a forwarding

table

Page 6: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Why Does Routing Matter?

• End-to-end performance– Quality of the path affects user performance– Propagation delay, throughput, and packet loss

• Use of network resources– Balance of the traffic over the routers and links– Avoiding congestion by balancing load

• Transient disruptions during changes– Failures, maintenance, and load balancing– Limiting packet loss and delay during changes

• Realizing business objectives– Maximizing revenue or minimizing cost– Avoiding paths going through untrusted parties

Page 7: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Choosing a Routing Protocol

• Who is in charge of selecting the path?– The network or the end host?

• How complex are the path-selection goals?– Shortest-path vs. policy-based routing

• Are participants willing to cooperate?– Willing to share information?– Have a common goal in selecting paths?

• Is large-scale behavior a concern?– Stability of the network topology– State and message overhead– Disruptions during routing convergence

Page 8: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Many Kinds of Routing Protocols

• Link-state routing (Dijkstra)– Routers flood topology information– And compute (shortest) paths

• Distance-vector routing (Bellman-Ford)– Routers learn path costs from their

neighbors– And select the neighbor along shortest path

• Policy-based path-vector routing– Routers learn full path from their neighbors– And select the most desirable path

Page 9: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Many Kinds of Routing Protocols (Continued)

• Source routing– End host or edge router learn the topology– And select the end-to-end path

• Route servers– Set of servers learn topology and compute

routes– And tell all the routers how to forward

packets• Ad hoc routing

– Routers keep track of a small neighborhood– And forward packets in (hopefully) right

direction

Page 10: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Internet Routing Architecture

Page 11: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Two-Tiered Internet Routing Architecture

• Goal: distributed management of resources– Internetworking of multiple networks– Networks under separate administrative

control

• Solution: two-tiered routing architecture– Intradomain: inside a region of control

• Okay for routers to share topology information• Routers configured to achieve a common goal

– Interdomain: between regions of control• Not okay to share complete information• Networks may have different/conflicting goals

Page 12: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Intradomain Routing: E.g., Shortest Path

• Routers belong to the same institution– Share a common, network-wide goal

• Metric-based routing protocols– Typically shortest-path routing

– With configurable link weights

32

2

1

13

1

4

5

3

Page 13: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Interdomain Routing: Between Networks

• AS-level topology– Nodes are Autonomous Systems (ASes)– Destinations are prefixes (e.g., 12.0.0.0/8)– Edges are links and business relationships

1

2

34

5

67

Client Web server

Page 14: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

AS Numbers (ASNs)

ASNs are 16 bit values.64512 through 65535 are “private”

• Level 3: 1 • MIT: 3• Harvard: 11• Yale: 29• Princeton: 88• AT&T: 7018, 6341, 5074, … • UUNET: 701, 702, 284, 12199, …• Sprint: 1239, 1240, 6211, 6242, …• …

ASNs represent units of routing policy

Currently around 30,000 in use.

Page 15: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Interdomain Routing: Border Gateway Protocol

• ASes exchange info about who they can reach– IP prefix: block of destination IP addresses– AS path: sequence of ASes along the path

• Policies configured by the AS’s operator– Path selection: which of the paths to use?– Path export: which neighbors to tell?

32 1

12.34.158.5

“12.34.158.0/24: path (2,1)” “12.34.158.0/24: path (1)”

data traffic data traffic

Page 16: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Measuring Internet Routing

Page 17: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Motivations for Measuring the Routing System

• Characterizing the Internet– Internet path properties– Demands on Internet routers– Routing convergence

• Improving Internet health– Protocol design problems– Protocol implementation problems– Configuration errors or attacks

• Operating a network– Detecting and diagnosing routing problems– Traffic shifts, routing attacks, flaky

equipment, …

Page 18: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Techniques for Measuring Internet Routing

• Active probing– Inject probes along path through the data plane– E.g., using traceroute

• Passive route monitoring– Capture control-plane messages between routers– E.g., using tcpdump or a software router– E.g., dumping the routing table on a router

• Injecting network events– Cause failure/recovery at planned time and place– E.g., BGP route beacon, or planned maintenance

Page 19: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Internet Routing is Hard to Measure

• Nobody knows the Internet topology– No central registry of the AS-level graph– Little public information about intra-AS

topologies• Deploying monitoring infrastructure is hard

– Forwarding: active probes of end-to-end paths– Routing: passive monitoring of routing messages

• Many measurement challenges– Network conditions vary by location– Network conditions change over time– One-way measurements are hard to collect– Controlled experiments are hard to do

Page 20: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Two Papers for Today

• Both early measurement studies of routing– Initially appeared at SIGCOMM’96 and ’97– Both won the “best student paper” award

• And recently won the SIGCOMM “test of time” award!

– Early glimpses into the health of Internet routing

– Early wave of papers on Internet measurement• Differences in emphasis

– Paxson96: end-to-end active probing to measure the characteristics of the data plane

– Labovitz97: passive monitoring of BGP update messages from several ISPs to characterize (in)stability of the interdomain routing system

Page 21: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Active Measurement: Traceroute

• Time-To-Live field in IP packet header– Source sends a packet with a TTL of n– Each router along the path decrements the

TTL– “TTL exceeded” sent when TTL reaches 0

• Traceroute tool exploits this TTL behavior

source destination

TTL=1

Time exceeded

TTL=2

Send packets with TTL=1, 2, 3, … and record source of “time exceeded” message

Page 22: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Paxson Study: Forwarding Loops

• Forwarding loop– Packet returns to same router multiple times

• May cause traceroute to show a loop– If loop lasted long enough– So many packets traverse the loopy path

• Traceroute may reveal false loops– Path change that leads to a longer path– Causing later probe packets to hit same nodes

• Heuristic solution– Require traceroute to return same path 3

times

Page 23: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Paxson Study: Causes of Loops

• Transient vs. persistent– Transient: routing-protocol convergence– Persistent: likely configuration problem

• Challenges– Appropriate time boundary between the

two?– What about flaky equipment going up and

down?– Determining the cause of persistent loops?

• Causes of persistent loops– E.g., misconfiguration

0.0.0.0/012.1.2.0/24

Page 24: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Paxson Study: Path Fluttering

• Rapid changes between paths– Multiple paths between a pair of hosts– Load balancing policies inside the network

• Packet-based load balancing– Round-robin or random– Multiple paths for packets in a single flow

• Flow-based load balancing– Hash of some fields in the packet header– E.g., IP addresses, port numbers, etc.– To keep packets in a flow on one path

Page 25: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Paxson Study: Routing Stability

• Route prevalence– Likelihood of observing a particular route– Relatively easy to measure with sound

sampling– Poisson arrivals see time averages (PASTA)– Most host pairs have a dominant route

• Route persistence– How long a route endures before a change– Much harder to measure through active probes– Look for cases of multiple observations– Typical host pair has path persistence of a

week

Page 26: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Paxson Study: Route Asymmetry

• Hot-potato routing • Other causes– Asymmetric link

weights in intradomain routing

– Cold-potato routing, where AS requests traffic enter at particular place

• Consequences– Lots of asymmetry– One-way delay is not

necessarily half of the round-trip timeCustomer A

Customer B

multiplepeeringpoints

Provider A

Provider B

Early-exit routing

Page 27: Routing Jennifer Rexford Advanced Computer Networks  Tuesdays/Thursdays 1:30pm-2:50pm

Conclusions

• Internet routing architecture– Two-tiered system– Intradomain is metric-based, with common goal– Interdomain is policy-based, reconciling

different goals across ASes

• Behavior of complete systems is mysterious– Challenging to measure– Challenging to characterize, and diagnose

• Next time– Border Gateway Protocol (BGP)– Discussion of the Labovitz97 paper