Vous êtes sur la page 1sur 336

Introduction to Routing

and Packet Forwarding

Routing Protocols and


Concepts – Chapter 1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Identify a router as a computer with an OS and
hardware designed for the routing process.
ƒ Demonstrate the ability to configure devices and
apply addresses.
ƒ Describe the structure of a routing table.
ƒ Describe how a router determines a path and
switches packets

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Router as a Computer
ƒ Describe the basic purpose of a router
-Computers that specialize in sending packets over the data
network. They are responsible for interconnecting networks by
selecting the best path for a packet to travel and forwarding
packets to their destination

ƒ Routers are the network center


-Routers generally have 2 connections:
-WAN connection (Connection to ISP)
-LAN connection

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Router as a Computer
ƒ Data is sent in form of packets between 2 end devices
ƒ Routers are used to direct packet to its destination
(routing table)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Router as a Computer
ƒ Routers examine a packet’s destination IP address and
determine the best path by enlisting the aid of a routing
table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Router as a Computer
ƒ Router components and their functions:
ƒCPU - Executes operating system instructions
ƒRandom access memory (RAM) - Contains the running copy of
configuration file. Stores routing table. RAM contents lost when power
is off
ƒRead-only memory (ROM) - Holds diagnostic software used when
router is powered up. Stores the router’s bootstrap program.
ƒNon-volatile RAM (NVRAM) - Stores startup configuration. This may
include IP addresses (Routing protocol, Hostname of router)
ƒFlash memory - Contains the operating system (Cisco IOS)
ƒInterfaces - There exist multiple physical interfaces that are used to
connect network. Examples of interface types:
-Ethernet / fast Ethernet interfaces
-Serial interfaces
-Management interfaces

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Router as a Computer
ƒ Router components

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Router as a Computer
ƒ Major phases to the
router boot-up process
ƒTest router hardware
Power-On Self Test
(POST)
Execute bootstrap loader
ƒLocate & load Cisco IOS
software
-Locate IOS
-Load IOS
ƒLocate & load startup
configuration file or enter
setup mode
-Bootstrap program looks
for configuration file
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Router as a Computer
ƒ Verify the router boot-up process:
-The show version command is used to view information about
the router during the bootup process. Information includes:
ƒPlatform model number
ƒImage name & IOS version
ƒBootstrap version stored in ROM
ƒImage file name & where it was loaded from
ƒNumber & type of interfaces
ƒAmount of NVRAM
ƒAmount of flash
ƒConfiguration register

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Router as a Computer

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Router as a Computer
ƒ Router Interface is a physical connector that enables a
router to send or receive packets
ƒ Each interface connects to a separate network
ƒ Consist of socket or jack found on the outside of a router
ƒ Types of router interfaces:
-Ethernet
-Fastethernet
-Serial
-DSL
-ISDN
-Cable

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Router as a Computer
ƒ Two major groups of Router Interfaces
LAN Interfaces:
ƒAre used to connect router to LAN
network
ƒHas a layer 2 MAC address
ƒCan be assigned a Layer 3 IP
address
ƒUsually consist of an RJ-45 jack
ƒ WAN Interfaces
ƒAre used to connect routers to external networks that
interconnect LANs.
ƒDepending on the WAN technology, a layer 2 address
may be used.
ƒUses a layer 3 IP address
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Router as a Computer
ƒ Routers and the Network Layer
Routers use destination IP address to forward packets
ƒThe path a packet takes is determined after a router
consults information in the routing table.
ƒAfter router determines the best path
ƒPacket is encapsulated into a frame
ƒFrame is then placed on network medium in form of Bits

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Router as a Computer
ƒ Routers Operate at Layers 1, 2 & 3
ƒRouter receives a stream of encoded bits
ƒBits are decoded and passed to layer 2
ƒRouter de-encapsulates the frame
ƒRemaining packet passed up to layer 3
-Routing decision made at this layer by examining
destination IP address
ƒPacket is then re-encapsulated & sent out outbound interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Configure Devices and Apply Addresses
ƒ Implementing Basic Addressing Schemes
ƒ When designing a new network or mapping an existing
network you must provide the following information in
the form of a document:
-Topology drawing that Illustrates physical connectivity
–Address table that provides the following information:
ƒDevice name
ƒInterfaces used
ƒIP addresses
ƒDefault gateway
ƒ Ex. 1.2.1.1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Configure Devices and Apply Addresses
ƒ Basic Router Configuration
ƒ A basic router configuration should contain the following:
-Router name - Host name should be unique
-Banner - At a minimum, banner should warn against
unauthorized use
-Passwords - Use strong passwords
-Interface configurations - Specify interface type, IP address
and subnet mask. Describe purpose of interface. Issue no
shutdown command. If DCE serial interface issue clock rate
command.
ƒ After entering in the basic configuration the following tasks should
be completed
-Verify basic configuration and router operations.
-Save the changes on a router

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Configure Devices and Apply Addresses

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Configure Devices and Apply Addresses
ƒ Verify Basic Router Configuration
-Issue the show running-config command
-Save the basic router configuration by Issuing the copy
running-config startup-config command
-Additional commands that will enable you to further verify
router configuration are:
ƒShow running-config - Displays configuration currently in
RAM
ƒShow startup-config - Displays configuration file NVRAM
ƒShow IP route - Displays routing table
ƒShow interfaces - Displays all interface configurations
ƒShow IP int brief - Displays abbreviated interface
configuration information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Routing Table Structure
ƒ Routing Table is stored in ram and contains information
about:
ƒDirectly connected networks - this occurs when a device is
connected to another router interface
ƒRemotely connected networks - this is a network that is not
directly connected to a particular router
ƒDetailed information about the networks include source of
information, network address & subnet mask, and Ip address of
next-hop router

ƒ Show ip route command is used to view a routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Routing Table Structure
ƒ Adding a connected network to the routing table
-Router interfaces
ƒEach router interface is a member of a different network
ƒActivated using the no shutdown command
ƒIn order for static and dynamic routes to exist in routing
table you must have directly connected networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Routing Table Structure
ƒ Static routes in the routing table
-Includes: network address and subnet mask and IP address of
next hop router or exit interface
-Denoted with the code S in the routing table
-Routing tables must contain directly connected networks used
to connect remote networks before static or dynamic routing
can be used

ƒ When to use static routes


-When network only consists of a few routers
-Network is connected to internet only through one ISP
-Hub & spoke topology is used on a large network

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Routing Table Structure
ƒ Connected and Static routes

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Routing Table Structure
ƒ Dynamic routing protocols
-Used to add remote networks to a routing table
-Are used to discover networks
-Are used to update and maintain routing tables

ƒ Automatic network discovery


-Routers are able discover new networks by sharing routing
table information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Routing Table Structure
ƒ Maintaining routing tables
-Dynamic routing protocols are used to share routing information with
other router & to maintain and up date their own routing table.
ƒ IP routing protocols. Example of routing protocols include:
-RIP
-IGRP
-EIGRP
-OSPF
-IS-IS
-BGP

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Routing Table Structure
ƒ Routing Table Principles
-3 principles regarding routing tables:
ƒEvery router makes its decisions alone, based on the
information it has in its routing table.
ƒDifferent routing table may contain different information
ƒ A routing table can tell how to get to a destination but not
how to get back

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Routing Table Structure
ƒ Effects of the 3 Routing Table Principles
-Packets are forwarded through the network from one router
to another, on a hop by hop basis.
-Packets can take path “X” to a destination but return via
path “Y” (Asymmetric routing).

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Router Paths and Packet Switching
ƒ Internet Protocol (IP) packet format contains fields that
provide information about the packet and the sending
and receiving hosts
ƒ Fields that are important for CCNA students:
-Destination IP address
-Source IP address
-Version & TTL
-IP header length
-Precedence & type of service
-Packet length

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Router Paths and Packet Switching
ƒ MAC Layer Frame Format
ƒ MAC Frames are also divided into fields. They include:
-Preamble
-Start of frame delimiter
-Destination MAC address
-Source MAC address
-Type/length
-Data and pad
-Frame check sequence

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
Router Paths and Packet Switching
ƒ A Metric is a numerical value used by routing protocols help
determine the best path to a destination
–The smaller the metric value the better the path
ƒ 2 types of metrics used by routing protocols are:
-Hop count - this is the number of routers a packet must travel
through to get to its destination
-Bandwidth - this is the “speed” of a link also known as the data
capacity of a link

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
Router Paths and Packet Switching
ƒ Equal cost metric is a condition where a router has multiple paths
to the same destination that all have the same metric
ƒ To solve this dilemma, a router will use Equal Cost Load
Balancing. This means the router sends packets over the multiple
exit interfaces listed in the routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 30
Router Paths and Packet Switching
ƒ Path determination is a process used by a router to pick the best
path to a destination
ƒ One of 3 path determinations results from searching for the best
path
Directly connected network
Remote network
No route determined
->ICMP unreachable

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 31
Router Paths and Packet Switching
ƒ Switching Function of Router is the process used by a
router to switch a packet from an incoming interface to
an outgoing interface on the same router.
-A packet received by a router will do the following:
ƒStrips off layer 2 headers.
ƒExamines destination IP address located in Layer 3
header to find best route to destination.
ƒRe-encapsulates layer 3 packet into layer 2 frame.
ƒForwards frame out exit interface.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 32
Router Paths and Packet Switching
ƒ As a packet travels from one networking device to another
-The Source and Destination IP addresses NEVER change
-The Source & Destination MAC addresses CHANGE as packet
is forwarded from one router to the next.
-TTL field decrement by one until a value of zero is reached at
which point router discards packet (prevents packets from
endlessly traversing the network)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 33
Router Paths and Packet Switching
ƒ Path determination and switching function details. PC1
Wants to send something to PC 2 here is part of what
happens
Step 1 - PC1 encapsulates packet into a frame. Frame
contains R1’s destination MAC address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 34
Router Paths and Packet Switching
Step 2 - R1 receives Ethernet frame.
ƒR1 sees that destination MAC address matches its own
MAC.
ƒR1 then strips off Ethernet frame.
ƒR1 Examines destination IP.
ƒR1 consults routing table looking for destination IP.
ƒAfter finding destination IP in routing table, R1 now looks up
next hop IP address.
ƒR1 re-encapsulates IP packet with a new Ethernet frame.
ƒR1 forwards Ethernet packet out Fa0/1 interface.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 35
Router Paths and Packet Switching

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 36
Router Paths and Packet Switching
ƒ Path determination and switching function details. PC1 Wants to
send something to PC 2 here is part of what happens
Step 3 - Packet arrives at R2
ƒR2 receives Ethernet frame
ƒR2 sees that destination MAC address matches its own
MAC
ƒR2 then strips off Ethernet frame
ƒR2 Examines destination IP
ƒR2 consults routing table looking for destination IP
ƒAfter finding destination IP in routing table, R2 now looks up
next hop IP address
ƒR2 re-encapsulates IP packet with a new data link frame
ƒR2 forwards Ethernet packet out S0/0 interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 37
Router Paths and Packet Switching
ƒ Path determination and switching function details. PC1 Wants to
send something to PC 2 here is part of what happens
Step 4 - Packet arrives at R3
ƒR3 receives PPP frame
ƒR3 then strips off PPP frame
ƒR3 Examines destination IP
ƒR3 consults routing table looking for destination IP
ƒAfter finding destination IP in routing table, R3 is directly
connected to destination via its fast Ethernet interface
ƒR3 re-encapsulates IP packet with a new Ethernet frame
ƒR3 forwards Ethernet packet out Fa0/0 interface
Step 5 - IP packet arrives at PC2. Frame is decapsulated &
processed by upper layer protocols.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 38
Summary
ƒ Routers are computers that specialize in sending data over a network.
ƒ Routers are composed of:
-Hardware i.e. CPU, Memory, System bus, Interfaces
-Software used to direct the routing process
ƒIOS
ƒConfiguration file
ƒ Routers need to be configured. Basic configuration consists of:
-Router name
-Router banner
-Password(s)
-Interface configurations i.e. IP address and subnet mask
ƒ Routing tables contain the following information
-Directly connected networks
-Remotely connected networks
-Network addresses and subnet masks
ITE PC v4.0
Chapter 1
-IP address of next hop address
© 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 39
Summary
ƒ Routers determine a packets path to its destination by
doing the following
ƒReceiving an encapsulated frame & examining destination
MAC address.
ƒIf the MAC address matches then Frame is de-encapsulated
so that router can examine the destination IP address.
ƒIf destination IP address is in routing table or there is a static
route then Router determines next hop IP address. Router will
re-encapsulate packet with appropriate layer 2 frame and send
it out to next destination.
ƒProcess continues until packet reaches destination.
ƒNote - only the MAC addresses will change the source and
destination IP addresses do not change.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 40
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 41
Static Routing

