Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Network Layer: Routing Intra- and Inter-Domain Routing Y. Richard Yang 4/18/2016.

Similar presentations


Presentation on theme: "1 Network Layer: Routing Intra- and Inter-Domain Routing Y. Richard Yang 4/18/2016."— Presentation transcript:

1 1 Network Layer: Routing Intra- and Inter-Domain Routing Y. Richard Yang http://zoo.cs.yale.edu/classes/cs433/ 4/18/2016

2 2 Admin r Suggested projects to be posted Tuesday m Please think about your own projects

3 Recap: Distance Vector Routing r Basic DV protocol m take away: use monotonicity as a technique to understand liveness/convergence highly recommended reading of Bersekas/Gallager chapter r DSDV, EIGRP m take away: use global invariants to understand/design safety/no routing loops 3

4 Recap: Link State r Basic LS protocol m take away: instead of computing routing results using distributed computing, distributed computing is for only link state distribution (synchronization) r Link state distribution can still have much complexity, e.g., out of order delivery, partition and reconnect, scalability 4

5 LS Protocol: OSPF (Open Shortest Path First) v2 r Implements link state (LS) packet dissemination m topology map at each node m All OSPF msgs are authenticated r Specify standard Dijkstra’s algorithm as path compute alg m Allows multiple same-cost paths m Multiple cost metrics per link (for type of service routing) 5 https://tools.ietf.org/html/rfc2328

6 Hierarchical OSPF “summarize” distances to nets in own area, advertise to other Area Border routers. run OSPF routing limited to backbone. - Link-state advertisements only in area each nodes has detailed area topology; - only know direction (shortest path) to nets in other areas. Two-level hierarchy: local area, backbone. 6

7 Outline  Admin and recap  Routing in the Internet 7

8 Discussion r Requirements of Internet-scale routing m DV or LS? 8

9 Routing in the Internet: Routing w/ AS r The Global Internet consists of Autonomous Systems (AS) interconnected with each other m An AS is identified by an AS Number (ASN), e.g. Yale ASN is 29 m Each AS owns part of IP address space m Autonomous systems interconnect at either public or private peering points 9 https://www.ultratools.com/tools/asnInfo

10 Routing with AS r Internet routing is divided into intra-AS routing and inter-AS routing r Intra-AS m A protocol running insides an AS is called an Interior Gateway Protocol (IGP), each AS can choose its own: RIP: Routing Information Protocol E/IGRP: Interior Gateway Routing Protocol (Cisco) OSPF: Open Shortest Path First IS-IS: very similar to OSPF (or should we say OSPF is very similar to IS-IS?) r Inter-AS m a protocol runs among AS’s is also called an Exterior Gateway Protocol (EGP)

11 BGP Routing r The de facto Inter-domain routing standard is BGP (Border Gateway Protocol) r BGP is a Path Vector protocol: m similar to Distance Vector protocol m a border gateway sends to a neighbor entire path (i.e., a sequence of ASNs) to a destination, e.g., gateway X sends to neighbor N its path to dest. Z: path (X,Z) = X,Y1,Y2,Y3,…,Z m if N selects path(X, Z) advertised by X, then: path (N,Z) = N, path (X,Z) X N Z

12 Routing with AS a b b a a C A B d c A.a A.c C.b B.a c b border (exterior gateway) routers interior (gateway) routers

13 b a AS C (RIP intra routing) Intra-AS, BGP Integration c AS B (OSPF intra routing) AS A (OSPF intra routing) eBGP iBGP Gateway routers participate in intradomain to learn internal routes. Gateway routers of diff. AS’s exchange routes using eBGP gateway routers of same AS share learned external routes using iBGP. i e f g h d Inter-AS routers form an overlay

14 Many Routing Processes on a Single Router Forwarding Table OSPF domain RIP domain BGP OS kernel RIP process RIP routing table Forwarding Table Manager OSPF process OSPF Routing table BGP process BGP routing table

