Вы находитесь на странице: 1из 48

Module 8

Routing Table: A Closer Look

Objectives
Describe the various route types found in the routing
table structure
Describe the route lookup process
Describe the routing behavior in routed networks

The Routing Table Structure

Lab Topology

RIPv2

Static route

Routing Table Entries


R2 routing table

Notice that the 172.16.0.0/24 subnets have a combination of all three types of
routing sources:
Directly connected networks C
Static routes S
Dynamic routing protocols R

Routes Levels

The Cisco IP routing table is not a flat database


Cisco IP routing table is a hierarchical structure that is used to speed up lookup
process when locating routes and forwarding packets.
For simplicity, we will discuss all routes as one of two levels: level 1 or level 2.
6

Level 1 Routes

A level 1 route is a route with a subnet mask equal to or less than the classful
mask of the network address.
Level 1 Route Examples:
Default route: 0.0.0.0/0
Supernet Route: 192.168.0.0/22
Network Route: 192.168.1.0/24 (ie. Major network)
The source of the level 1 route can be a directly connected network, static route,
or a dynamic routing protocol

Level 1 Routes

An ultimate route is a route that includes:


Either a next-hop IP address (another path)
And/or an exit interface
8

Parent and Child Routes: Classful Network

Parent and Child Routes: Classful Network


Routing Table: Parent/Child Relationship

A level 1 parent route is a network route that does not contain a next-hop IP address
or exit interface for any network (not an ultimate route)
A level 2 route is a route that is a subnet of a classful network address.
10

Parent and Child Routes: Classful Network

Level 2 child routes are also considered ultimate


routes because they will contain the next-hop IP
address and/or exit interface.
11

Parent and Child Routes: Classful Network


R2 Routing Table: Parent/Child Relationship

Ultimate Route

12

Parent and Child Routes: Classless Network

Level 1 Parent Route

Level 2 Child Route

13

Parent and Child Routes: Classless Network

Routing Table Lookup Process

Steps in the Route Lookup Process

16

Steps in the Route Lookup Process

Because of
discontigous
network, neither R1
nor R2 has a route
to 172.16.4.0.
R3 does not have
routes to subnets
172.16.1.0/24,
172.16.2.0/24, or
172.16.3.0/24.

17

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Steps in the Route Lookup Process

Longest Match: Level 1 Network Routes

The best match or longest match is the route in the routing table that has
the most number of left-most matching bits with the destination IP address
of the packet.

29

Longest Match: Level 1 Network Routes

Step 1: Examines level 1 routes, including network


routes and supernet routes, for the best match with
the destination address (192.168.1.2) of the IP packet

30

Longest Match: Level 1 Network Routes


172.16.0.0/16 Level 1 Parent Route

31

Longest Match: Level 1 Network Routes

32

Longest Match: Level 1 Parent & Level 2


Child Routes

Before any level 2 child routes are examined for a match, there must first be a match between
the classful address of the level 1 parent route and the destination IP address of the packet.

33

Longest Match: Level 1 Parent & Level 2


Child Routes
Step 1b: The best
match is a level 1
parent route,
proceed to Step 2

Step 2: The router examines child routes (the subnet routes)


of the parent route for a best match
Step 2a: There is a match with a level 2 child route,
that subnet will be used to forward the packet.
34

Longest Match: Level 1 Parent & Level 2


Child Routes
First 16 bits match
parent route

First 24 bits do not


match -> skip

35

Routing Behavior

Classful & Classless Routing Behavior


Routing Protocols vs Routing Behaviors

Classful and classless routing behaviors are independent from classful and classless
routing protocols.
In today's networks, it is recommended to use classless routing behavior so that
supernet and default routes can be used whenever needed.

37

Classful & Classless Routing Behavior

38

Classful Routing Behavior: no ip classless

Classful:
Drop packet

Step 3: Is the router


implementing classful or
classless routing behavior?

Step 3a: If classful routing


behavior is in effect, terminate the
lookup process and drop the packet.

39

Classful Routing Behavior: no ip classless

Prior to IOS 11.3, no ip classless was the default behavior for Cisco routers.

40

Classful Routing Behavior: Search Process

R2 now check the child route

First 24 bits do not


match -> skip
41

Classful Routing Behavior Search Process

42

Classless Routing Behavior: ip classless

All routers are configured with the ip classless command.


R1(config)#ip classless
R2(config)#ip classless
R3(config)#ip classless
Classless routing behavior works well for discontiguous networks and CIDR supernets

43

Steps in the Route Lookup Process


Step 3: Classful or classless routing behavior?

Step 3a: If classful routing


behavior is in effect,
terminate the lookup process
and drop the packet.

Step 3b: If classless routing


behavior is in effect, continue
searching level 1 supernet routes in
the routing table for a match,
including the default route, if
there is one.

44

Steps in the Route Lookup Process


Step 4: If there is now a lesser match with a level 1
supernet or default routes, the router uses that route
to forward the packet.

Step 5: If there is not a match with any


route in the routing table, the router
drops the packet.
45

Classless Routing Behavior: Search Process

R2 now check the child route

First 24 bits do not


match -> skip
46

Classless Routing Behavior Search


Process

47

Good luck with this module!

Вам также может понравиться