+ All Categories
Home > Documents > Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show...

Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show...

Date post: 26-May-2020
Category:
Upload: others
View: 11 times
Download: 0 times
Share this document with a friend
23
CSE 222A: Computer Communication Networks Alex C. Snoeren Lecture 4: Routing Thanks: Nick Feamster & Mike Freedman
Transcript
Page 1: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

CSE 222A: Computer Communication Networks Alex C. Snoeren

Lecture 4:Routing"

Thanks: Nick Feamster & Mike Freedman

Page 2: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Lecture 4 Overview"  Cerf & Kahn discussion

  Routing review ◆  Alternative designs ◆  BGP

  Paxson discussion

CSE 222A – Lecture 4: Routing" 2

Page 3: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

  Building a forwarding table ◆  Computing paths between network elements ◆  … and figuring out where the end-hosts are ◆  … to map a destination address to an outgoing link

  How to find the hosts? ◆  Learning/flooding ◆  Injecting into routing protocol ◆  Dissemination via different protocol ◆  Directory service

Finding the Hosts"

3 CSE 222A – Lecture 4: Routing"

Page 4: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Learning and Flooding"  When a frame arrives

◆  Inspect the source address

◆  Associate address with the incoming interface

  When the frame has an unfamiliar destination ◆  Forward out all interfaces ◆  … except for the one where

the frame arrived

A!

B!

C!

D!

Switch learns how to reach A.!

A!

B!

C!

D!

When in doubt, shout!!

Used in Ethernet LANs!

4 CSE 222A – Lecture 4: Routing"

Page 5: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Inject into Routing Protocol"  Treat the end host (or subnet) as a node

◆  And disseminate in the routing protocol ◆  E.g., flood information about where addresses attach

3 2

2

1

1 4

1

4

5

3

u!

s!6!Used in OSPF and IS-IS, especially in enterprise networks

. . .!5 CSE 222A – Lecture 4: Routing"

Page 6: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Disseminate w/Other Protocol"  Distribute using another protocol

◆  One router learns the route ◆  … and shares the information with other routers

learn a route to d!(e.g., via BGP)!

disseminate route to other routers!

Internal BGP (iBGP) used in backbone networks

6 CSE 222A – Lecture 4: Routing"

Page 7: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Directory Service"  Contact a service to learn the location

◆  Lookup the end-host or subnet address ◆  … and learn the label to put on the packet ◆  … to get the traffic to the right egress point

s!

d!

i!

e!

directory!

“Host d is at egress e”!

Encapsulate packet to send to egress e.!

Used in some data centers

7 CSE 222A – Lecture 4: Routing"

Page 8: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

To Each His Own…"  Ethernet LAN: spanning tree, MAC learning, flooding

  Enterprise: link-state routing, injecting subnet addresses

  Backbone: link-state routing inside, path-vector routing with neighboring domains, and iBGP dissemination

  Data centers: many different solutions, still in flux »  E.g., link-state routing or multiple spanning trees »  E.g., directory service or injection of subnets into routing protocol

8 CSE 222A – Lecture 4: Routing"

Page 9: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Internet Routing: BGP"

Route Advertisement

Autonomous Systems (ASes)

Session

Traffic Destination Next-hop AS Path

130.207.0.0/16

130.207.0.0/16

192.5.89.89

66.250.252.44

10578..2637

174… 2637

9 CSE 222A – Lecture 4: Routing"

Page 10: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Two Flavors of BGP"

  External BGP (eBGP): exchanging routes between ASes

  Internal BGP (iBGP): disseminating routes to external destinations among the routers within an AS

eBGP iBGP

10 CSE 222A – Lecture 4: Routing"

Page 11: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Example BGP Routing Table"> show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356 701 703 80 i *>i4.0.0.0 4.79.2.1 0 110 0 3356 i *>i4.21.254.0/23 208.30.223.5 49 110 0 1239 1299 10355 10355 i * i4.23.84.0/22 208.30.223.5 112 110 0 1239 6461 20171 i

The full routing table