15 BGP Operations (Simplified) Establish session on TCP port 179 Exchange all active routes Exchange incremental updates AS1 AS2 while (connection is ALIVE) exchange UPDATE message select best available route if route changes, export to neigh. BGP session

16 BGP Messages r Four types of messages m OPEN: opens TCP connection to peer and authenticates sender m UPDATE: advertises new path (or withdraws old) m KEEPALIVE keeps connection alive in absence of UPDATES; also ACKs OPEN request m NOTIFICATION: reports errors in previous msg; also used to close connection

17 Summary: Benefits of Internet Hierarchical Routing  ASes have flexibility to choose their own intra-AS routing protocols - allows autonomy  Only a small # of routers (gateways) from each AS in the inter-AS level - improves scalability  Inter-AS route represented as a list of ASNs instead of detailed routers - improves scalability/privacy

18 Issue: Hierarchical Routing May Pay a Price for Path Quality AS 4 AS 3 AS 2 AS 1

19 Outline  Admin and recap  Routing in the Internet o Internet as hierarchical routing  BGP as policy routing 19

20 BGP Policy Routing routing cache select best path export path to neighbors route selection policy: rank paths export policy: which paths export to which neighbors Yale QwestAT&T Internet2 1 3 0 1 0

21 21 BGP Example 1 AS A (OSPF) AS B (OSPF intra routing) AS D AS C i b b->i: I can reach hosts in D; my path: BCD a1 a2 d d->a2: I can reach hosts in D; my path: D a1->i: I can reach hosts in D; my path: AD E F Export to E: i->e: I can reach hosts in D; path: IAD AS I a2->a1: I can reach hosts in D; path: D Route selection policy: - Shortest AS Path policy: b->i2: I can reach hosts in D; my path: BCD i2 i2->i: I can reach hosts in D; path: BCD No Export to F (why?) Choose AD using a1

22 22 BGP Example 2 AS A (OSPF) AS B (OSPF intra routing) AS D AS C i b b->i: I can reach hosts in D; my path: BCD a1 a2 d d->a2: I can reach hosts in D; my path: D a1->i: I can reach hosts in D; my path: AD E F Export to E: i->e: I can reach hosts in D; path: IBCD AS I a2->a1: I can reach hosts in D; path: D Selection policy: - Low local_pref for A - Shortest AS Path - Prefer eBGP (hot potato) b->i2: I can reach hosts in D; my path: BCD i2 i2->i: I can reach hosts in D; path: BCD Choose BCD using b

23 23 Routing: Example 3 AS A (OSPF) AS B (OSPF intra routing) AS D AS C i b b->i: I can reach hosts in D; my path: BCD a1 a2 d d->a2: I can reach hosts in D; my path: D a1->i: I can reach hosts in D; my path: AD E F Export to E: i->e: I can reach hosts in D; path: IBCD AS I a2->a1: I can reach hosts in D; path: D Selection policy: - Low local_pref A - Shortest AS Path - Prefer iBGP (cold potato) b->i2: I can reach hosts in D; my path: BCD i2 i2->i: I can reach hosts in D; path: BCD Choose BCD using i2

24 Observing BGP Paths r Using one of the looking glass servers: http://www.bgp4.as/looking-glasses 24

25 Outline  Admin and recap  Routing in the Internet o Overview o BGP as policy routing  Analysis of BGP policy routing 25

26 Motivation: Policy Routing May Lead to Instability 2 0 3 1 2 1 0 2 0 1 3 0 1 0 3 2 0 3 0 4 3 preferred less preferred The BAD GADGET example: - 0 is the destination - the route selection policy of each AS is to prefer its counter clock-wise neighbor Policy interaction causes routing instability !

27 Key Tool to Understand Policy Routing: P-Graph r Nodes in P-graph are feasible paths r Edges represent priority (low to high) m A directed edge from path N 1 P 1 to P 1 intuition: to let N 1 choose N 1 P 1, P 1 must be chosen and exported to N 1 m A directed edge from a lower ranked path to a higher ranked path intuition: the higher ranked path should be considered first 2 1 0 2 0 1 0 3 0 1 3 0 3 2 0 P-graph 2 0 1 3 320 30 210 20 130 10

