15-441 Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)

Slides:



Advertisements
Similar presentations
BGP.
Advertisements

CS Summer 2003 CS672: MPLS Architecture, Applications and Fault-Tolerance.
Border Gateway Protocol Ankit Agarwal Dashang Trivedi Kirti Tiwari.
CS540/TE630 Computer Network Architecture Spring 2009 Tu/Th 10:30am-Noon Sue Moon.
Lecture 9 Overview. Hierarchical Routing scale – with 200 million destinations – can’t store all dests in routing tables! – routing table exchange would.
© J. Liebeherr, All rights reserved 1 Border Gateway Protocol This lecture is largely based on a BGP tutorial by T. Griffin from AT&T Research.
Border Gateway Protocol Autonomous Systems and Interdomain Routing (Exterior Gateway Protocol EGP)
Fundamentals of Computer Networks ECE 478/578 Lecture #18: Policy-Based Routing Instructor: Loukas Lazos Dept of Electrical and Computer Engineering University.
1 Interdomain Routing Protocols. 2 Autonomous Systems An autonomous system (AS) is a region of the Internet that is administered by a single entity and.
Univ. of TehranComputer Network1 Computer Networks Computer Networks (Graduate level) University of Tehran Dept. of EE and Computer Engineering By: Dr.
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization –All routers are identical –Network is flat. Not true in Practice Hierarchical.
The Border Gateway Protocol (BGP) Sharad Jaiswal.
Computer Networking Lecture 10: Inter-Domain Routing
15-744: Computer Networking L-5 Inter-Domain Routing.
15-744: Computer Networking L-6 Inter-Domain Routing.
14 – Inter/Intra-AS Routing
© 2009 Cisco Systems, Inc. All rights reserved. ROUTE v1.0—6-1 Connecting an Enterprise Network to an ISP Network Considering the Advantages of Using BGP.
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)
Computer Networks Layering and Routing Dina Katabi
Inter-domain Routing Don Fussell CS 395T Measuring Internet Performance.
14 – Inter/Intra-AS Routing Network Layer Hierarchical Routing scale: with > 200 million destinations: can’t store all dest’s in routing tables!
1 Computer Communication & Networks Lecture 22 Network Layer: Delivery, Forwarding, Routing (contd.)
© Janice Regan, CMPT 128, CMPT 371 Data Communications and Networking BGP, Flooding, Multicast routing.
1 Interdomain Routing (BGP) By Behzad Akbari Fall 2008 These slides are based on the slides of Ion Stoica (UCB) and Shivkumar (RPI)
CS 3700 Networks and Distributed Systems Inter Domain Routing (It’s all about the Money) Revised 8/20/15.
Routing protocols Basic Routing Routing Information Protocol (RIP) Open Shortest Path First (OSPF)
Lecture 4: BGP Presentations Lab information H/W update.
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)
Border Gateway Protocol
BGP V1.1. When is BGP Applicable Basic BGP Peer Configuration Troubleshooting BGP Connections BGP Operation and Path Attributes Route Import/Export Selected.
Network Layer r Introduction r Datagram networks r IP: Internet Protocol m Datagram format m IPv4 addressing m ICMP r What’s inside a router r Routing.
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)
Xuan Zheng (modified by M. Veeraraghavan) 1 BGP overview BGP operations BGP messages BGP decision algorithm BGP states.
Advance Computer Networking L-3 BGP Acknowledgments: Lecture slides are from the graduate level Computer Networks course thought by Srinivasan Seshan at.
Border Gateway Protocol (BGP) W.lilakiatsakun. BGP Basics (1) BGP is the protocol which is used to make core routing decisions on the Internet It involves.
More on Internet Routing A large portion of this lecture material comes from BGP tutorial given by Philip Smith from Cisco (ftp://ftp- eng.cisco.com/pfs/seminars/APRICOT2004.
T. S. Eugene Ngeugeneng at cs.rice.edu Rice University1 COMP/ELEC 429/556 Introduction to Computer Networks Inter-domain routing Some slides used with.
Network Layer4-1 Intra-AS Routing r Also known as Interior Gateway Protocols (IGP) r Most common Intra-AS routing protocols: m RIP: Routing Information.
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol) Copyright ©, Carnegie Mellon University.
CSCI-1680 Network Layer: Inter-domain Routing Based partly on lecture notes by Rob Sherwood, David Mazières, Phil Levis, Rodrigo Fonseca John Jannotti.
An internet is a combination of networks connected by routers. When a datagram goes from a source to a destination, it will probably pass through many.
Routing in the Inernet Outcomes: –What are routing protocols used for Intra-ASs Routing in the Internet? –The Working Principle of RIP and OSPF –What is.
CS 640: Introduction to Computer Networks Aditya Akella Lecture 11 - Inter-Domain Routing - BGP (Border Gateway Protocol)
1 Agenda for Today’s Lecture The rationale for BGP’s design –What is interdomain routing and why do we need it? –Why does BGP look the way it does? How.
15-744: Computer Networking
1 Border Gateway Protocol (BGP) and BGP Security Jeff Gribschaw Sai Thwin ECE 4112 Final Project April 28, 2005.
BGP and ICMP. Exterior Gateway Protocol (EGP) Like RIP, but no metrics. Just if reachable. Rtr inside a domain collects reachability information and informs.
BGP Basics BGP uses TCP (port 179) BGP Established unicast-based connection to each of its BGP- speaking peers. BGP allowing the TCP layer to handle such.
Text BGP Basics. Document Name CONFIDENTIAL Border Gateway Protocol (BGP) Introduction to BGP BGP Neighbor Establishment Process BGP Message Types BGP.
Michael Schapira, Princeton University Fall 2010 (TTh 1:30-2:50 in COS 302) COS 561: Advanced Computer Networks
Inter-domain Routing Outline Border Gateway Protocol.
CS 640: Introduction to Computer Networks Aditya Akella Lecture 11 - Inter-Domain Routing - BGP (Border Gateway Protocol)
Border Gateway Protocol BGP-4 BGP environment How BGP works BGP information BGP administration.
Inter-Domain Routing. Routing Hierarchies Flat routing doesn’t scale –Each node cannot be expected to have routes to every destination (or destination.
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)
Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol) Copyright ©, Carnegie Mellon University.
ROUTING ON THE INTERNET COSC Jun-16. Routing Protocols  routers receive and forward packets  make decisions based on knowledge of topology.
1 Internet Routing 11/11/2009. Admin. r Assignment 3 2.
1 CS716 Advanced Computer Networks By Dr. Amir Qayyum.
CS 3700 Networks and Distributed Systems
CS 3700 Networks and Distributed Systems
Border Gateway Protocol
BGP supplement Abhigyan Sharma.
CSCI-1680 Network Layer: Inter-domain Routing
Department of Computer and IT Engineering University of Kurdistan
Dan LI CS Department, Tsinghua University
COMP/ELEC 429/556 Introduction to Computer Networks
BGP Instability Jennifer Rexford
Computer Networks Protocols
Presentation transcript:

