47
Ming Liu mgliu@cs.wisc.edu Introduction to Computer Networks CS640 https://pages.cs.wisc.edu/~mgliu/CS640/F21/ Inter-domain Routing 1

Introduction to Computer Networks CS640 Inter-domain Routing

  • Upload
    others

  • View
    15

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Introduction to Computer Networks CS640 Inter-domain Routing

Ming Liu [email protected]

Introduction to Computer Networks

CS640 https://pages.cs.wisc.edu/~mgliu/CS640/F21/

Inter-domain Routing

1

Page 2: Introduction to Computer Networks CS640 Inter-domain Routing

Today

Last lecture • Link State Routing

• Link Weights • Router/Switch Design

2

Today • Inter-domain Routing

Announcements • Lab2 due today at 11:59PM

Page 3: Introduction to Computer Networks CS640 Inter-domain Routing

Internet Structure

Original idea

3

Page 4: Introduction to Computer Networks CS640 Inter-domain Routing

Today

Internet Structure (cont’d)

4

Page 5: Introduction to Computer Networks CS640 Inter-domain Routing

Route Propagation in the Internet

Autonomous System (AS) • Corresponds to an administrative domain

• Examples: University, company, backbone network • Assign each AS a 16-bit number

Two-level routing hierarchy • interior gateway protocol (each AS selects its own)

• exterior gateway protocol (Internet-wide standard)

5

Page 6: Introduction to Computer Networks CS640 Inter-domain Routing

Route Propagation in the Internet (cont’d)

Route information is propagated at various levels • Hosts know local router • Local routers know site routers • Site routers know core router • Core routers know everything

6

Page 7: Introduction to Computer Networks CS640 Inter-domain Routing

Popular Interior Gateway Protocols

7

Page 8: Introduction to Computer Networks CS640 Inter-domain Routing

Popular Interior Gateway Protocols

RIP: Router Information Protocol • Distributed with BSD Unix • Distance-vector algorithm

• Based on hop-count (infinity set to 16)

OSPF: Open Shortest Path First • Uses link-state algorithm

• Supports load balancing

• Supports authentication

7

Page 9: Introduction to Computer Networks CS640 Inter-domain Routing

BGP-4: Border Gateway Protocol

BGP-1 developed in 1989 to address problems with EGP

Assumes Internet is an arbitrarily interconnected set of ASs

8

Page 10: Introduction to Computer Networks CS640 Inter-domain Routing

BGP-4: Border Gateway Protocol (cont’d)

AS traffic types • Local: starts or ends within an AS

• Transit: passes through an AS

AS types • stub AS: has a single connection to one other AS

• carries local traffic only • multi-homed AS: has connections to more than one AS

• refuses to carry transit traffic • transmit AS: has connections to more than one AS

• carries both transmit and local traffic

9

Page 11: Introduction to Computer Networks CS640 Inter-domain Routing

BGP-4: Border Gateway Protocol (cont’d)

AS traffic types • Local: starts or ends within an AS

• Transit: passes through an AS

AS types • stub AS: has a single connection to one other AS

• carries local traffic only • multi-homed AS: has connections to more than one AS

• refuses to carry transit traffic • transmit AS: has connections to more than one AS

• carries both transmit and local traffic

19

Page 12: Introduction to Computer Networks CS640 Inter-domain Routing

AS Characteristics

#1: Each AS has one or more border routers • Handles inter-AS traffic

#2: At least one BGP speaker for an AS that participates in routing • Border routers might or might not be BGP speakers

11

Page 13: Introduction to Computer Networks CS640 Inter-domain Routing

AS Characteristics (cont’d)

#3: BGP speaker establishes BGP sessions with peers and advertises • Local network names • Other reachable networks (transit AS only) • Give path information — AS Path, or Path vector • Withdraw routes

12

Page 14: Introduction to Computer Networks CS640 Inter-domain Routing

AS Characteristics (cont’d)

#3: BGP speaker establishes BGP sessions with peers and advertises • Local network names • Other reachable networks (transit AS only) • Give path information — AS Path, or Path vector • Withdraw routes

• Peers: neighbor routers exchange routing information • Advertises: an AS publicizes its learned routing information

12

Page 15: Introduction to Computer Networks CS640 Inter-domain Routing

AS Characteristics (cont’d)

#3: BGP speaker establishes BGP sessions with peers and advertises • Local network names • Other reachable networks (transit AS only) • Give path information — AS Path, or Path vector • Withdraw routes

• Peers: neighbor routers exchange routing information • Advertises: an AS publicizes its learned routing information

• Unlike RIP and OSPF, BGP advertises complete path as an enumerated list of autonomous systems to reach a particular network

12

Page 16: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Example

Speaker for AS2 advertises reachability to P and Q • Network 128.96, 192.4.153, 192.4.32, and 192.4.3, can be reached directly from AS2

13

Page 17: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Example (cont’d)

Speaker for backbone advertises • Network 128.96, 192.4.153, 192.4.32, and 192.4.3, can be reached directly from (AS1, AS2)

14

Page 18: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Example (cont’d)

Speaker can cancel previously advertised paths

15

Page 19: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Goal

Find loop free paths between ASes • Optimality is secondary goal • It’s neither a distance-vector nor a link-state protocol

128.96, can be reached via AS2

16

Page 20: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Goal

Find loop free paths between ASes • Optimality is secondary goal • It’s neither a distance-vector nor a link-state protocol

128.96, can be reached via AS2

128.96, can be reached via (AS2 ,AS1)

16

Page 21: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Goal