Routing Protocols and


Concepts – Chapter 2

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Define the general role a router plays in networks.
ƒ Describe the directly connected networks, different
router interfaces
ƒ Examine directly connected networks in the routing
table and use the CDP protocol
ƒ Describe static routes with exit interfaces
ƒ Describe summary and default route
ƒ Examine how packets get forwarded when using
static routes
ƒ Identify how to manage and troubleshoot static routes

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
General Role of the Router
ƒ Functions of a Router
-Best Path Selections
-Forwarding packets to destination

ƒ Introducing the Topology


-3 x 1800 series routers connected via WAN links
-Each router connected to a LAN represented by a switch and a
PC

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
General Role of the Router
ƒ Connections of a Router for WAN
-A router has a DB-60 port that can support 5 different cabling
standards

ƒ Connections of a Router for Ethernet


-2 types of connectors can be used: Straight through and Cross-
over
ƒStraight through used to connect:
-Switch-to-Router, Switch-to-PC, Router-to-Server, Hub-to-
PC, Hub-to-Server
ƒCross-over used to connect:
-Switch-to-Switch, PC-to-PC, Switch-to-Hub, Hub-to-Hub,
Router-to-Router

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Interfaces
ƒ Examining Router Interfaces
-Show IP router command – used to view routing table
-Show Interfaces command – used to show status of an
interface
-Show IP Interface brief command – used to show a portion of
the interface information
-Show running-config command – used to show configuration
file in RAM

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Interfaces
ƒ Configuring an Ethernet interface
-By default all serial and Ethernet interfaces are down
-To enable an interface use the No Shutdown command

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Interfaces
ƒ Verifying Ethernet interface
-Show interfaces for fastEthernet 0/0 – command used to show
status of fast Ethernet
port
-Show ip interface brief
-Show running-config
ƒ Ethernet interfaces participate in ARP

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Interfaces
ƒ Configuring a Serial interface
-Enter interface configuration mode
-Enter in the ip address and subnet mask
-Enter in the no shutdown command
ƒ Example:
-R1(config)#interface serial 0/0
-R1(config-if)#ip address 172.16.2.1 255.255.255.0
-R1(config-if)#no shutdown

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Interfaces
ƒ Examining Router Interfaces
-Physically connecting a WAN Interface.
-A WAN Physical Layer connection has sides:
ƒData Circuit-terminating Equipment (DCE) – This is the
service provider. CSU/DSU is a DCE device.
ƒData Terminal Equipment (DTE) – Typically the router is the
DTE device.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Interfaces
ƒ Configuring serial links in a lab environment
ƒOne side of a serial connection must be considered a DCE
ƒThis requires placing a clocking signal – use the clock rate
command.
ƒExample:
-R1(config)#interface serial 0/0
-R1(config-if)#clockrate 64000

ƒSerial Interfaces require a clock signal to control the timing of


the communcations.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Routing Table and CDP Protocol
ƒ Purpose of the debug ip routing command
ƒAllows you to view changes that the router performs when
adding or removing routes
ƒExample:
-R2#debug ip routing
-IP routing debugging is on

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Routing Table and CDP Protocol
ƒ To configure an Ethernet interface
ƒExample:
-R2(config)#interface fastethernet 0/0
-R2(config-if)#ip address 172.16.1.1 255.255.255.0
-R2(config-if)#no shutdown

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Routing Table and CDP Protocol
ƒ When a router only has its interfaces configured & no
other routing protocols are configured then:
-The routing table contains only the directly connected networks
-Only devices on the directly connected networks are reachable

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Routing Table and CDP Protocol

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Routing Table and CDP Protocol
ƒ Checking each
route in turn
The ping
command is
used to check
end to end
connectivity

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Routing Table and CDP Protocol
ƒ Purpose of CDP
A layer 2 cisco proprietary tool used to gather information about
other directly connected Cisco devices.

ƒ Concept of neighbors
-2 types of neighbors
ƒLayer 3 neighbors
ƒLayer 2 neighbors

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Routing Table and CDP Protocol
ƒ CDP show commands
ƒShow cdp neighbors command
-Displays the following information:
ƒNeighbor device ID
ƒLocal interface
ƒHoldtime value, in seconds
ƒNeighbor device capability code
ƒNeighbor hardware platform
ƒNeighbor remote port ID
ƒShow cdp neighbors detail command
-Useful in determining if an IP address configuration error

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Routing Table and CDP Protocol

ƒ Disabling CDP
To disable CDP globally use
the following command
Router(config)#no cdp run

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Static Routes with Exit Interfaces
ƒ Purpose of a static route
A manually configured route used when routing from a network
to a stub network (a network accessed by a single route)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Static Routes with Exit Interfaces
ƒ IP route command
ƒTo configure a static route use the following command: ip route
ƒExample:
-Router(config)# ip route network-address subnet-mask {ip-
address | exit-interface }

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Static Routes with Exit Interfaces
ƒ Dissecting static route syntax
ƒip route - Static route command
ƒ172.16.1.0 – Destination network address
ƒ255.255.255.0 - Subnet mask of destination network
ƒ172.16.2.2 - Serial 0/0/0 interface IP address on R2, which is
the "next-hop" to this network

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Static Routes with Exit Interfaces
ƒ Configuring routes to 2 or more remote networks
Use the following commands for R1
-R1(config)#ip route 192.168.1.0 255.255.255.0 172.16.2.2
-R1(config)#ip route 192.168.2.0 255.255.255.0 172.16.2.2

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Static Routes with Exit Interfaces
ƒ Zinin’s 3 routing principles
ƒPrinciple 1: "Every router makes its decision alone, based on
the information it has in its own routing table.“
ƒPrinciple 2: "The fact that one router has certain information in
its routing table does not mean that other routers have the same
information.“
ƒPrinciple 3: "Routing information about a path from one
network to another does not provide routing information about
the reverse, or return path."

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Static Routes with Exit Interfaces
ƒ Using Zinin’s 3 routing principles, how would you
answer the following?
-Would packets from PC1 reach their destination?
Yes, packets destined for 172.16.1.0/24 and 192.168.1.0/24
networks would reach their destination.
-Does this mean that any packets from these networks destined
for 172.16.3.0/24 network will reach their destination?
No, because neither R2 nor R3 router has a route to the
172.16.3.0/24 network.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Static Routes with Exit Interfaces
ƒ Resolving to an Exit Interface
-Recursive route lookup - Occurs when the router has to perform multiple
lookups in the routing table before forwarding a packet. A static route that
forwards all packets to the next-hop IP address goes through the following
process (reclusive route lookup)
ƒThe router first must match static route’s destination IP address with the
Next hop address
ƒThe next hop address is then matched to an exit interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Static Routes with Exit Interfaces
ƒ Configuring a Static route with an Exit Interface
-Static routes configured with an exit interface are more efficient
–The routing table can resolve the exit interface in a single search instead
of 2 searches
-Example of syntax require to configure a static route with an exit interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Static Routes with Exit Interfaces
ƒ Modifying Static routes
ƒExisting static routes cannot be modified. The old static route
must be deleted by placing no in front of the ip route
ƒExample:
-no ip route 192.168.2.0 255.255.255.0 172.16.2.2
ƒA new static route must be rewritten in the configuration

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Static Routes with Exit Interfaces
ƒ Verifying the Static Route Configuration
-Use the following commands
ƒStep 1 show running-config
ƒStep 2 verify if static route has been entered correctly
ƒStep 3 show ip route
ƒStep 4 verify if route was configured in routing table
ƒStep 5 issue ping command to verify packets can reach
destination and that Return path is working

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
Static Routes with Exit Interfaces
ƒ Ethernet interfaces and ARP.
– If a static route is configured on an Ethernet link
-If the packet is sent to the next-hop router then…
the destination MAC address will be the
address of the next hop’s Ethernet interface
This is found by the router consulting the
ARP table.
If an entry isn’t found then an ARP
request will be sent out

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
Summary and Default Route
ƒ Summarizing routes reduces the size of the routing table.
ƒ Route summarization is the process of combining a number
of static routes into a single static route.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 30
Summary and Default Route
ƒ Configuring a summary route
Step 1: Delete the current static route
Step 2: Configure the summary static route
Step 3: Verify the new static route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 31
Summary and Default Route
ƒ Default Static Route
ƒThis is a route that will match all packets. Stub routers that
have a number of static routes all exiting the same interface are
good candidates for a default route.
-Like route summarization this will help reduce the size of the
routing table