> show ip bgp 130.207.7.237 BGP routing table entry for 130.207.0.0/16 Paths: (1 available, best #1, table Default-IP-Routing-Table) Not advertised to any peer 10578 11537 10490 2637 192.5.89.89 from 18.168.0.27 (66.250.252.45) Origin IGP, metric 0, localpref 150, valid, internal, best Community: 10578:700 11537:950 Last update: Sat Jan 14 04:45:09 2006

Specific entry. Can do longest prefix lookup: Prefix

AS path Next-hop

11 CSE 222A – Lecture 4: Routing"

Page 12: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

  Local preference: numerical value assigned by routing policy. Higher values are more preferred.

  AS path length: number of AS-level hops in the path   Multiple exit discriminator (“MED”): allows one AS to specify that

one exit point is more preferred than another. Lower values are more preferred.

  eBGP over iBGP   Shortest IGP path cost to next hop: implements “hot potato”

routing   Router ID tiebreak: arbitrary tiebreak, since only a single “best”

route can be selected

BGP routes have the following attributes, on which the route selection process is based:

12 CSE 222A – Lecture 4: Routing"

BGP Route Selection"

Page 13: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Other BGP Attributes"

  Next-hop: IP address to send packets en route to destination. (Question: How to ensure that the next-hop IP address is reachable?)

  Community value: Semantically meaningless. Used for passing around “signals” and labelling routes. More in a bit.

Next-hop: 4.79.2.1 iBGP

4.79.2.1 4.79.2.2

Next-hop: 192.5.89.89

13 CSE 222A – Lecture 4: Routing"

Page 14: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Local Preference"

  Control over outbound traffic   Not transitive across ASes   Coarse hammer to implement route preference   Useful for preferring routes from one AS over another

(e.g., primary-backup semantics)

Primary

Backup

Higher local pref

Lower local pref

Destination

14 CSE 222A – Lecture 4: Routing"

Page 15: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Communities and Local Pref"

  Customer expresses provider that a link is a backup   Affords some control over inbound traffic

Primary

Backup

“Backup” Community

Destination

15 CSE 222A – Lecture 4: Routing"

Page 16: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

AS Path Length"

  Among routes with highest local preference, select route with shortest AS path length

  Shortest AS path != shortest path, for any interpretation of “shortest path”

Destination

Traffic

16 CSE 222A – Lecture 4: Routing"

Page 17: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Hot-Potato Routing"  Prefer route with shorter IGP path cost to next-hop   Idea: traffic leaves AS as quickly as possible

I

New York Atlanta

Washington, DC

5 10

Dest.

Common practice: Set IGP weights in accordance with propagation delay (e.g., miles, etc.)

Traffic

17 CSE 222A – Lecture 4: Routing"

Page 18: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Hot-Potato Dynamics"  Small changes in IGP weights can have significant

impact

18

I

San Fran New York

LA

5 10

Dest.

Traffic

11

CSE 222A – Lecture 4: Routing"

Page 19: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Internet Business Model (Simplified)"

  Customer/Provider: One AS pays another for reachability to some set of destinations

  “Settlement-free” Peering: Bartering. Two ASes exchange routes with one another.

Provider

Peer

Customer

Preferences implemented with local preference manipulation

Destination

Pay to use

Get paid to use

Free to use

19 CSE 222A – Lecture 4: Routing"

Page 20: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

End-to-End Routing Behavior"  Importance of paper

◆  Revitalized field of network measurement ◆  Use of statistical techniques to capture new types of

measurements ◆  Empirical findings of routing behavior

(motivation for future work)

  Various routing pathologies ◆  Routing loops ◆  Erroneous ◆  Connectivity altered mid-stream ◆  Fluttering…

20 CSE 222A – Lecture 4: Routing"

Page 21: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Measurement With Traceroute"  Traceroute tool to measure the forwarding path

◆  Send packets with TTL=1, 2, 3… ◆  Record the source of the “time exceeded” message

  Useful, but introduces many challenges ◆  Path changes ◆  Non-participating nodes ◆  Inaccurate, two-way measurements

source! destination!

TTL=1!Time! exceeded!

TTL=2!

21 CSE 222A – Lecture 4: Routing"

Page 22: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

Questions"  Why can’t we measure the Internet more directly?

◆  What can we do about it?

  Right division of labor between host and network? ◆  For path selection ◆  For network monitoring

  How do we fix these routing problems? ◆  In a decentralized, federated network ◆  How to incentivize better network management

22 CSE 222A – Lecture 4: Routing"

Page 23: Lecture 4: Routing - University of California, San Diego€¦ · Example BGP Routing Table" > show ip bgp Network Next Hop Metric LocPrf Weight Path *>i3.0.0.0 4.79.2.1 0 110 0 3356

For Next Class…"

  Read and review Wetherall ’98

  Keep thinking about term project ideas/groups ◆  Initial ideas due on Tuesday ◆  Email to Siva

23 CSE 222A – Lecture 4: Routing"


Recommended