Find loop free paths between ASes • Optimality is secondary goal • It’s neither a distance-vector nor a link-state protocol

128.96, can be reached via AS2

128.96, can be reached via (AS2 ,AS1)

128.96, can be reached via (AS2 ,AS1, AS3)

16

Page 22: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Goal

Find loop free paths between ASes • Optimality is secondary goal • It’s neither a distance-vector nor a link-state protocol

128.96, can be reached via AS2

128.96, can be reached via (AS2 ,AS1)

128.96, can be reached via (AS2 ,AS1, AS3)

AS2 sees itself in the path <AS2, AS1, AS3, AS4>

AS numbers carried in BGP need to be unique

16

Page 23: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Goal

Find loop free paths between ASes • Optimality is secondary goal • It’s neither a distance-vector nor a link-state protocol

Challenges • Internet’s size (~12K active ASs) means large tables in BGP routers • Policy-compliant path (not just scalar cost of a path)

• Autonomous domains mean different path metrics • Trust among different ASs

17

Page 24: Introduction to Computer Networks CS640 Inter-domain Routing

Policy with BGP

BGP provides capability for enforcing various policies

Enforces policies by • Choosing appropriate paths from multiple alternatives —> import policies • Controlling advertisement to other AS —> export policies

Policies are not part of BGP: they are provided to BGP as configuration information

18

Page 25: Introduction to Computer Networks CS640 Inter-domain Routing

Illustrating BGP Policies

19

Page 26: Introduction to Computer Networks CS640 Inter-domain Routing

Peering and Customer-Provider

Peering relationship • Peers provide transit to each other • Peering relationships are free and involve no money exchange

Customer-Provider relationship • Customers use providers to reach the rest of the Internet • Customers pay providers for this

20

Page 27: Introduction to Computer Networks CS640 Inter-domain Routing

Import Policy: Prefer Customer Routing

21

Page 28: Introduction to Computer Networks CS640 Inter-domain Routing

Import Policy: Prefer Customer Routing

Route learned from customer > Route leaned from peer > Route leaned from provider

21

Page 29: Introduction to Computer Networks CS640 Inter-domain Routing

Import Policy: Prefer Customer Routing

21

Page 30: Introduction to Computer Networks CS640 Inter-domain Routing

Import Policy: Prefer Customer Routing

Set appropriate “local pref” to reflect preferences: higher local preference values are preferred.

21

Page 31: Introduction to Computer Networks CS640 Inter-domain Routing

Import Routes

22

Page 32: Introduction to Computer Networks CS640 Inter-domain Routing

Export Routes

23

Page 33: Introduction to Computer Networks CS640 Inter-domain Routing

BGP Export Policies

24

Page 34: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example

Consider a network with 13 ASes. They have the following relationships: • AS1 is the provider for AS2, AS3, and AS4

• AS2 is the provider for AS11 and AS13

• AS2 and AS3 are peers; AS3 and AS4 are peers • AS3 is the provider for AS5 and AS6

• AS4 is the provider for AS7 and AS8

• AS5 is the provider for AS11

• AS6 is the provider for AS12

• AS11 and AS12 are peers • AS7 is the provider for AS9

• AS8 is the provider for AS10 25

Page 35: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

26

Page 36: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

What is the AS path used for AS7-> AS11?

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

27

Page 37: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

What is the AS path used for AS7-> AS11? • AS7 -> AS4 -> AS3 -> AS5 -> AS11

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

27

Page 38: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

What is the AS path used for AS12-> AS13?

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

28

Page 39: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

What is the AS path used for AS12-> AS13? • AS12->AS6->AS3->AS2->AS13

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

28

Page 40: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

Is (AS13, AS2, AS3, AS4, AS8, AS10) a valid path to go from a host in AS13 to a host in AS10?

29

Page 41: Introduction to Computer Networks CS640 Inter-domain Routing

A BGP Example (cont’d)Is (AS13, AS2, AS3, AS4, AS8, AS10) a valid path to go from a host in AS13 to a host in AS10? => No!

AS1

AS2 AS3 AS4

AS13 AS5 AS6 AS7 AS8

AS11 AS12 AS9 AS10

29

Page 42: Introduction to Computer Networks CS640 Inter-domain Routing

BGP implementations

Path vectors are most important innovations in BGP • Enable loop presentation in complex topologies • If AS sees itself in the path, it will not use that path

Routes can be aggregated • Based on the CIDR (classless) addressing

Routers can be filtered

Runs over TCP

30

Page 43: Introduction to Computer Networks CS640 Inter-domain Routing

BGP in Practice

10-20 “backbone” ASs which are fairly richly connected to each other • Peers

Other “low tier” ASs hang off the backbone networks —> Customers • Some of them may also connect with each other at peering points —> Peers

Corporations connect as Customers to lower tier ASs or to backbone ASs depending on their need or willingness to pay 31

Page 44: Introduction to Computer Networks CS640 Inter-domain Routing

BGP in Reality

32

Page 45: Introduction to Computer Networks CS640 Inter-domain Routing

BGP in Reality

32

Page 46: Introduction to Computer Networks CS640 Inter-domain Routing

BGP in Reality

BGP routing policies in ISP networks, IEEE Network 2005

• https://www.cs.princeton.edu/~jrex/papers/policies.pdf Running BGP in Data Centers at Scale, NSDI 2021

• https://www.usenix.org/conference/nsdi21/presentation/abhashkumar

32

Page 47: Introduction to Computer Networks CS640 Inter-domain Routing

Summary

Today • Inter-domain Routing

Next lecture • Multicast • IPv6

• Software-defined network (SDN)

33