ƒ Configuring a default static route


ƒSimilar to configuring a static route. Except that destination IP
address and subnet mask are all zeros
ƒExample:
-Router(config)#ip route 0.0.0.0 0.0.0.0 [exit-interface | ip-
address ]

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 32
Summary and Default Route
ƒ Static routes and subnet masks
The routing table lookup process will use the most specific
match when comparing destination IP address and subnet
mask

ƒ Default static routes and subnet masks


Since the subnet mask used on a default static route is 0.0.0.0
all packets will match.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 33
Static Routes and Packet Forwarding
ƒ Packet forwarding with
static routes. (recall
Zinin’s 3 routing
principles)
ƒ Router 1
Packet arrives on R1’s
Fastethernet 0/0
interface
-R1 does not have a
route to the destination
network,
192.168.2.0/24
-R1 uses the default
static route.
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 34
Static Routes and Packet Forwarding
ƒ Packet forwarding with static routes. (recall Zinin’s 3
routing principles)
ƒ Router 2
-The packet arrives on the Serial 0/0/0 interface on R2.
-R2 has a static route to 192.168.2.0/24 out Serial0/0/1.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 35
Static Routes and Packet Forwarding
ƒ Packet forwarding with static routes. (recall Zinin’s 3
routing principles)
ƒ Router 3
-The packet arrives on the Serial0/0/1 interface on R3.
-R3 has a connected route to 192.168.2.0/24 out Fastethernet
0/1.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 36
Static Routes and Packet Forwarding
ƒ Troubleshooting a Missing Route
ƒ Tools that can be used to isolate routing problems
include:
-Ping– tests end to end connectivity
-Traceroute– used to discover all of the hops (routers) along the
path between 2 points
-Show IP route– used to display routing table & ascertain
forwarding process
-Show ip interface brief- used to show status of router interfaces
-Show cdp neighbors detail– used to gather configuration
information about directly connected neighbors

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 37
Static Routes and Packet Forwarding
ƒ Solving a Missing Route
ƒ Finding a missing or mis-configured route requires
methodically using the correct tools
-Start with PING. If ping fails then use traceroute to determine
where packets are failing to arrive

ƒ Issue: show ip route to examine routing table.


-If there is a problem with a mis-configured static route remove
the static route then reconfigure the new static route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 38
Static Routes and Packet Forwarding
ƒ Solving a Missing Route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 39
Static Routes and Packet Forwarding
ƒ Solving a Missing Route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 40
Summary
ƒ Routers
-Operate at layer 3
-Functions include best path selection & forwarding packets
ƒ Connecting Networks
WANs
Serial cables are connected to router serial ports.
In the lab environment clock rates must be configured for DCE
LANs
Straight through cables or cross over cables are used to
connect to fastethernet port. (The type of cable used depends
on what devices are being connected)
ƒ Cisco Discovery Protocol
A layer 2 proprietary protocol
Used to discover information about directly connected Cisco
devices

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 41
Summary
ƒ Static Routes
-This is a manually configured path that specifies how the router
will get to a certain point using a certain path.
ƒ Summary static routes
-This is several static routes that have been condensed into a
single static route.
ƒ Default route
-It is the route packets use if there is no other possible match for
their destination in the routing table.
ƒ Forwarding of packets when static route is used
-Zinin’s 3 routing principles describe how packets are forwarded
ƒ Troubleshooting static routes may require some of the following
commands:
-Ping
-Traceroute
-Show IP route
-Show ip interface brief
ITE PC v4.0
-Show cdp neighbors detail
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 42
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 43
Introduction to Dynamic
Routing Protocol

Routing Protocols and


Concepts – Chapter 3

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
Describe the role of dynamic routing protocols and
place these protocols in the context of modern
network design.
Identify several ways to classify routing protocols.
Describe how metrics are used by routing protocols
and identify the metric types used by dynamic routing
protocols.
Determine the administrative distance of a route and
describe its importance in the routing process.
Identify the different elements of the routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Dynamic Routing Protocols - History

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Dynamic Routing Protocols
Function(s) of Dynamic Routing Protocols:
-Dynamically share information between routers.
-Automatically update routing table when topology changes.
-Determine best path to a destination.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Dynamic Routing Protocols
The purpose of a dynamic routing protocol is to:
-Discover remote networks
-Maintaining up-to-date routing information
-Choosing the best path to destination networks
-Ability to find a new best path if the current path is no longer
available

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Dynamic Routing Protocols
Components of a routing protocol
Algorithm
In the case of a routing protocol algorithms are used for
facilitating routing information and best path determination
Routing protocol messages
These are messages for discovering neighbors and
exchange of routing information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Static Routing Protocols
Advantages of static routing
-It can backup multiple interfaces/networks on a router
-Easy to configure
-No extra resources are needed
-More secure

Disadvantages of static routing


-Network changes require manual reconfiguration
-Does not scale well in large topologies

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Static vs Dynamic Routing Protocols

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Classifying Routing Protocols
Dynamic routing protocols are grouped according
to characteristics. Examples include:
-RIP
-IGRP
-EIGRP
-OSPF
-IS-IS
-BGP

Autonomous System is a group of routers under


the control of a single authority.
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Classifying Routing Protocols
Types of routing protocols:
-Interior Gateway Protocols (IGP)
-Exterior Gateway Protocols (EGP)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Classifying Routing Protocols
Interior Gateway Routing Protocols (IGP)
-Used for routing inside an autonomous system & used to route
within the individual networks themselves.
-Examples: RIP, EIGRP, OSPF

Exterior Routing Protocols (EGP)


-Used for routing between autonomous systems
-Example: BGPv4

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Classifying Routing Protocols
IGP: Comparison of Distance Vector & Link State
Routing Protocols
Distance vector
– routes are advertised as vectors
of distance & direction.
– incomplete view of network
topology.
–Generally, periodic
updates.
Link state
– complete view of network
topology is created.
– updates are not
periodic.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Classifying Routing Protocols
Classful routing
protocols
Do NOT send subnet mask
in routing updates

Classless routing
protocols
Do send subnet mask in
routing updates.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Classifying Routing Protocols
Convergence is defined as when all routers’ routing
tables are at a state of consistency

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Routing Protocols Metrics
Metric
A value used by a routing protocol to determine which
routes are better than others.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Routing Protocols Metrics
Metrics used in IP routing protocols
-Bandwidth
-Cost
-Delay
-Hop count
-Load
-Reliability

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Routing Protocols Metrics
The Metric Field in the
Routing Table
Metric used for each
routing protocol
-RIP - hop count
-IGRP & EIGRP -
Bandwidth (used by
default), Delay (used by
default), Load, Reliability
-IS-IS & OSPF – Cost,
Bandwidth (Cisco’s
implementation)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Routing Protocols Metrics
Load balancing
This is the ability of a router to distribute packets among
multiple same cost paths

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Administrative Distance of a Route
Purpose of a metric
It’s a calculated value used to determine the best path to a
destination

Purpose of Administrative Distance


It’s a numeric value that specifies the preference of a particular
route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Administrative Distance of a Route
Identifying the Administrative Distance (AD) in a
routing table
It is the first number in the brackets in the routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Administrative Distance of a Route
Dynamic Routing Protocols

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Administrative Distance of a Route
Directly connected routes
Have a default AD of 0

Static Routes
Administrative distance of a static route has a default value of
1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Administrative Distance of a Route
Directly connected routes
-Immediately appear in the routing table as soon as the
interface is configured

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Summary
Dynamic routing protocols fulfill the following functions
-Dynamically share information between routers
-Automatically update routing table when topology changes
-Determine best path to a destination
Routing protocols are grouped as either
-Interior gateway protocols (IGP)Or
-Exterior gateway protocols(EGP)
Types of IGPs include
-Classless routing protocols - these protocols include subnet mask
in routing updates
-Classful routing protocols - these protocols do not include subnet
mask in routing update

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Summary
Metrics are used by dynamic routing protocols to calculate the
best path to a destination.
Administrative distance is an integer value that is used to
indicate a router’s “trustworthiness”
Components of a routing table include:
-Route source
-Administrative distance
-Metric
Excercise 3.5.1 ☺

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Distance Vector Routing
Protocols

Routing Protocols and Concepts – Chapter 4

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Identify the characteristics of distance vector routing
protocols.
ƒ Describe the network discovery process of distance
vector routing protocols using Routing Information
Protocol (RIP).
ƒ Describe the processes to maintain accurate routing
tables used by distance vector routing protocols.
ƒ Identify the conditions leading to a routing loop and
explain the implications for router performance.
ƒ Recognize that distance vector routing protocols are
in use today

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Static routes VS scalability

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Distance Vector Routing Protocols
ƒ Examples of Distance Vector routing protocols:
ƒRouting Information Protocol (RIP)
ƒHop count, max 15
ƒSent every 30 sec
ƒInterior Gateway Routing Protocol (IGRP)
ƒBandwidth, delay, load and reliability
ƒSent every 90 sec

ƒEnhanced Interior Gateway Routing Protocol (EIGRP)


