You are on page 1of 7

Routing Concepts

• IPv4
• Routing
Routing Basics
• Forwarding
• Some definitions
ISP/IXP Workshops
• Policy options
• Routing Protocols
IXP/IXP Workshops © 2000, Cisco Systems, Inc. 1 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 2

IPv4 IPv4 address format

• Internet uses IPv4 • Address and subnet mask


addresses are 32 bits long written as
range from 1.0.0.0 to 223.255.255.255 12.34.56.78 255.255.255.0 or
0.0.0.0 to 0.255.255.255 and 224.0.0.0 12.34.56.78/24
to 255.255.255.255 have “special”
uses mask represents the number of
network bits in the 32 bit address
• IPv4 address has a network portion
and a host portion the remaining bits are the host bits
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 3 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 4

What does a router do? A day in a life of a router

find path
forward packet, forward packet,
forward packet, forward packet...

? find alternate path


forward packet, forward packet,
forward packet, forward packet…
repeat until powered off
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 5 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 6

1
Routing versus Forwarding IP Routing - finding the path
• Path derived from information received
• Routing = building from a routing protocol
maps and giving
directions • Several alternative paths may exist
best next hop stored in forwarding table
• Forwarding =
• Decisions are updated periodically or as
moving packets
topology changes (event driven)
between interfaces
according to the • Decisions are based on:
“directions” topology, policies and metrics (hop count,
filtering, delay, bandwidth, etc.)
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 7 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 8

IP route lookup IP route lookup

• Based on destination IP packet


• Based on destination IP packet R3
All 10/8 except
Packet: Destination 10.1/16
• “longest match” routing IP address: 10.1.1.1

more specific prefix preferred over R4


R1 R2
less specific prefix
10/8 -> R3
10.1/16
example: packet with destination of 10.1/16 -> R4
20/8 -> R5
10.1.1.1/32 is sent to the router 30/8 -> R6
…..
announcing 10.1/16 rather than the
R2’s IP routing table
router announcing 10/8. www.cisco .com www.cisco .com
ISP/IXP Workshops © 2000, Cisco Systems, Inc. 9 ISP/IXP Workshops © 2000, Cisco Systems, Inc. 10

IP route lookup: Longest IP route lookup: Longest


match routing match routing
• Based on destination IP packet • Based on destination IP packet
R3 R3
All 10/8 except All 10/8 except
Packet: Destination 10.1/16 Packet: Destination 10.1/16
IP address: 10.1.1.1 IP address: 10.1.1.1

R1 R2 R4 R1 R2 R4

10/8 -> R3 10.1.1.1 && FF.0.0.0 10.1/16 10/8 -> R3 10.1/16


10.1.1.1 && FF.FF.0.0
10.1/16 -> R4 vs. Match! 10.1/16 -> R4 Match as well!
vs.
20/8 -> R5 10.0.0.0 && FF.0.0.0 20/8 -> R5
10.1.0.0 && FF.FF.0.0
30/8 -> R6 30/8 -> R6
….. …..
R2’s IP routing table R2’s IP routing table
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 11 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 12

2
IP route lookup: Longest IP route lookup: Longest
match routing match routing
• Based on destination IP packet • Based on destination IP packet
R3 R3
All 10/8 except All 10/8 except
Packet: Destination 10.1/16 Packet: Destination 10.1/16
IP address: 10.1.1.1 IP address: 10.1.1.1

R1 R2 R4 R1 R2 R4

10/8 -> R3 10.1/16 10/8 -> R3 10.1/16


10.1/16 -> R4 10.1/16 -> R4
20/8 -> R5 10.1.1.1 && FF.0.0.0 20/8 -> R5 10.1.1.1 && FF.0.0.0
vs. Does not match!
30/8 -> R6 30/8 -> R6 vs. Does not match!
….. 20.0.0.0 && FF.0.0.0 ….. 30.0.0.0 && FF.0.0.0
R2’s IP routing table R2’s IP routing table
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 13 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 14

IP route lookup: Longest


IP Forwarding
match routing
• Based on destination IP packet • Router makes decision on which interface
R3
a packet is sent to
All 10/8 except
Packet: Destination
IP address: 10.1.1.1
10.1/16 • Forwarding table populated by routing
process

R1 R2 R4 • Forwarding decisions:
destination address
10/8 -> R3 10.1/16
10.1/16 -> R4 Longest match, 16 bit netmask class of service (fair queuing, precedence, others)
20/8 -> R5
30/8 -> R6 local requirements (packet filtering)
…..
R2’s IP routing table • Can be aided by special hardware
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 15 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 16

Explicit versus Default


Egress Traffic
routing
• Default:
• How packets leave your network
simple, cheap (cycles, memory, bandwidth)
low granularity (metric games) • Egress traffic depends on:
• Explicit (default free zone) route availability (what others send you)
high overhead, complex, high cost, high granularity route acceptance (what you accept from
others)
• Hybrid
minimise overhead policy and tuning (what you do with routes
from others)
provide useful granularity
requires some filtering knowledge Peering and transit agreements
ISP/IXP Workshops www.cisco .com
© 2000, Cisco Systems, Inc. 17 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 18

