Routing Basics: ISP/IXP Workshops
Routing Basics: ISP/IXP Workshops
ISP/IXP Workshops
Cisco Confidential
Routing Concepts
IPv4 Routing Forwarding Some definitions Policy options Routing Protocols
IPv4
Internet uses IPv4
addresses are 32 bits long range from 1.0.0.0 to 223.255.255.255 0.0.0.0 to 0.255.255.255 and 224.0.0.0 to 255.255.255.255 have special uses
Routing = building maps and giving directions Forwarding = moving packets between interfaces according to the directions
Path derived from information received from a routing protocol Several alternative paths may exist
best next hop stored in forwarding table
Decisions are updated periodically or as topology changes (event driven) Decisions are based on:
topology, policies and metrics (hop count, filtering, delay, bandwidth, etc.)
IP route lookup
Based on destination IP address longest match routing
more specific prefix preferred over less specific prefix example: packet with destination of 10.1.1.1/32 is sent to the router announcing 10.1/16 rather than the router announcing 10/8.
IP route lookup
Based on destination IP address
R3 Packet: Destination IP address: 10.1.1.1 All 10/8 except 10.1/16
R1
R4 10.1/16
10
R2
R4 10.1/16
R2
R4
10.1/16 10.1.1.1 && FF.FF.0.0 Match as well! vs. 10.1.0.0 && FF.FF.0.0
R2
R4 10.1/16
10.1.1.1 && FF.0.0.0 Does not match! vs. 20.0.0.0 && FF.0.0.0
R2
R4 10.1/16
10.1.1.1 && FF.0.0.0 vs. Does not match! 30.0.0.0 && FF.0.0.0
R2
R4 10.1/16
IP Forwarding
Router makes decision on which interface a packet is sent to Forwarding table populated by routing process Forwarding decisions:
destination address class of service (fair queuing, precedence, others) local requirements (packet filtering)
16
Static Routes
17
18
Hybrid
minimise overhead provide useful granularity requires some filtering knowledge
19
Egress Traffic
How packets leave your network Egress traffic depends on:
route availability (what others send you) route acceptance (what you accept from others) policy and tuning (what you do with routes from others) Peering and transit agreements
20
Ingress Traffic
How packets get to your network and your customers networks Ingress traffic depends on:
what information you send and to whom based on your addressing and ASs based on others policy (what they accept from you and what they do with it)
21
Collection of networks with same routing policy Single routing protocol Usually under single ownership, trust and administrative control
Cisco ISP Workshops 2006 Cisco Systems, Inc. All rights reserved. 22
Definition of terms
Neighbours
ASs which directly exchange routing information Routers which exchange routing information
Announce
send routing information to a neighbour
Accept
receive and use routing information sent by a neighbour
Originate
insert routing information into external announcements (usually as a result of the IGP)
Peers
routers in neighbouring ASs or within one AS which exchange routing and policy information
23
AS 1
accept announce
announce accept
AS 2
24
25
AS 1 N1
AS 34 AS16 AS 8 N16
For two-way packet flow, similar policies must exist for N1.
Cisco ISP Workshops 2006 Cisco Systems, Inc. All rights reserved. 26
AS 1 N1
AS 34 AS16 AS 8 N16
As multiple paths between sites are implemented it is easy to see how policies can become quite complex.
27
Routing Policy
Used to control traffic flow in and out of an ISP network ISP makes decisions on what routing information to accept and discard from its neighbours
Individual routes Routes originated by specific ASes Routes traversing specific ASes Routes belonging to other groupings
Groupings which you define as you see fit
28
red
Internet
green green packet flow
AS99
AS99 uses red link for traffic to the red AS and the green link for remaining traffic To implement this policy, AS99 has to:
Accept routes originating from the red AS on the red link Accept all other routes on the green link
29
red
Internet
AS22
red
AS99
green
AS99 would like packets coming from the green AS to use the green link. But unless AS22 cooperates in pushing traffic from the green AS down the green link, there is very little that AS99 can do to achieve this aim
Cisco ISP Workshops 2006 Cisco Systems, Inc. All rights reserved. 30
191000 prefixes (not realistic to set policy on all of them individually) 22500 origin ASs (too many) routes tied to a specific AS or path may be unstable regardless of connectivity groups of ASs are a natural abstraction for filtering purposes
31
Routing Protocols
We now know what routing means but what do the routers get up to? And why are we doing this anyway?
Cisco Confidential
32
Internet is made up of the ISPs who connect to each others networks How does an ISP in Kenya tell an ISP in Japan what customers they have? And how does that ISP send data packets to the customers of the ISP in Japan, and get responses back
After all, as on a local ethernet, two way packet flow is needed for communication between two devices
33
Instead, ISP in Kenya tells his neighbouring ISPs what customers he has
And the neighbouring ISPs pass this information on to their neighbours, and so on This process repeats until the information reaches the ISP in Japan
34
35
ISP in Kenya doesnt actually tell his neighbouring ISPs the names of the customers
(network equipment does not understand names)
Instead, he has received an IP address block as a member of the Regional Internet Registry serving Kenya
His customers have received address space from this address block as part of their Internet service And he announces this address block to his neighbouring ISPs this is called announcing a route
36
Routing Protocols
Routers use routing protocols to exchange routing information with each other
IGP is used to refer to the process running on routers inside an ISPs network EGP is used to refer to the process running between routers bordering directly connected ISP networks
37
What Is an IGP?
Interior Gateway Protocol Within an Autonomous System Carries information about internal infrastructure prefixes Examples OSPF, ISIS, EIGRP
38
39
What Is an EGP?
Exterior Gateway Protocol Used to convey routing information between Autonomous Systems De-coupled from the IGP Current EGP is BGP
40
41
Interior
automatic neighbour discovery generally trust your IGP routers prefixes go to all IGP routers binds routers in one AS together
Exterior
specifically configured peers connecting with outside networks set administrative boundaries binds ASs together
42
Exterior
Carries customer prefixes Carries Internet prefixes EGPs are independent of ISP network topology
43
BGP4 IXP
Cisco ISP Workshops 2006 Cisco Systems, Inc. All rights reserved.
Static/BGP4 Customers
44
Connected Interface Static Route Enhanced IGRP Summary Route External BGP Internal Enhanced IGRP IGRP OSPF IS-IS RIP EGP External Enhanced IGRP Internal BGP Unknown
Cisco ISP Workshops 2006 Cisco Systems, Inc. All rights reserved.
Routing Basics
ISP/IXP Workshops
Cisco Confidential
46