ƒUnequal cost load balancing
ƒUses DUAL
ƒNo periodic updates
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Distance Vector Routing Protocols
ƒ Distance Vector Technology
–The Meaning of Distance Vector:
•A router using distance vector routing protocols knows 2
things:
ƒDistance to final destination
ƒVector, or direction, traffic should be directed

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Distance Vector Routing Protocols
Characteristics of Distance Vector routing protocols:
ƒ Periodic updates
ƒ Neighbors
ƒ Broadcast updates
ƒ Entire routing table is included with routing update

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Distance Vector Routing Protocols
ƒ Routing Protocol Algorithm:
-Defined as a procedure for accomplishing a certain task

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Distance Vector Routing Protocols
Routing Protocol Characteristics
–Criteria used to compare routing protocols includes
ƒTime to convergence
ƒScalability
ƒClassless or VLSM
ƒResource usage
ƒImplementation & maintenance

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Distance Vector Routing Protocols

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Network Discovery
ƒ Router initial start up (Cold Starts)
-Initial network discovery
ƒDirectly connected networks are initially placed in
routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Network Discovery
ƒ Initial Exchange of Routing Information
–If a routing protocol is configured then
-Routers will exchange routing information
ƒ Routing updates received from other routers
-Router checks update for new information
ƒIf there is new information:
-Metric is updated
-New information is
stored in routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Network Discovery
ƒ Exchange of Routing Information
–Router convergence is reached when
-All routing tables in the network contain the same
network information
–Routers continue to exchange routing information
-If no new information is found then Convergence is
reached

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Network Discovery
ƒ Convergence must be reached before a network is
considered completely operable
ƒ Speed of achieving convergence consists of 2
interdependent categories
-Speed of broadcasting routing information
-Speed of calculating routes

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Routing Table Maintenance
ƒ Periodic Updates: RIPv1 & RIPv2
These are time intervals in which a router sends
out its entire routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Routing Table Maintenance
RIP uses 4 timers
ƒ Update timer 30s
ƒ Invalid timer 180s,
metric = 16
ƒ Holddown timer 180s
after route marked unreachable
ƒ Flush timer 240s
remove route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Routing Table Maintenance
ƒ Bounded Updates: EIGRP
ƒ EIRPG routing updates are
-Partial updates
-Triggered by topology changes
-Bounded
-Non periodic

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Routing Table Maintenance
ƒ Triggered Updates
–Conditions in which triggered updates are sent
-Interface changes state
-Route becomes unreachable
-Route is placed in routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Routing Table Maintenance
ƒ Random Jitter
Synchronized updates
A condition where multiple routers on multi access LAN
segments transmit routing updates at the same time.
ƒProblems with synchronized updates
-Bandwidth consumption
-Packet collisions
ƒSolution to problems with
synchronized updates
- Used of random variable
called RIP_JITTER 0-25% of
default interval

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Routing Loops

ƒ Routing loops are


A condition in
which a packet is
continuously
transmitted within
a series of routers
without ever
reaching its
destination.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Routing Loops
ƒ Routing loops may be caused by:
-Incorrectly configured static routes
-Incorrectly configured route redistribution
-Slow convergence
-Incorrectly configured discard routes
ƒ Routing loops can create the following issues
-Excess use of bandwidth
-CPU resources may be strained
-Network convergence is degraded
-Routing updates may be lost or not processed in a timely
manner

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Routing Loops

ƒ Count to Infinity
This is a routing loop whereby packets bounce
infinitely around a network.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Routing Loops
ƒ Setting a maximum (RIP = 15)
ƒ Distance Vector routing protocols set a specified
metric value to indicate infinity
Once a router “counts to infinity” it marks the route
as unreachable

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Routing Loops
ƒ Preventing loops with holddown timers
-Holddown timers allow a router to not accept any changes to a
route for a specified period of time.
-Point of using holddown timers
ƒAllows routing updates to propagate through network with
the most current information.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Routing Loops
ƒ The Split Horizon Rule is used to prevent routing
loops
ƒ Split Horizon rule:
A router should not advertise a network through the
interface from which the update came.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Routing Loops
ƒ Split horizon with poison
reverse
The rule states that
once a router learns of
an unreachable route
through an interface,
advertise it as
unreachable

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Routing Loops
ƒ IP & TTL
–Purpose of the TTL field
The TTL field is found in an IP header and is
used to prevent packets from endlessly
traveling on a network
ƒ How the TTL field works
-TTL field contains a numeric value
The numeric value is decreased by one by
every router on the route to the destination.
If numeric value reaches 0 then Packet
is discarded.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Routing Protocols Today
ƒ Factors used to determine whether to use RIP or EIGRP
include
-Network size
-Compatibility between models of routers
-Administrative knowledge

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Routing Protocols Today

ƒ RIP
ƒFeatures of RIP:
-Supports split horizon & split horizon with
poison reverse
-Capable of load balancing
-Easy to configure
-Works in a multi vendor router environment

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
Routing Protocols Today

ƒ EIGRP
ƒFeatures of EIGRP:
-Triggered updates
-EIGRP hello protocol used to establish
neighbor adjacencies
-Supports VLSM & route summarization
-Use of topology table to maintain all routes
-Classless distance vector routing protocol
-Cisco proprietary protocol

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
Summary
ƒ Characteristics of Distance Vector routing
protocols
–Periodic updates
–RIP routing updates include the entire routing table
–Neighbors are defined as routers that share a link and are
configured to use the same protocol
ƒ The network discovery process for D.V. routing
protocol
–Directly connected routes are placed in routing table 1st
–If a routing protocol is configured then
•Routers will exchange routing information
–Convergence is reached when all network routers have the
same network information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 30
Summary
ƒ D.V. routing protocols maintains routing tables by
–RIP sending out periodic updates
–RIP using 4 different timers to ensure information is accurate
and convergence is achieved in a timely manner
–EIGRP sending out triggered updates

ƒ D.V. routing protocols may be prone to routing loops


– routing loops are a condition in which packets continuously
traverse a network
–Mechanisms used to minimize routing loops include defining
maximum hop count, holddown timers, split horizon, route
poisoning and triggered updates

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 31
Summary
ƒ Conditions that can lead to routing loops include
–Incorrectly configured static routes
–Incorrectly configured route redistribution
–Slow convergence
–Incorrectly configured discard routes

ƒ How routing loops can impact network performance


includes:
–Excess use of bandwidth
–CPU resources may be strained
–Network convergence is degraded
–Routing updates may be lost or not processed

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 32
Summary
ƒ Routing Information Protocol (RIP)
A distance vector protocol that has 2 versions
RIPv1 – a classful routing protocol
RIPv2 - a classless routing protocol

ƒ Enhanced Interior Gateway Routing Protocol


(EIGRP)
–A distance vector routing protocols that has some features of
link state routing protocols
–A Cisco proprietary routing protocol

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 33
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 34
RIP version 1

Routing Protocols and


Concepts – Chapter 5

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Describe the functions, characteristics, and operation
of the RIPv1 protocol.
ƒ Configure a device for using RIPv1.
ƒ Verify proper RIPv1 operation.
ƒ Describe how RIPv1 performs automatic
summarization.
ƒ Configure, verify, and troubleshoot default routes
propagated in a routed network implementing RIPv1.
ƒ Use recommended techniques to solve problems
related to RIPv1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
RIPv1
ƒ RIP Characteristics
-A classful, Distance Vector (DV) routing protocol
-Metric = hop count
-Routes with a hop count > 15 are unreachable
-Updates are broadcast every 30 seconds

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
RIPv1
ƒ RIP Message Format
ƒ RIP header - divided into
3 fields
-Command field
-Version field
-Must be zero
ƒ Route Entry - composed
of 3 fields
-Address family
identifier
-IP address
-Metric
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
RIPv1
ƒ RIP Operation
–RIP uses 2 message types:
ƒRequest message
-This is sent out on startup by each RIP
enabled interface
-Requests all RIP enabled neighbors to send
routing table
ƒResponse message
-Message sent to requesting router
containing routing table
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
RIPv1
ƒ IP addresses initially divided
into classes
-Class A
-Class B
-Class C
ƒ RIP is a classful routing
protocol
-Does not send subnet
masks in routing updates

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
RIPv1
ƒ Administrative Distance
–RIP’s default administrative distance is 120

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Basic RIPv1 Configuration
ƒ A typical topology suitable for
use by RIPv1 includes:
-Three router set up
-No PCs attached to LANs
-Use of 5 different IP
subnets

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Basic RIPv1 Configuration
ƒ Router RIP Command
–To enable RIP enter:
-Router rip at the global configuration prompt
-Prompt will look like R1(config-router)#

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Basic RIPv1 Configuration
ƒ Specifying Networks
–Use the network
command to:
-Enable RIP on all
interfaces that
belong to this
network
-Advertise this
network in RIP
updates
sent to other
routers
every 30 seconds
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Verification and Troubleshooting

ƒ Show ip Route
ƒ To verify and
troubleshoot routing
-Use the following
commands:
-show ip route
-show ip protocols

