Presentation is loading. Please wait.

Presentation is loading. Please wait.

Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 1 Border Gateway Protocol Tahir Azim.

Similar presentations


Presentation on theme: "Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 1 Border Gateway Protocol Tahir Azim."— Presentation transcript:

1 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 1 Border Gateway Protocol Tahir Azim

2 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 2 Outline Techniques  Flooding  Distributed Bellman Ford Algorithm  Dijkstra’s Shortest Path First Algorithm Routing in the Internet  Hierarchy and Autonomous Systems  Interior Routing Protocols: RIP, OSPF  Exterior Routing Protocol: BGP Multicast Routing

3 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 3 Routing in the Internet The Internet uses hierarchical routing  The Internet is split into Autonomous Systems (AS’s)  Examples of AS’s: PTCL (17557), HP (71), MCI Worldcom (17373), Sprint (1239)  Try: whois –h whois.arin.net “MCI Worldcom”  Within an AS, the administrator chooses an Interior Gateway Protocol (IGP)  Examples of IGPs: RIP (rfc 1058), OSPF (rfc 1247).  Between AS’s, the Internet uses an Exterior Gateway Protocol  AS’s today use the Border Gateway Protocol, BGP-4 (rfc 1771)

4 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 4 Routing in the Internet Stub AS Transit AS e.g. backbone service provider Stub AS AS ‘A’ AS ‘B’ AS ‘C’ Interior Gateway Protocol Interior Gateway Protocol Interior Gateway Protocol BGP

5 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 5 Routing within a Stub AS  There is only one exit point, so routers within the AS can use default routing.  Each router knows all Network IDs within AS.  Packets destined to another AS are sent to the default router.  Default router is the border gateway to the next AS.  Routing tables in Stub AS’s tend to be small.

6 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 6 Interior Routing Protocols  RIP  Uses distance vector (distributed Bellman-Ford algorithm).  Updates sent every 30 seconds.  No authentication.  Originally in BSD UNIX.  Widely used for many years; not used much anymore.  OSPF  Link-state updates sent (using flooding) as and when required.  Every router runs Dijkstra’s algorithm.  Authenticated updates.  Autonomous system may be partitioned into “areas” corresponding to internal networks.  Widely used.

7 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 7 Exterior Routing Protocols Problems:  Topology: The Internet is a complex mesh of different AS’s with very little structure.  Autonomy of AS’s: Each AS defines link costs in different ways, so not possible to find lowest cost paths.  Trust: Some AS’s can’t trust others to advertise good routes (e.g. two competing backbone providers), or to protect the privacy of their traffic (e.g. two warring nations).  Policies: Different AS’s have different objectives (e.g. route over fewest hops; use one provider rather than another).

8 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 8 Border Gateway Protocol (BGP-4)  BGP is not a link-state or distance-vector routing protocol.  Instead, BGP uses “Path vector”  BGP advertises complete paths (a list of AS’s).  Also called AS_PATH (this is the path vector)  Example of path advertisement: “The network /16 can be reached via the path {AS1, AS5, AS13}”.  Paths with loops are detected locally and ignored.  Local policies pick the preferred path among options.  When a link/router fails, the path is “withdrawn”.

9 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 9 Customers and Providers Customer pays provider for access to the Internet Customer may not always need BGP provider customer IP traffic provider customer

10 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 10 Customer-Provider Hierarchy IP traffic provider customer

11 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 11 The Peering Relationship peer customerprovider Peers provide transit between their respective customers Peers generally do not provide transit between peers A->C routing must occur through a provider Peers (often) do not exchange $$$ traffic allowed traffic NOT allowed A B C

12 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 12

13 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 13

14 14  Open : Establish a BGP session.  Keep Alive : Handshake at regular intervals.  Notification : Shuts down a peering session.  Update : Announcing new routes or withdrawing previously announced routes.  Attributes include: Next hop, AS Path, local preference, Multi-exit discriminator (MED), …  Used to select among multiple options for paths  BGP messages exchanged using TCP BGP announcement = network prefix + path attributes BGP Messages

15 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 15 BGP Route Selection Summary Highest Local Preference Shortest ASPATH Lowest MED Lowest IGP cost to BGP egress Lowest router ID traffic engineering Enforce relationships E.g. prefer customer routes over peer routes Throw up hands and break ties

16 16 ASPATH Attribute AS /16 AS Path = 6341 AS 1239 Sprint AS 1755 Ebone AT&T AS 3549 Global Crossing /16 AS Path = /16 AS Path = AS /16 AT&T Research Prefix Originated AS RIPE NCC RIS project AS 1129 Global Access /16 AS Path = /16 AS Path = /16 AS Path = /16 AS Path = Pick shorter AS path

17 17 Which route should Frank pick to /16? AS 1 AS 2 AS 4 AS /16 Frank’s Internet Barn peer customerprovider So Many Choices…

18 18 AS 1 AS 2 AS 4 AS /16 local pref = 80 local pref = 100 local pref = 90 Set appropriate “local pref” to reflect preferences: Higher Local preference values are preferred Frank’s Choices… peer customerprovider Route learned from customer preferred over route learned from peer, preferred over route learned from provider

19 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 19 Prompt> whois -h whois.apnic.net AS17577  as-block: AS AS18409  descr: APNIC ASN block  remarks: These AS numbers are further assigned by APNIC  remarks: to APNIC members and end-users in the APNIC region  admin-c: HM20-AP  tech-c: HM20-AP  mnt-by: APNIC-HM  mnt-lower: APNIC-HM  changed:  changed:  source: APNIC  aut-num: AS17557  as-name: PKTELECOM-AS-AP  descr: Pakistan Telecom  descr: ITI Region PTCL  country: PK  import: from AS5400  action pref=185;  accept ANY  import: from AS1239  action pref=185;  accept ANY  export: to AS5400  announce AS-SETPTCL  export: to AS1239  announce AS-SETPTCL  admin-c: MH49-AP  tech-c: AB242-AP  mnt-by: MAINT-PK-ARSHAD  mnt-routes: MAINT-PK-ARSHAD  changed:  source: APNIC  person: Mansoor ul Hassan  nic-hdl: MH49-AP   address: 2nd Floor, International Gateway Exchange Building,  address: PTCL Complex, 7th Road, Satellite Town Rawalpindi  address: Pakistan  phone:  fax-no:  country: PK  changed:  mnt-by: MAINT-PK-ARSHAD  source: APNIC  person: Arshad Butt  nic-hdl: AB242-AP   address: ITI Hall,Telcom Complex  address: S/Town Exchange,7th road  address: Rawalpindi.  phone:  fax-no:  country: PK  mnt-by: MAINT-PK-ARSHAD  changed:  source: APNIC

20 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 20 Who owns an address block? prompt> whois OrgName: Savvis OrgID: SAVVI-2 Address: 3300 Regency Parkway City: Cary StateProv: NC PostalCode: Country: US ReferralServer: rwhois://rwhois.exodus.net:4 321/ NetRange: CIDR: /14 NetName: SAVVIS NetHandle: NET Parent: NET NetType: Direct Allocation NameServer: DNS01.SAVVIS.NET NameServer: DNS02.SAVVIS.NET NameServer: DNS03.SAVVIS.NET NameServer: DNS04.SAVVIS.NET Comment: RegDate: Updated: # ARIN WHOIS database, last updated :10 # Enter ? for additional hints on searching ARIN's WHOIS database.

21 Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 21


Download ppt "Courtesy: Nick McKeown, Stanford Umar Kalim, NIIT 1 Border Gateway Protocol Tahir Azim."

Similar presentations


Ads by Google