3
Ingress Traffic Autonomous System (AS)

AS 100
• How packets get to your network and A
your customers’ networks
• Ingress traffic depends on:
what information you send and to whom • Collection of networks with same routing
policy
based on your addressing and AS’s
• Single routing protocol
based on others’ policy (what they accept
• Usually under single ownership, trust and
from you and what they do with it) administrative control
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 19 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 20

Definition of terms Routing flow and packet flow

packet flow
• Neighbours - AS’s which directly exchange routing accept announce
information AS 1 announce routing flow
accept AS 2
• Announce - send routing information to a neighbour packet flow

• Accept - receive and use routing information sent by


a neighbour For networks in AS1 and AS2 to communicate:
AS1 must announce to AS2
• Originate - insert routing information into external
announcements (usually as a result of the IGP) AS2 must accept from AS1
• Peers - routers in neighbouring AS’s or within one AS2 must announce to AS1
AS which exchange routing and policy information AS1 must accept from AS2
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 21 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 22

Routing flow and Traffic flow Routing policy limitations

red
red
• Traffic flow is always in the opposite Internet AS99
direction of the flow of routing green green
information
packet flow
filtering outgoing routing information AS99 uses red link for traffic going to the red AS
inhibits traffic flowing in and green link for traffic going to the green AS
To implement this policy for AS99:
filtering incoming routing information
• accept routes originating in the red AS on the red link
inhibits traffic flowing out
• accept all other routes on the green link
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 23 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 24

4
Routing policy with multiple
Routing policy limitations
AS’s
red AS 1
red AS 34
Internet
N1
AS22 AS99 AS16
green AS 8
green N16

packet flow For net N1 in AS1 to send traffic to net N16 in AS16:
• AS16 must originate and announce N16 to AS8.
For packets flowing toward AS 99:
• AS8 must accept N16 from AS16.
Unless AS 22 and all other intermediate AS’s co-
operate in pushing green traffic to the green link • AS8 must announce N16 to AS1 or AS34.
then some reasonable policies can not be • AS1 must accept N16 from AS8 or AS34.
implemented. For two-way packet flow, similar policies must exist for N1.
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 25 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 26

Routing policy with multiple


Granularity of routing policy
AS’s
• What to announce/accept
AS 1
AS 34
N1
• Preferences between multiple accepts
AS16
single route
AS 8
N16
routes originated by single AS

As multiple paths between sites routes originated by a group of AS’s


are implemented it is easy to see routes traversing specific path
how policies can become quite routes traversing specific AS
complex. routes belonging to other groupings (including
combinations)
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 27 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 28

Routing Policy Issues What Is an IGP?

• 75,000+ prefixes (not realistic to set


policy on all of them individually)
• Interior Gateway Protocol
• 7000+ origin AS’s (too many)
• Within an Autonomous System
• routes tied to a specific AS or path
may be unstable regardless of • Carries information about
connectivity internal infrastructure prefixes
• groups of AS’s are a natural • Examples - OSPF, ISIS, EIGRP…
abstraction for filtering purposes
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 29 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 30

5
Why Do We Need an IGP? What Is an EGP?

• ISP backbone scaling


• Exterior Gateway Protocol
Hierarchy
• Used to convey routing information
Modular infrastructure construction
between Autonomous Systems
Limiting scope of failure
• De-coupled from the IGP
Healing of infrastructure faults using
dynamic routing with fast • Current EGP is BGP
convergence
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 31 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 32

Why Do We Need an EGP? Interior versus Exterior


Routing Protocols
• Scaling to large network
• Interior • Exterior
Hierarchy
automatic neighbour specifically
Limit scope of failure discovery configured peers

• Policy generally trust your connecting with


IGP routers outside networks
Control reachability to prefixes prefixes go to all IGP set administrative
Merge separate organizations routers boundaries
binds routers in one binds AS’s together
Connect multiple IGPs AS together
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 33 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 34

Interior versus Exterior Hierarchy of Routing


Routing Protocols Protocols
Other ISPs
BGP4
• Interior • Exterior
Carries ISP Carries customer
infrastructure prefixes
BGP4
addresses only
Carries Internet and OSPF/ISIS
ISPs aim to keep prefixes
the IGP small for
EGPs are Static/BGP4
efficiency and BGP4
independent of ISP Local
scalability FDDI NAP Customers
network topology

ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 35 ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 36

6
Default Administrative
Distances
Route Source Default Distance

Connected Interface 0
Static Route 1
Enhanced IGRP Summary Route 5
External BGP 20
Internal Enhanced IGRP 90
IGRP 100
OSPF 110
IS-IS 115
RIP 120
EGP 140
External Enhanced IGRP 170
Internal BGP 200
Unknown 255
ISP/IXP Workshops © 2000, Cisco Systems, Inc. www.cisco .com 37 38

You might also like