-debug ip rip

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Verification and Troubleshooting
ƒ show ip
protocols
command
-Displays
routing
protocol
configured
on router

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Verification and Troubleshooting
ƒ Debug ip rip command
-Used to display RIP routing updates as they are
happening

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Verification and Troubleshooting
ƒ Passive interface command
-Used to prevent a router from sending updates through
an interface
-Example:
Router(config-router)#passive-interface interface-type interface-number

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Verification and Troubleshooting
ƒ Passive interfaces

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Automatic Summarization
Modified Topology
ƒ The original scenario has been
modified such that:
Three classful networks are used:
172.30.0.0/16
192.168.4.0/24
192.168.5.0/24
The 172.30.0.0/16 network is
subnetted into three subnets:
172.30.1.0/24
172.30.2.0/24
172.30.3.0/24
The following devices are part of the
172.30.0.0/16 classful network address:
All interfaces on R1
ITE PC v4.0
S0/0/0 and Fa0/0 on R2
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Automatic Summarization
ƒ Configuration Details
-To remove the RIP routing
process use the following
command
No router rip
-To check the configuration
use the following command
Show run

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Automatic Summarization
ƒ Boundary Routers
–RIP automatically summarizes classful networks
–Boundary routers summarize RIP subnets from one
major network to another.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Automatic Summarization
Processing RIP Updates
ƒ 2 rules govern RIPv1 updates:
-If a routing update and the interface it’s
received on belong to the same
network then
The subnet mask of the
interface is applied to the
network in the routing update
-If a routing update and the interface it’s
received on belong to a different
network then
The classful subnet mask of the
network is applied to the
network in the routing update.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Automatic Summarization
ƒ Sending RIP
Updates
–RIP uses
automatic
summarizatio
n to reduce
the size of a
routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Automatic Summarization
ƒ Advantages of automatic
summarization:
-The size of
routing updates is
reduced
-Single routes are
used to represent
multiple routes
which results in
faster lookup in the
routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Automatic Summarization
ƒ Disadvantage of Automatic Summarization:
-Does not support discontiguous networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Automatic Summarization
ƒ Discontiguous
Topologies do not
converge with RIPv1
ƒ A router will only
advertise major
network addresses
out interfaces that do
not belong to the
advertised route.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Default Route and RIPv1
ƒ Modified Topology: Scenario C
ƒ Default routes
Packets that are not defined specifically in a routing
table will go to the specified interface for the default
route
Example: Customer routers use default routes to
connect to an ISP router.
Command used to configure a default route is
ip route 0.0.0.0 0.0.0.0 s0/0/1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Default Route and RIPv1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Default Route and RIPv1

ƒ Propagating the Default


Route in RIPv1

ƒ Default-information
originate command
-This command is used to specify that the
router is to originate default information,
by propagating the static default route in
ITE PC v4.0
RIP update.
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Summary

ƒ RIP characteristics include:


Classful, distance vector routing protocol
Metric is Hop Count
Does not support VLSM or discontiguous subnets
Updates every 30 seconds
ƒ Rip messages are encapsulated in a UDP segment
with source and destination ports of 520

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Summary: Commands used by RIP
Command Command’s purpose

Rtr(config)#router rip Enables RIP routing process

Rtr(config-router)#network Associates a network with a RIP routing process

Rtr#debug ip rip used to view real time RIP routing updates

Rtr(config-router)#passive-interface fa0/0 Prevent RIP updates from going out an interface

Rtr(config-router)#default-information originate Used by RIP to propagate default routes

Rtr#show ip protocols Used to display timers used by RIP

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
VLSM and CIDR

Routing Protocols and


Concepts – Chapter 6

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
Compare and contrast classful and classless IP
addressing.
Review VLSM and explain the benefits of classless IP
addressing.
Describe the role of the Classless Inter-Domain
Routing (CIDR) standard in making efficient use of
scarce IPv4 addresses

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Introduction
Prior to 1981, IP addresses used only the first 8 bits to
specify the network portion of the address
In 1981, RFC 791 modified the IPv4 32-bit address to
allow for three different classes
IP address space was depleting rapidly
the Internet Engineering Task Force (IETF)
introduced Classless Inter-Domain Routing (CIDR)
–CIDR uses Variable Length Subnet Masking
(VLSM) to help conserve address space.
-VLSM is simply subnetting a subnet

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Classful and Classless IP Addressing
Classful IP addressing
As of January 2007, there
are over 433 million hosts
on Internet
Initiatives to conserve IPv4
address space include:
-VLSM & CIDR notation
(1993, RFC 1519)
-Network Address
Translation (1994, RFC
1631)
-Private Addressing
(1996, RFC 1918)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Classful and Classless IP Addressing

The High Order Bits


These are the leftmost bits in a 32 bit address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Classful and Classless IP Addressing
Classes of IP addresses are identified by the decimal number of
the 1st octet
Class A address begin with a 0 bit
Range of class A addresses = 0.0.0.0 to 127.255.255.255
Class B address begin with a 1 bit and a 0 bit
Range of class B addresses = 128.0.0.0 to 191.255.255.255
Class C addresses begin with two 1 bits & a 0 bit
Range of class C addresses = 192.0.0.0 to 223.255.255.255.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Classful and Classless IP Addressing
The IPv4 Classful Addressing Structure (RFC 790)
An IP address has 2 parts:
-The network portion
Found on the left side of an IP address
-The host portion
Found on the right side of an IP address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Classful and Classless IP Addressing

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Classful and Classless IP Addressing

Purpose of a subnet mask


It is used to determine the network portion of an IP
address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Classful and Classless IP Addressing
Classful Routing Updates
-Recall that classful routing protocols (i.e. RIPv1)
do not send subnet masks in their routing updates
The reason is that the Subnet mask is
directly related to the network address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Classful and Classless IP Addressing
Classless Inter-domain Routing (CIDR – RFC 1517)
Advantage of CIDR :
-More efficient use of IPv4 address
space
-Route summarization
Requires subnet mask to be included in routing update
because address class is meaningless
Recall purpose of a subnet mask:
-To determine the network and host portion
of an IP address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Classful and Classless IP Addressing
Classless IP Addressing
CIDR & Route Summarization
-Variable Length Subnet Masking (VLSM)
-Allows a subnet to be further sub-netted
according to individual needs
-Prefix Aggregation a.k.a. Route Summarization
-CIDR allows for routes to be summarized as a
single route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Classful and Classless IP Addressing

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Classful and Classless IP Addressing
Classless Routing Protocol
Characteristics of classless routing protocols:
-Routing updates include the subnet mask
-Supports VLSM
Supports Route Summarization

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Classful and Classless IP Addressing

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Classful and Classless IP Addressing
Classless Routing Protocol

Routing Routing Supports Ability to send


Protocol updates VLSM Supernet routes
Include
subnet
Mask

Classful No No No

Classless Yes Yes Yes


ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
VLSM
Classful routing
-only allows for one
subnet mask for all
networks
VLSM & classless routing
-This is the process
of subnetting a subnet
-More than one
subnet mask can be
used
-More efficient use of IP
addresses as compared
to classful IP
addressing BACKBONE
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
VLSM
VLSM – the process of
sub-netting a subnet to fit
your needs
-Example:
Subnet 10.1.0.0/16, 8
more bits are borrowed
again, to create 256
subnets with a /24 mask.
-Mask allows for 254 host
addresses per subnet
-Subnets range from:
10.1.0.0 / 24 to
10.1.255.0 / 24
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Classless Inter-Domain Routing (CIDR)
Route summarization done by CIDR
-Routes are summarized with masks that are less
than that of the default classful mask
-Example:
172.16.0.0 / 13 is the summarized
route for the 172.16.0.0 / 16 to
172.23.0.0 / 16 classful networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Classless Inter-Domain Routing (CIDR)
Steps to calculate a route
summary
-List networks in binary
format
-Count number of left
most matching bits to
determine summary
route’s mask
-Copy the matching
bits and add zero bits
to determine the
summarized
network address
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Summary
Classful IP addressing
IPv4 addresses have 2 parts:
-Network portion found on left side of an IP
address
-Host portion found on right side of an IP
address
Class A, B, & C addresses were designed to provide IP
addresses for different sized organizations
The class of an IP address is determined by the decimal
value found in the 1st octet
IP addresses are running out so the use of Classless Inter
Domain Routing (CIDR) and Variable Length Subnet Mask
(VLSM) are used to try and conserve address space

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Summary
Classful Routing Updates
–Subnet masks are not sent in routing updates
Classless IP addressing
–Benefit of classless IP addressing
Can create additional network
addresses using a subnet mask
that fits your needs
–Uses Classless Interdomain Routing (CIDR)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Summary
CIDR
Uses IP addresses more efficiently through
use of VLSM
-VLSM is the process of
subnetting a subnet
Allows for route summarization
-Route summarization is
representing multiple contiguous
routes with a single route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Summary
Classless Routing Updates
Subnet masks are included in updates

LAB 6.4.1
LAB 6.4.2 ☺
LAB 6.4.3
LAB 6.4.4
LAB 6.4.5 ☺
LAB 6.4.6

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
RIPv2

Routing Protocols and


Concepts – Chapter 7

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Encounter and describe the limitations of RIPv1’s
limitations.
ƒ Apply the basic Routing Information Protocol Version
2 (RIPv2) configuration commands and evaluate
RIPv2 classless routing updates.
ƒ Analyze router output to see RIPv2 support for VLSM
and CIDR
ƒ Identify RIPv2 verification commands and common
RIPv2 issues.
ƒ Configure, verify, and troubleshoot RIPv2 in “hands-
on” labs

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Introduction
ƒ Chapter focus
-Difference between RIPv1 & RIPv2
ƒRIPv1
-A classful distance vector routing protocol
-Does not support discontiguous subnets
-Does not support VLSM
-Does not send subnet mask in routing update
-Routing updates are broadcast
ƒRIPv2
-A classless distance vector routing protocol that is an
enhancement of RIPv1’s features.
-Next hop address is included in updates
-Routing updates are multicast
-The use of authentication is an option

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Introduction

ƒ Similarities between RIPv1 & RIPv2


-Use of timers to prevent routing loops
-Use of split horizon or split horizon with poison
reverse
-Use of triggered updates
-Maximum hop count of 15

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
RIPv1 Limitations
ƒ Lab Topology
ƒ Scenario:
ƒ3 router set up
ƒTopology is discontiguous
ƒThere exists a static summary
route
ƒStatic route information can be
injected into routing table updates
using redistribution.
ƒRouters 1 & 3 contain VLSM
networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
RIPv1 Limitations
ƒ Scenario Continued
ƒ VLSM
-Recall this is sub netting
the subnet
ƒ Private IP addresses are
on LAN links
ƒ Public IP addresses are
used on WAN links
ƒ Loopback interfaces
-These are virtual
interfaces that can be
pinged and added to
routing table
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
RIPv1 Limitations
ƒ Null Interfaces
ƒThis is a virtual interface that does not need to be
created or configured
-Traffic sent to a null interface is discarded
-Null interfaces do not send or receive traffic

ƒ Static routes and null interfaces


ƒnull interfaces will serve as the exit interface for
static route
-Example of configuring a static supernet route with a
null interface
-R2(config)#ip route 192.168.0.0 255.255.0.0 Null0

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
RIPv1 Limitations
ƒ Route redistribution
-Redistribution command is way to disseminate a
static route from one router to another via a routing
protocol
-Example
R2(config-router)#redistribute static

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
RIPv1 Limitations