Computer Networking Inter-Domain Routing BGP (Border Gateway Protocol)

10/4/07 Lecture #11: Inter-Domain Routing2 Routing Review The Story So Far… Routing protocols generate the forwarding table Two styles: distance vector, link state Scalability issues: Distance vector protocols suffer from count-to-infinity Link state protocols must flood information through network Today’s lecture How to make routing protocols support large networks How to make routing protocols support business policies

10/4/07 Lecture #11: Inter-Domain Routing3 Outline Routing hierarchy Internet structure External BGP (E-BGP)

10/4/07 Lecture #11: Inter-Domain Routing4 Routing Hierarchies Flat routing doesn’t scale Storage  Each node cannot be expected to store routes to every destination (or destination network) Convergence times increase Communication  Total message count increases Key observation Need less information with increasing distance to destination Need lower diameters networks Solution: area hierarchy

10/4/07 Lecture #11: Inter-Domain Routing5 Areas Divide network into areas Areas can have nested sub-areas Hierarchically address nodes in a network Sequentially number top-level areas Sub-areas of area are labeled relative to that area Nodes are numbered relative to the smallest containing area

10/4/07 Lecture #11: Inter-Domain Routing6 Routing Hierarchy Partition Network into “Areas” Within area Each node has routes to every other node Outside area Each node has routes for other top-level areas only Inter-area packets are routed to nearest appropriate border router Constraint: no path between two sub-areas of an area can exit that area Backbone Areas Lower-level Areas Area-Border Router