28 Partial Order Graph and BGP Convergence  If the P-graph has no loop, then BGP policy converges.  intuition: choose the path node from the partial order graph with no out-going edge to non-fixed path nodes, fix the path node, eliminate all no longer feasible; continue  Example: suppose we swap the order of 30 and 320 2 1 0 2 0 1 0 3 0 1 3 0 3 2 0 2 0 1 3 30 320 210 20 130 10

29 Question Do we often see path instability in the Internet? Surpise: the current Internet ISP economics implies no loop in P-graph !

30 Internet Economy: Two Types of Business Relationship r Customer provider relationship m a provider is an AS that connects the customer to the rest of the Internet m customer pays the provider for the transit service m e.g., Yale is a customer of AT&T and QWEST r Peer-to-peer relationship m mutually agree to exchange traffic between their respective customers only m there is no payment between peers provider customer peer provider provider to customer

31 Implication of Economics: Route Selection Policies r Route selection (ranking) policy: m the typical route selection policy is to prefer customers over peers/providers to reach a destination, i.e., Customer > pEer/Provider provider customer peer

32 customer provider customer peer Implication of Economics : Export Policies provider customer peer provider customer peer routes learned from a customer are sent to all other neighbors routes learned from a provider are sent only to customers routes learned from a peer are sent only to customers case 1: routes learned from customer case 2: routes learned from provider case 3: routes learned from peer

33 Example: Typical Export -> No-Valley Routing P1P1 A P2P2 IP traffic A advertises path to C, but not P 2 A advertises to C paths to P 1 and P 2 A advertises path to C, but not P 1 Suppose P 1 and P 2 are providers of A; A is a provider of C C A learns paths to C, P1, P2

34 Typical Export Policies Imply Patterns of Routes r Assume a BGP path SABCD to destination AS D. Consider the business relationship between each pair: r Three types of business relationships: m PC (provider-customer) m CP (customer-provider) m PP (peer-peer) 34 S A B C D

35 Typical Export Policies Imply Patterns of Routes r Invariant 1 of valid BGP routes (with labels representing business relationship) P C ? Dest P C Reasoning: only route learned from customer is sent to provider; thus after a PC, it is always PC to the destination

36 Typical Export Policies Imply Patterns of Routes r Invariant 2 of valid BGP routes (with labels representing business relationship) CP/PP ? CP ······ Dest Reasoning: routes learned from peer or provider are sent to only customers; thus all relationship before is CP

37 Stability of BGP Policy Routing r Suppose 1. there is no loop formed by provider-customer relationship in the Internet 2. each AS uses typical route selection policy: C > E/P 3. each AS uses the typical export policies  Then policy routing always converges (i.e., is stable).

38 Case 1: A Link is PC PC Proof by contradiction. Assume a loop in P-graph. Consider a fixed link. in the loop PC AS 1AS 2 AS 3AS 4

39 Case 2: Link is CP/PP CP/PP CP CP/PP CP AS 1AS 2 AS 3AS 4

40 Summary: BGP Policy Routing  Advantage - satisfies real demand  Issue - policy dispute can lead to instability -current Internet economy provides a stability framework, but if the framework changes, we may see instability  Comment: -a policy routing framework is a preference (ranking) aggregation framework -a fundamental negative result is Arrow’s Impossibility Theorem (http://en.wikipedia.org/wiki/Arrow's_impossibi lity_theorem)

41 Summary: BGP Policy Routing  Many potential directions to explore o The basic idea of path vector is to share the results of computation. Instead of path vector, how about secure multi-party computation? o ….


Download ppt "1 Network Layer: Routing Intra- and Inter-Domain Routing Y. Richard Yang 4/18/2016."

Similar presentations


Ads by Google