ƒ Verifying and Testing Connectivity


Use the following commands:
ƒ show ip interfaces brief
ƒ ping
ƒ traceroute

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
RIPv1 Limitations
ƒ RIPv1 – a classful routing protocol
-Subnet mask are not sent in updates
-Summarizes networks at major network boundaries
-if network is discontiguous and RIPv1 configured
convergence
will not be reached

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
RIPv1 Limitations
ƒExamining the routing tables
-To examine the contents of
routing updates use the
debug ip rip command
-If RIPv1 is
configured then
Subnet masks will not be
included with the
network address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
RIPv1 Limitations
ƒ RIPv1 does not support
VLSM
Reason: RIPv1 does not
send subnet mask
in routing updates
ƒ RIPv1 does summarize
routes to the Classful
boundary
Or uses the Subnet mask
of the outgoing interface
to determine which
subnets to advertise

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
RIPv1 Limitations
ƒ No CIDR Support
ƒ In the diagram R2 will not
include the static route in its
update
Reason: Classful routing
protocols do not support
CIDR routes that are
summarized with a smaller
mask than the classful
subnet mask

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Configuring RIPv2
ƒ Comparing RIPv1 & RIPv2 Message Formats
-RIPv2 Message format is similar to RIPv1 but has 2
extensions
ƒ1st extension is the subnet mask field
ƒ2nd extension is the addition of next hop
address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Configuring RIPv2

ƒ Enabling and Verifying RIPv2


ƒ Configuring RIP on a Cisco router
By default it is running RIPv1

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Configuring RIPv2
ƒ Configuring RIPv2 on a
Cisco router
-Requires using the
version 2 command
-RIPv2 ignores RIPv1
updates
ƒ To verify RIPv2 is
configured use the
show ip protocols
command

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Configuring RIPv2

ƒ Auto-Summary & RIPv2


ƒ RIPv2 will automatically
summarize routes at
major network
boundaries and can
also summarize routes
with a subnet mask that
is smaller than the
classful subnet mask

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Configuring RIPv2

ƒ Disabling Auto-
Summary in RIPv2
ƒ To disable automatic
summarization issue
the no auto-summary
command

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Configuring RIPv2
ƒ Verifying RIPv2 Updates
ƒ When using RIPv2 with automatic summarization turned off
Each subnet and mask has its own specific entry, along
with the exit interface and next-hop address to reach that
subnet.
ƒ To verify information being sent by RIPv2 use the
debug ip rip command

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
VLSM & CIDR

ƒ RIPv2 and VLSM


ƒ Networks using a VLSM IP
addressing scheme
Use classless
routing protocols (i.e.
RIPv2) to
disseminate
network addresses
and their subnet
masks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
VLSM & CIDR

ƒ CIDR uses Supernetting


Supernetting is a bunch of contiguous classful
networks that is addressed as a single
network.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
VLSM & CIDR
ƒ To verify that
supernets are
being sent and
received use the
following commands
-Show ip route
-Debug ip rip

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Verifying & Troubleshooting RIPv2
ƒ Basic Troubleshooting steps
-Check the status of all links
-Check cabling
-Check IP address & subnet mask configuration
-Remove any unneeded configuration commands
ƒ Commands used to verify proper operation of RIPv2
–Show ip interfaces brief
–Show ip protocols
–Debug ip rip
–Show ip route
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Verifying & Troubleshooting RIPv2
ƒ Common RIPv2 Issues
ƒ When trouble shooting RIPv2 examine the following issues:
ƒVersion
Check to make sure you are using version 2
ƒNetwork statements
Network statements may be incorrectly typed
or missing
ƒAutomatic summarization
If summarized routes are not needed then disable
automatic summarization

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Verifying & Troubleshooting RIPv2
ƒ Reasons why it’s good to authenticate routing information
-Prevent the possibility of accepting invalid routing
updates
-Contents of routing updates are encrypted
ƒ Types of routing protocols that can use authentication
-RIPv2
-EIGRP
-OSPF
-IS-IS
-BGP

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Summary

Routing Distance Classless Uses Use of Max Auto Support Supports Uses
Protocol Vector Routing Hold- Split Hop Summary CIDR VLSM Authen-
Protocol Down Horizon count tication
Timers or = 15
Split
Horizon
w/
Poison
Reverse

RIPv1 Yes No Yes Yes Yes Yes No No No

RIPv2 Yes Yes Yes Yes Yes Yes Yes Yes Yes

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
The Routing Table: A
Closer Look

Routing Protocols and


Concepts – Chapter 8

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Describe the various route types found in the routing
table structure
ƒ Describe the routing table lookup process.
ƒ Describe routing behavior in routed networks.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Introduction

ƒ Chapter Focus
-Structure of the routing table
-Lookup process of the routing table
-Classless and classful routing behaviors

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Routing Table Structure
ƒ Lab Topology
ƒ 3 router setup
-R1 and R2 share a common 172.16.0.0/16 network with
172.16.0.0/24 subnets.
-R2 and R3 are connected by the 192.168.1.0/24 network.
-R3 also has a 172.16.4.0/24 subnet, which is disconnected, or
discontiguous, from the 172.16.0.0 network that R1 and R2
share.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Routing Table Structure
ƒ Routing table entries come from the following sources
-Directly connected networks
-Static routes
-Dynamic routing protocols

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Routing Table Structure
ƒ Level 1 Routes
ƒ As soon as the no shutdown command is issued the
route is added to routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Routing Table Structure
ƒ Cisco IP routing table
is a hierarchical
structure
-The reason for this is
to speed up lookup
process

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Routing Table Structure
ƒ Level 1 Routes
-Have a subnet mask equal to or less than the
classful mask of the network address.
ƒ Level 1 route can function as:

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Routing Table Structure
ƒ Level 1 Routes
-Ultimate Route
ƒIncludes either:
-A next-hop address
OR
-An exit interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Routing Table Structure

ƒ Parent and Child


Routes
-A parent route is a
level 1 route
-A parent route does
not contain any next-
hop IP address or exit
interface information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Routing Table Structure
ƒ Automatic creation of parent
routes
-Occurs any time a
subnet is added to the
routing table
ƒ Child routes
-Child routes are level
2 routes
-Child routes are a
subnet of a classful
network address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Routing Table Structure
ƒ Level 2 child routes contain route source & the network
address of the route
ƒ Level 2 child routes are also considered ultimate
routes
Reason: they contain the next hop address
&/or exit interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Routing Table Structure
ƒ Both child routes have the same subnet mask
-This means the parent route maintains the /24 mask

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Routing Table Structure
ƒ Diagram illustrates 2 child networks belonging to the
parent route 172.16.0.0 / 24

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Routing Table Structure
ƒ In classless networks, child routes do not have to share
the same subnet mask

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Routing Table Structure
ƒ Parent & Child Routes: Classless Networks

Network Parent route’s Term Includes the Subnet mask


Type Classful mask is variably # of different included
Displayed subnetted masks of with each
is seen in parent child routes child route
route in routing entry
table

Class- No No No No
ful
Class- Yes Yes Yes Yes
less

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Routing Table Structure
ƒ Parent & Child Routes: Classless Networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Routing Table Lookup Process
ƒ The Route Lookup Process
ƒ Examine level 1 routes
-If best match a level 1 ultimate route and is not a parent
route this route is used to forward packet
ƒ Router examines level 2 (child) routes
-If there is a match with level 2 child route then
that subnet is used to forward packet
-If no match then
determine routing behavior type
ƒ Router determines classful or classless routing behavior
-If classful then packet is dropped
-If classless then router searches level one supernet and
default routes
-If there exists a level 1 supernet or default route match
then Packet is forwarded. If not packet is dropped
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Routing Table Lookup Process
ƒ Longest Match: Level 1 Network Routes
–Best match is also known as the longest match
–The best match is the one that has the most number of left
most bits matching between the destination IP address and the
route in the routing table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Routing Table Lookup Process
ƒ Finding the subnet mask
used to determine the
longest match
Scenario:
–PC1 pings 192.168.1.2
–Router examines level 1
route for best match
–There exist a match
between192.168.1.2 &
192.168.1.0 / 24
–Router forwards packets
out s0/0/0

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Routing Table Lookup Process
ƒ The process of matching
-1st there must be a match made between the
parent route & destination IP
-If a match is made then an attempt at finding a
match between the destination IP and the child route
is made.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Routing Table Lookup Process
ƒ Finding a match between packet’s destination IP address
and the next route in the routing table
-The figure shows a match between the destination IP of
192.168.1.0 and the level one IP of 192.168.1.0 / 24
then packet forwarded out s0/0/0

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Routing Table Lookup Process
ƒ Level 1 Parent & Level 2 Child Routes
ƒ Before level 2 child routes are examined
-There must be a match between classful level one
parent route and destination IP address.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Routing Table Lookup Process
ƒ After the match with parent route has been made Level 2 child
routes will be examined for a match
-Route lookup process searches for child
routes with a match with destination IP

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Routing Table Lookup Process
ƒ How a router finds a match with one of the level 2 child
routes
-First router examines parent routes for a match
-If a match exists then:
ƒChild routes are examined
ƒChild route chosen is the one with the
longest match

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Routing Table Lookup Process
ƒ Example: Route Lookup
Process with VLSM
-The use of VLSM does not
change the lookup process
-If there is a match between
destination IP address and the
level 1 parent route then
-Level 2 child routes will be
searched

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Routing Behavior
ƒ Classful & classless routing protocols
Influence how routing table is populated
ƒ Classful & classless routing behaviors
Determines how routing table is searched after it is
filled

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Routing Behavior
ƒ Classful Routing
Behavior:
no ip classless
ƒ What happens if there is
not a match with any
level 2 child routes of the
parent?
-Router must determine if
the routing behavior is
classless or classful
-If router is utilizing classful
routing behavior then
-Lookup process is
terminated and
packet is dropped
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
Routing Behavior
ƒ Classful Routing Behavior – Search Process
ƒ An example of when classful routing behavior is in effect and
why the router drops the Packet
-The destination’s subnet mask is a /24 and none of the child
routes left most bits match the first 24 bits. This means packet
is dropped

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
Routing Behavior