10/4/07 Lecture #11: Inter-Domain Routing7 Area Hierarchy Addressing

10/4/07 Lecture #11: Inter-Domain Routing8 Path Sub-optimality hop red path vs. 2 hop green path start end Can result in sub-optimal paths

10/4/07 Lecture #11: Inter-Domain Routing9 Outline Routing hierarchy Internet structure External BGP (E-BGP)

10/4/07 Lecture #11: Inter-Domain Routing10 A Logical View of the Internet? R R R RR After looking at RIP/OSPF descriptions End-hosts connected to routers Routers exchange messages to determine connectivity NOT TRUE!

10/4/07 Lecture #11: Inter-Domain Routing11 Internet’s Area Hierarchy What is an Autonomous System (AS)? A set of routers under a single technical administration, using an interior gateway protocol (IGP) and common metrics to route packets within the AS and using an exterior gateway protocol (EGP) to route packets to other AS’s Each AS assigned unique ID AS’s peer at network exchanges

10/4/07 Lecture #11: Inter-Domain Routing12 AS Numbers (ASNs) ASNs are 16 bit values64512 through are “private” Genuity: 1 MIT: 3 CMU: 9 UC San Diego: 7377 AT&T: 7018, 6341, 5074, … UUNET: 701, 702, 284, 12199, … Sprint: 1239, 1240, 6211, 6242, … … ASNs represent units of routing policy Currently over 15,000 in use

10/4/07 Lecture #11: Inter-Domain Routing13 Example EGP IGP EGP IGP EGP

10/4/07 Lecture #11: Inter-Domain Routing14 A Logical View of the Internet? R R R RR RIP/OSPF not very scalable  area hierarchies NOT TRUE EITHER! ISP’s aren’t equal Size Connectivity ISP

10/4/07 Lecture #11: Inter-Domain Routing15 A Logical View of the Internet Tier 1 Tier 2 Tier 3 Tier 1 ISP “Default-free” with global reachability info Tier 2 ISP Regional or country-wide Tier 3 ISP Local Customer Provider

10/4/07 Lecture #11: Inter-Domain Routing16 Transit vs. Peering ISP X ISP Y ISP Z ISP P Transit ($$) Transit ($$$) Transit ($$ 1/2) Transit ($$) Peering Transit ($$$) Transit ($) Transit ($$) Transit ($$$)

10/4/07 Lecture #11: Inter-Domain Routing17 Policy Impact “Valley-free” routing Number links as (+1, 0, -1) for provider, peer and customer In any path should only see sequence of +1, followed by at most one 0, followed by sequence of -1 WHY? Consider the economics of the situation

10/4/07 Lecture #11: Inter-Domain Routing18 Outline Routing hierarchy Internet structure External BGP (E-BGP)

10/4/07 Lecture #11: Inter-Domain Routing19 Choices Link state or distance vector? No universal metric – policy decisions Problems with distance-vector: Bellman-Ford algorithm may not converge Problems with link state: Metric used by routers not the same – loops LS database too large – entire Internet May expose policies to other AS’s

10/4/07 Lecture #11: Inter-Domain Routing20 Solution: Distance Vector with Path Each routing update carries the entire path Loops are detected as follows: When AS gets route, check if AS already in path If yes, reject route If no, add self and (possibly) advertise route further Advantage: Metrics are local - AS chooses path, protocol ensures no loops