ƒ Classful Routing Behavior – Search Process


ƒ The reason why the router will not search beyond the
child routes
ƒOriginally networks were all classful
ƒThis meant an organization could subnet a
major network address and “enlighten” all the
organization’s routers about the subnetting
ƒTherefore, if the subnet was not in the
routing table, the subnet did not exist and
packet was dropped

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 30
Routing Behavior

ƒ ip classless
ƒ Beginning with IOS 11.3, ip classless was configured
by default
ƒ Classless routing behavior works for
-Discontiguous networks
And
-CIDR supernets

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 31
Routing Behavior
ƒ Classless Routing Behavior: ip classless
ƒ Route lookup process when ip classless is in use
-If classless routing behavior in effect then
ƒSearch level 1 routes
ƒSupernet routes Checked first
-If a match exists then forward packet
ƒDefault routes Checked second
If there is no match or no default
route then the
ƒPacket is dropped

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 32
Routing Behavior
ƒ Classless Routing Behavior – Search Process
ƒ Router begins search process by finding a match between
destination IP and parent route
After finding the above mentioned match, then
there is a search of the child route

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 33
Routing Behavior
ƒ Classless Routing Behavior – Search Process
ƒ If no match is found in child routes of previous slide then
Router continues to search the routing table for a
match that may have fewer bits in the match

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 34
Routing Behavior

ƒ Classful vs. Classless Routing Behavior


-It is recommended to use classless routing
behavior
ƒReason: so supernet and default routes can
be used whenever needed

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 35
Summary
Content/structure of a routing table
ƒ Routing table entries
-Directly connected networks
-Static route
-Dynamic routing protocols
ƒ Routing tables are hierarchical
-Level 1 route
Have a subnet mask that is less than or equal to
classful subnet mask for the network address
-Level 2 route
These are subnets of a network address

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 36
Summary
Routing table lookup process
ƒ Begins with examining level 1 routes for best match with packet’s destination IP
ƒ If the best match = an ultimate route then
-Packet is forwarded -Else-
-Parent route is examined
If parent route & destination IP match then Level 2 (child)
routes are examined
Level 2 route examination
ƒ If a match between destination IP and child route found then
Packet forwarded -Else
ƒ If Router is using classful routing behavior then
Packet is dropped -Else

ƒ If router is using classless routing behavior then


Router searches Level 1 supernet & default routes for a
match
ƒ If a match is found then Packet if forwarded -Else
ƒ Packet is dropped

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 37
Summary
ƒ Routing behaviors
-This refers to how a routing table is searched
ƒ Classful routing behavior
-Indicated by the use of the no ip classless command
-Router will not look beyond child routes for a lesser
match
ƒ Classless routing behavior
-Indicated by the use of the ip classless command
-Router will look beyond child routes for a lesser match

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 38
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 39
Link-State Routing
Protocols

Routing Protocols and


Concepts – Chapter 10

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Describe the basic features & concepts of link-state
routing protocols.
ƒ List the benefits and requirements of link-state routing
protocols.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Link-State Routing
ƒ Link state routing protocols
-Also known as shortest path first algorithms
-These protocols are built around Dijkstra’s
SPF

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Link-State Routing
Dikjstra’s algorithm also known as the shortest path first
(SPF) algorithm

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Link-State Routing
ƒ The shortest path to a destination is not necessarily the
path with the least number of hops

SPF for R1:

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Link-State Routing
Link-State Routing Process
ƒ How routers using Link State Routing Protocols reach
convergence
-Each routers learns about its own directly connected networks
-Link state routers exchange hello packet to “meet” other
directly
connected link state routers.
-Each router builds its own Link State Packet (LSP) which
includes information about neighbors such as neighbor ID, link
type, & bandwidth.
-After the LSP is created the router floods it to all neighbors who
then store the information and then forward it until all routers
have the same information.
-Once all the routers have received all the LSPs, the routers
then construct a topological map of the network which is used to
determine the best routes to a destination

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Link-State Routing

ƒ Directly Connected
Networks
ƒ Link
This is an interface on a
router
ƒ Link state
This is the information
about the state of the
links

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Link-State Routing
Sending Hello Packets to Neighbors
ƒ Link state routing protocols use a hello protocol
Purpose of a hello protocol:
-To discover neighbors (that use the same
link state routing protocol) on its link

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Link-State Routing
Sending Hello Packets to
Neighbors
ƒ Connected interfaces that are using
the same link state routing protocols
will exchange hello packets.
ƒ Once routers learn it has neighbors
they form an adjacency
-2 adjacent neighbors will
exchange hello packets
-These packets will serve as a
keep alive function

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Link-State Routing
Building the Link State Packet
ƒEach router builds its own Link State Packet (LSP)
Contents of LSP:
-State of each directly connected link
-Includes information about neighbors such as neighbor ID, link type, &
bandwidth.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Link-State Routing
Flooding LSPs to Neighbors
ƒ Once LSP are created they are forwarded out to neighbors.
-After receiving the LSP the neighbor continues to forward it
throughout routing area.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Link-State Routing
ƒ LSPs are sent out under the following conditions
-Initial router start up or routing process
-When there is a change in topology

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Link-State Routing
ƒ Final Step: Constructing a link state data base
ƒ Routers use a database to construct a topology map of
the network

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Link-State Routing

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Link-State Routing
Shortest Path First (SPF) Tree
ƒ Building a portion of the SPF tree
Process begins by examining R2’s LSP information
-R1 ignores 1st LSP
Reason: R1 already knows it’s connected to R2

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Link-State Routing
ƒ Building a portion of the SPF tree
-R1 uses 2nd LSP
Reason: R1 can create a link from R2 to R5.
This information is added to R1’s SPF tree

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Link-State Routing
ƒ Building a portion of the SPF tree
-R1 uses 3rd LSP
ƒReason: R1 learns that R2 is connected to
10.5.0.0/16.
ƒThis link is added to R1’s SPF tree.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Link-State Routing
ƒ Determining the shortest path
The shortest path to a destination determined by adding the
costs & finding the lowest cost

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Link-State Routing
ƒ Once the SPF algorithm has determined the shortest
path routes, these routes are placed in the routing
table.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Link-State Routing Protocols

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Link-State Routing Protocols
Advantages of a Link-State Routing Protocol

Routing Builds Router can An event driven Use


protocol Topological independently Convergence routing updates of
map determine the LSP
shortest path to
every network.

Distance No No Slow Generally No No


vector

Link State Yes Yes Fast Generally Yes Yes

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Link-State Routing Protocols
Requirements for using a link state routing protocol
ƒ Memory requirements
Typically link state routing protocols use more
memory
ƒ Processing Requirements
More CPU processing is required of link state
routing protocols
ƒ Bandwidth Requirements
Initial startup of link state routing protocols can
consume lots of bandwidth

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Link-State Routing Protocols
ƒ 2 link state routing protocols used for routing IP
-Open Shortest Path First (OSPF)
-Intermediate System-Intermediate System (IS-IS)

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
Summary

ƒ Link State Routing protocols are also known as


Shortest Path First protocols
ƒ Summarizing the link state process
-Routers 1ST learn of directly connected networks
-Routers then say “hello” to neighbors
-Routers then build link state packets
-Routers then flood LSPs to all neighbors
-Routers use LSP database to build a network topology
map & calculate the best path to each destination

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
Summary

ƒ Link
An interface on the router
ƒ Link State
Information about an interface such as
-IP address
-Subnet mask
-Type of network
-Cost associated with link
-Neighboring routers on the link

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
Summary

ƒ Link State Packets


After initial flooding, additional LSP are sent out
when a change in topology occurs

ƒ Examples of link state routing protocols


-Open shortest path first
-IS-IS

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
OSPF

Routing Protocols and


Concepts – Chapter 11

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 1
Objectives
ƒ Describe the background and basic features of OSPF
ƒ Identify and apply the basic OSPF configuration
commands
ƒ Describe, modify and calculate the metric used by
OSPF
ƒ Describe the Designated Router/Backup Designated
Router (DR/BDR) election process in multiaccess
networks
ƒ Describe the uses of additional configuration
commands in OSPF

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 2
Introduction

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 3
Introduction to OSPF
Background of OSPF
ƒ Began in 1987
ƒ 1989 OSPFv1 released in RFC 1131
This version was experimental & never deployed
ƒ 1991 OSPFv2 released in RFC 1247
ƒ 1998 OSPFv2 updated in RFC 2328
ƒ 1999 OSPFv3 published in RFC 2740

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 4
Introduction to OSPF
OSPF Message Encapsulation
ƒ Data link frame header
Contains - Source MAC address and Destination MAC address
DstAddr = 01-00-5E-00-00-05 or 01-00-5E-00-00-06
ƒ IP packet header
Contains - Source IP address, Destination IP address & Protocol field
Proto = 89
DstAddr = 224.0.0.5 or 224.0.0.6
ƒ OSPF packet header
Contains - Router ID and area ID and Type code for OSPF packet type
ƒ OSPF packet type
There exist 5 types

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 5
Introduction to OSPF

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 6
Introduction to OSPF
OSPF Packet Types

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 7
Introduction to OSPF
Hello Protocol
ƒ OSPF Hello Packet
–Purpose of Hello Packet
ƒ Discover OSPF neighbors & establish adjacencies
ƒ Advertise guidelines on which routers must agree to become
neighbors
ƒ Used by multi-access networks to elect a designated router and
a backup designated router

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 8
Introduction to OSPF
ƒ Hello Packets continued
Contents of a Hello Packet
router ID of transmitting router
ƒ OSPF Hello Intervals
–Usually multicast (224.0.0.5)
–Sent every 30 seconds for NBMA segments
ƒ OSPF Dead Intervals
–This is the time that must transpire
before the neighbor is considered
down
–Default time is 4 times
the hello interval

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 9
Introduction to OSPF
ƒ Hello protocol packets contain information that is used
in electing
-Designated Router (DR)
ƒ DR is responsible for updating all other OSPF routers
-Backup Designated Router (BDR)
ƒ This router takes over DR’s responsibilities if DR fails

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 10
Introduction to OSPF
OSPF Link-state Updates
ƒ Purpose of a Link State Update (LSU)
Used to deliver link state advertisements
ƒ Purpose of a Link State Advertisement (LSA)
Contains information about neighbors & path costs

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 11
Introduction to OSPF
OSPF Algorithm
ƒ OSPF routers build &
maintain link-state
database containing LSA
received from other routers
–Information found in
database is utilized upon
execution of Dijkstra SPF
algorithm
–SPF algorithm used to
create SPF tree
–SPF tree used to populate
routing table

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 12
Introduction to OSPF
Administrative Distance
ƒ Default Administrative Distance for OSPF is 110

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 13
Introduction to OSPF
ƒ OSPF Authentication
–Purpose is to encrypt & authenticate routing
information
–This is an interface specific configuration
–Routers will only accept routing information from
other routers that have been configured with the
same password or authentication information

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 14
Basic OSPF Configuration
Lab Topology
ƒ Topology used for this chapter
Discontiguous IP addressing scheme
Since OSPF is a classless routing protocol the subnet mask is
configured

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 15
Basic OSPF Configuration
The router ospf command
ƒ To enable OSPF on a router use the following
command
R1(config)#router ospf process-id
Process id
ƒ A locally significant number between 1 and 65535
-this means it does not have to match other OSPF
routers

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 16
Basic OSPF Configuration
ƒ OSPF network command
-Requires entering: network address
wildcard mask - the inverse of the subnet
mask
area-id - area-id refers to the OSPF area.
OSPF area is a group of routers that
share link state information
-Example: Router(config-router)#network network-address
wildcard-ask area area-id

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 17
Basic OSPF Configuration
ƒ Router ID
–This is an IP address used to identify a router
–3 criteria for deriving the router ID
ƒUse identifier configured with OSPF router-id command
-Takes precedence over loopback and physical interface
addresses
ƒIf router-id command not used then router chooses highest
IP address of any loopback interfaces
ƒIf no loopback interfaces are configured then the highest IP
address on any active interface is used

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 18
Basic OSPF Configuration
OSPF Router ID
ƒ Commands used to verify current router ID
–Show ip protocols
–Show ip ospf
–Show ip ospf interface

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 19
Basic OSPF Configuration
OSPF Router ID
ƒ Router ID & Loopback addresses
-Highest loopback address will be used as router ID if router-id
command isn’t used
-Advantage of using loopback address
the loopback interface cannot fail Æ OSPF stability
ƒ The OSPF router-id command
–Introduced in IOS 12.0
–Command syntax
ƒRouter(config)#router ospfprocess-id
ƒRouter(config-router)#router-idip-address
ƒ Modifying the Router ID
–Use the command Router#clear ip ospf process
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 20
Basic OSPF Configuration
Verifying OSPF
ƒ Use the show ip ospf neighbor command to verify &
trouble shoot OSPF networks
Command will display the following:
ƒ Neighbor adjacency
-No adjacency indicated by -
ƒNeighboring router’s Router ID is not displayed
ƒA state of full is not displayed
-Consequence of no adjacency-
ƒNo link state information exchanged
ƒInaccurate SPF trees & routing tables

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 21
Basic OSPF Configuration
Verifying OSPF - Additional Commands

Command Description

Displays OSPF process ID,


router ID, networks router is
Show ip protocols
advertising & administrative
distance
Displays OSPF process ID,
router ID, OSPF area information
Show ip ospf
& the last time SPF algorithm
calculated
Displays hello interval and dead
Show ip ospf interface interval

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 22
Basic OSPF Configuration
Examining the routing table
ƒ Use the show ip route command to display the routing
table
-An “O’ at the beginning of a route indicates that the router
source is OSPF
-Note OSPF does not automatically summarize at major
network boundaries

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 23
OSPF Metric
ƒ OSPF uses cost as the metric for determining the
best route
-The best route will have the lowest cost
-Cost is based on bandwidth of an interface
ƒCost is calculated using the formula
108 / bandwidth
-Reference bandwidth
ƒdefaults to 100Mbps
ƒcan be modified using
ƒauto-cost reference-bandwidth command

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 24
OSPF Metric
ƒ COST of an OSPF route
Is the accumulated value from one router to the next

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 25
OSPF Metric
ƒ Usually the actual speed of a link is different than the
default bandwidth
–This makes it imperative that the bandwidth value reflects
link’s actual speed
ƒReason: so routing table has best path information
ƒ The show interface command will display interface’s
bandwidth
-Most serial link default to 1.544Mbps

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 26
Basic OSPF Configuration
Modifying the Cost of a link
ƒ Both sides of a serial link should be configured with the
same bandwidth
–Commands used to modify bandwidth value
ƒBandwidth command
–Example: Router(config-if)#bandwidthbandwidth-kbps
ƒip ospf cost command – allows you to directly specify
interface cost
-Example:R1(config)#interface serial 0/0/0
R1(config-if)#ip ospf cost 1562

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 27
Basic OSPF Configuration
Modifying the Cost of the link
ƒ Difference between bandwidth command & the ip ospf
cost command
–Ip ospf cost command
ƒSets cost to a specific value
–Bandwidth command
ƒLink cost is calculated

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 28
OSPF and Multiaccess Networks
Challenges in Multiaccess Networks
ƒ OSPF defines five network types:
–Point-to-point
–Broadcast Multiaccess
–Nonbroadcast Multiaccess (NBMA)
–Point-to-multipoint
–Virtual links

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 29
OSPF in Multiaccess Networks
ƒ 2 challenges presented by multiaccess networks
–Multiple adjacencies
–Extensive LSA flooding

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 30
OSPF in Multiaccess Networks
ƒ Extensive flooding of LSAs
For every LSA sent out there must be an acknowledgement of
receipt sent back to transmitting router.
consequence: lots of bandwidth consumed and chaotic traffic

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 31
OSPF in Multiaccess Networks
ƒ Solution to LSA flooding issue
is the use of
–Designated router (DR)
–Backup designated router (BDR)

ƒ DR & BDR selection


–Routers are elected to send &
receive LSA

ƒ Sending & Receiving LSA


–DRothers send LSAs via
multicast 224.0.0.6 to DR & BDR
–DR forward LSA via multicast
address 224.0.0.5 to all other
routers
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 32
OSPF in Multiaccess Networks
DR/BDR Election Process
ƒ DR/BDR elections DO NOT occur in point to point
networks

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 33
OSPF in Multiaccess Networks
ƒ DR/BDR elections will take place on multiaccess
networks as shown below

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 34
OSPF in Multiaccess Networks
ƒ Criteria for getting elected DR/BDR
1. DR: Router with the highest OSPF
interface priority.
2. BDR: Router with the second highest
OSPF interface priority.
3. If OSPF interface priorities are equal, the
highest router ID is used to break the tie.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 35
OSPF in Multiaccess Networks

ƒ Timing of DR/BDR Election


–Occurs as soon as 1st router has its interface enabled on
multiaccess network
ƒWhen a DR is elected it remains as the DR until one of the
following occurs
-The DR fails.
-The OSPF process on the DR fails.
-The multiaccess interface on the DR fails.
•No preemption mechanism

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 36
OSPF in Multiaccess Networks
ƒ Manipulating the election process
-If you want to influence the election of DR & BDR then do one
of the following
ƒBoot up the DR first, followed by the BDR, and then boot all
other routers,
OR
ƒShut down the interface on all routers, followed by a no
shutdown on the DR, then the BDR, and then all other
routers.

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 37
OSPF in Multiaccess Networks
OSPF Interface Priority
ƒ Manipulating the DR/BDR election process continued
–Use the ip ospf priority interface command.
–Example:Router(config-if)#ip ospf priority {0 - 255}
ƒPriority number range 0 to 255
–0 means the router cannot become the DR or BDR
–1 is the default priority value

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 38
More OSPF Configuration
Redistributing an OSPF Default Route
ƒ Topology includes a link to ISP
–Router connected to ISP
ƒCalled an autonomous system border router
ƒUsed to propagate a default route
–Example of static default route
R1(config)#ip route 0.0.0.0 0.0.0.0 loopback 1
–Requires the use of the default-information originate
command
–Example of default-information originate command
R1(config-router)#default-information originate

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 39
More OSPF Configuration

Fine-Tuning OSPF
ƒ Since link speeds are getting
faster it may be necessary to
change reference bandwidth
values
–Do this using the auto-cost
reference-bandwidth command
–Example:
ƒ R1(config-router)#auto-cost
reference-bandwidth 10000

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 40
More OSPF Configuration

Fine-Tuning OSPF
ƒ Modifying OSPF timers
–Reason to modify timers
ƒFaster detection of network failures
–Manually modifying Hello & Dead intervals
ƒRouter(config-if)#ip ospf hello-interval seconds
ƒRouter(config-if)#ip ospf dead-interval seconds
–Point to be made
ƒHello & Dead intervals must be the same between
neighbors

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 41
Summary
ƒ RFC 2328 describes OSPF link state concepts and
operations
ƒ OSPF Characteristics
–A commonly deployed link state routing protocol
–Employs DRs & BDRs on multi-access networks
ƒDRs & BDRs are elected
ƒDR & BDRs are used to transmit and receive LSAs
–Uses 5 packet types:
1: HELLO
2: DATABASE DESCRIPTION
3: LINK STATE REQUEST
4: LINK STATE UPDATE
5: LINK STATE ACKNOWLEDGEMENT

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 42
Summary
ƒ OSPF Characteristics
–Metric = cost
ƒLowest cost = best path

ƒ Configuration
–Enable OSPF on a router using the following command
ƒR1(config)#router ospf process-id
–use the network command to define which interfaces will
participate in a given OSPF process
ƒRouter(config-router)#network network-address
wildcard-mask area area-id

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 43
Summary
ƒ Verifying OSPF configuration
–Use the following commands
ƒshow ip protocol
ƒshow ip route
ƒshow ip ospf interface
ƒshow ip ospf neighbor

ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 44
ITE PC v4.0
Chapter 1 © 2007 Cisco Systems, Inc. All rights reserved. Cisco Public 45

Vous aimerez peut-être aussi