10/4/07 Lecture #11: Inter-Domain Routing21 Interconnecting BGP Peers BGP uses TCP to connect peers Advantages: Simplifies BGP No need for periodic refresh - routes are valid until withdrawn, or the connection is lost Incremental updates Disadvantages Congestion control on a routing protocol? Poor interaction during high load

10/4/07 Lecture #11: Inter-Domain Routing22 Hop-by-hop Model BGP advertises to neighbors only those routes that it uses Consistent with the hop-by-hop Internet paradigm e.g., AS1 cannot tell AS2 to route to other AS’s in a manner different than what AS2 has chosen (need source routing for that) BGP enforces policies by choosing paths from multiple alternatives and controlling advertisement to other AS’s

10/4/07 Lecture #11: Inter-Domain Routing23 Examples of BGP Policies A multi-homed AS refuses to act as transit Limit path advertisement A multi-homed AS can become transit for some AS’s Only advertise paths to some AS’s An AS can favor or disfavor certain AS’s for traffic transit from itself

10/4/07 Lecture #11: Inter-Domain Routing24 BGP Messages Open Announces AS ID Determines hold timer – interval between keep_alive or update messages, zero interval implies no keep_alive Keep_alive Sent periodically (but before hold timer expires) to peers to ensure connectivity. Sent in place of an UPDATE message Notification Used for error notification TCP connection is closed immediately after notification

10/4/07 Lecture #11: Inter-Domain Routing25 BGP UPDATE Message List of withdrawn routes Network layer reachability information List of reachable prefixes Path attributes Origin Path Metrics All prefixes advertised in message have same path attributes

10/4/07 Lecture #11: Inter-Domain Routing26 Path Selection Criteria Attributes + external (policy) information Examples: Hop count Policy considerations Preference for AS Presence or absence of certain AS Path origin Link dynamics

10/4/07 Lecture #11: Inter-Domain Routing27 LOCAL PREF Local (within an AS) mechanism to provide relative priority among BGP routers (e.g. R3 over R4) R1R2 R3R4 I-BGP AS 256 AS 300 Local Pref = 500Local Pref = 800 AS 100 R5 AS 200

10/4/07 Lecture #11: Inter-Domain Routing28 LOCAL PREF – Common Uses Peering vs. transit Prefer to use peering connection, why? In general, customer > peer > provider Use LOCAL PREF to ensure this

10/4/07 Lecture #11: Inter-Domain Routing29 AS_PATH List of traversed AS’s AS 500 AS 300 AS 200AS / / / /16

10/4/07 Lecture #11: Inter-Domain Routing30 Multi-Exit Discriminator (MED) Hint to external neighbors about the preferred path into an AS Non-transitive attribute Different AS choose different scales Used when two AS’s connect to each other in more than one place

10/4/07 Lecture #11: Inter-Domain Routing31 MED Hint to R1 to use R3 over R4 link Cannot compare AS40’s values to AS30’s R1R2 R3R4 AS 30 AS MED = MED = 200 AS MED = 50

10/4/07 Lecture #11: Inter-Domain Routing32 MED MED is typically used in provider/subscriber scenarios It can lead to unfairness if used between ISP because it may force one ISP to carry more traffic: SF NY ISP1 ignores MED from ISP2 ISP2 obeys MED from ISP1 ISP2 ends up carrying traffic most of the way ISP1 ISP2

10/4/07 Lecture #11: Inter-Domain Routing33 Decision Process Processing order of attributes: Select route with highest LOCAL-PREF Select route with shortest AS-PATH Apply MED (if routes learned from same neighbor)

10/4/07 Lecture #11: Inter-Domain Routing34 Important Concepts Wide area Internet structure and routing driven by economic considerations Customer, providers and peers BGP designed to: Provide hierarchy that allows scalability Allow enforcement of policies related to structure Mechanisms Path vector – scalable, hides structure from neighbors, detects loops quickly

10/4/07 Lecture #11: Inter-Domain Routing35 Next Lecture: IP Hodgepodge… IPv6 Addressing and more Tunneling How anything new gets added to the Internet NAT Making do with not enough IP addresses VPN How to make your own network

EXTRA SLIDES The rest of the slides are FYI

10/4/07 Lecture #11: Inter-Domain Routing37 History Mid-80s: EGP Reachability protocol (no shortest path) Did not accommodate cycles (tree topology) Evolved when all networks connected to NSF backbone Result: BGP introduced as routing protocol Latest version = BGP 4 BGP-4 supports CIDR Primary objective: connectivity not performance

10/4/07 Lecture #11: Inter-Domain Routing38 Link Failures Two types of link failures: Failure on an E-BGP link Failure on an I-BGP Link These failures are treated completely different in BGP Why?

10/4/07 Lecture #11: Inter-Domain Routing39 Failure on an E-BGP Link AS1 R1 AS2 R2 Physical link E-BGP session / /30 If the link R1-R2 goes down The TCP connection breaks BGP routes are removed This is the desired behavior

10/4/07 Lecture #11: Inter-Domain Routing40 Failure on an I-BGP Link R1 R2 R3 Physical link I-BGP connection / /30 If link R1-R2 goes down, R1 and R2 should still be able to exchange traffic The indirect path through R3 must be used Thus, E-BGP and I-BGP must use different conventions with respect to TCP endpoints

10/4/07 Lecture #11: Inter-Domain Routing41 BGP Common Header Length (2 bytes)Type (1 byte) Marker (security and message delineation) 16 bytes Types: OPEN, UPDATE, NOTIFICATION, KEEPALIVE

10/4/07 Lecture #11: Inter-Domain Routing42 CIDR and BGP AS X /24 AS Y /24 AS T (provider) /23 AS Z What should T announce to Z?

10/4/07 Lecture #11: Inter-Domain Routing43 Options Advertise all paths: Path 1: through T can reach /23 Path 2: through T can reach /24 Path 3: through T can reach /24 But this does not reduce routing tables! We would like to advertise: Path 1: through T can reach /22

10/4/07 Lecture #11: Inter-Domain Routing44 Sets and Sequences Problem: what do we list in the route? List T: omitting information not acceptable, may lead to loops List T, X, Y: misleading, appears as 3-hop path Solution: restructure AS Path attribute as: Path: (Sequence (T), Set (X, Y)) If Z wants to advertise path: Path: (Sequence (Z, T), Set (X, Y)) In practice used only if paths in set have same attributes

10/4/07 Lecture #11: Inter-Domain Routing45 Other Attributes ORIGIN Source of route (IGP, EGP, other) NEXT_HOP Address of next hop router to use Check out for full explanationhttp://

10/4/07 Lecture #11: Inter-Domain Routing46 Outline Routing hierarchy Internet structure External BGP (E-BGP) Internal BGP (I-BGP)

10/4/07 Lecture #11: Inter-Domain Routing47 Internal vs. External BGP R3R4 R1 R2 E-BGP BGP can be used by R3 and R4 to learn routes How do R1 and R2 learn routes? AS1 AS2

10/4/07 Lecture #11: Inter-Domain Routing48 Internal BGP (I-BGP) Same messages as E-BGP Different rules about re-advertising prefixes: Prefix learned from E-BGP can be advertised to I-BGP neighbor and vice-versa, but Prefix learned from one I-BGP neighbor cannot be advertised to another I-BGP neighbor Reason: no AS PATH within the same AS and thus danger of looping.

10/4/07 Lecture #11: Inter-Domain Routing49 Internal BGP (I-BGP) R3R4 R1 R2 E-BGP I-BGP R3 can tell R1 and R2 prefixes from R4 R3 can tell R4 prefixes from R1 and R2 R3 cannot tell R2 prefixes from R1 R2 can only find these prefixes through a direct connection to R1 Result: I-BGP routers must be fully connected (via TCP)! contrast with E-BGP sessions that map to physical links AS1 AS2