Vous êtes sur la page 1sur 89

Based on subject :

ITE526: Practical Internetworking

Part of the :
Master of Networking and Systems Administration
Master of Management (IT)
• Routing is the process of sending packets
from one network to another network.
• Key term is network!
• In order to route between networks routers
build routing tables
– Destination networks and subnet masks
– Next Hop to each network
– Metrics & Administrative Distances (AD)
• Routing Table relates to 2 different types of
protocols which sound the same
– Routing Protocols : a protocol that dynamically
helps the router to build the routing & topology
tables e.g. EIGRP, OSPF, BGP4
– Routed Protocols : A Layer 3 protocol that
applies logical addresses to devices and routes
data between networks e.g. IPv4, IPv6, IPX
• To decide on the best route to any given
destination a router considers the
following 3 things in order :
– Prefix-length
– Metric
– Administrative Distance
• Prefix-Length is the number of bits used to
identify the network portion of the
destination address and is used to
determine the most specific route. The
longer the prefix-length the more specific
the route.
e.g. packet destined for will match
more specifically with “” than
• Metric allows a router to choose the best
path within a routing protocol
– Hop-count or cost are two common metrics
– Routes with the best metric are placed into the
routing table
• Administrative Distance is used to decide
which routing protocol is more trustworthy
– That is it determines routes between routing
• AD = trustworthiness of a routing protocol
• Lowest metric, or AD, always wins and
results in that route being inserted into
the routing table
• Routes with an AD of “unknown” will
never be placed into the routing table
• Routers connect
networks together.
• One-to-one
between interfaces
and subnets.
• Routers learn routes via static routes and
dynamic routing protocols.
• Routers use routing tables to determine
the best path to send packets.
• Routers encapsulate the packet and
forward it out the best interface based on
the routing table.
Best path is selected by a routing protocol based on the value or metric
it uses to determine the distance to reach a network:
 A metric is the value used to measure the distance to a given
 Best path to a network is the path with the lowest metric.
Dynamic routing protocols use their own rules and metrics to build and
update routing tables:
 Routing Information Protocol (RIP) - Hop count
 Open Shortest Path First (OSPF) - Cost based on cumulative
bandwidth from source to destination
 Enhanced Interior Gateway Routing Protocol (EIGRP) - Bandwidth,
delay, load, reliability
When a router has two or more paths to a destination with equal cost metrics,
then the router forwards the packets using both paths equally:
• Equal cost load balancing can improve network performance.
• Equal cost load balancing can be configured to use both dynamic routing
protocols and static routes.
• RIP, OSPF and EIGRP support equal cost load balancing.
If multiple paths to a destination are configured on a router, the path
installed in the routing table is the one with the lowest Administrative
Distance (AD):
• A static route with an AD of 1 is more reliable than an EIGRP-
discovered route with an AD of 90.
• A directly connected route with an AD of 0 is more reliable than a
static route with an AD of 1.
A routing table is a file stored in RAM that contains information about:
 Directly connected routes
 Remote routes
 Network or next hop associations
The show ip route command is used to display the
contents of the routing table:
• Local route interfaces - Added to the routing table
when an interface is configured. (displayed in IOS 15
or newer)
• Directly connected interfaces - Added to the routing
table when an interface is configured and active.
• Static routes - Added when a route is manually
configured and the exit interface is active.
• Dynamic routing protocol - Added when EIGRP or
OSPF are implemented and networks are identified.
Static routes and default static routes can be implemented after
directly connected interfaces are added to the routing table:
• Static routes are manually configured
• They define an explicit path between two networking devices.
• Static routes must be manually updated if the topology changes.
• Their benefits include improved security and control of resources.
• A default static route is used when the routing table does not contain
a path for a destination network.
• Configure a default static route using the command:

ip route {exit-intf | next-hop-ip}

Dynamic routing is used by routers to share information about the
reachability and status of remote networks.
• EIGRP – Enhanced Interior Gateway
Routing Protocol

• OSPF – Open Shortest Path First

• RIP – Routing Information Protocol

• RIPng - RIP next generation
• OSPFv3
• EIGRP for IPv6
• MP-BGP4 - Multicast Protocol-Border
Gateway Protocol
• Discovery of remote networks
• Maintaining up-to-date routing
• Choosing the best path to destination
• Ability to find a new best path if the
current path is no longer available
Advantages of dynamic routing include:

 Automatically share information about remote networks

 Determine the best path to each network and add this information
to their routing tables
 Compared to static routing, dynamic routing protocols require less
administrative overhead
 Help the network administrator manage the time-consuming
process of configuring and maintaining static routes

Disadvantages of dynamic routing include:

 Part of a router’s resources are dedicated for protocol operation,

including CPU time and network link bandwidth
 Times when static routing is more appropriate
Summarised, the operations of a dynamic routing
protocol can be described as follows:
1. The router sends and receives routing messages on
its interfaces.
2. The router shares routing messages and routing
information with other routers that are using the same
routing protocol.
3. Routers exchange routing information to learn about
remote networks.
4. When a router detects a topology change the routing
protocol can advertise this change to other routers.
The network is converged when all routers have complete and accurate
information about the entire network:

 Convergence time is the time it takes routers to share information, calculate

best paths, and update their routing tables.

 A network is not completely operable until the network has converged.

 Convergence properties include the speed of propagation of routing

information and the calculation of optimal paths. The speed of propagation
refers to the amount of time it takes for routers within the network to forward
routing information.

 Generally, older protocols, such as RIP, are slow to converge, whereas

modern protocols, such as EIGRP and OSPF, converge more quickly.
Interior Gateway
Protocols (IGP) -
 Used for routing
within an AS
 Include RIP, EIGRP,
Exterior Gateway
Protocols (EGP) -
 Used for routing
between AS
 Official routing
protocol used by the
• Distance vector protocols use routers as sign posts
along the path to the final destination.

• A link-state routing protocol is like having a complete

map of the network topology.
– The sign posts along the way from source to destination
are not necessary, because all link-state routers are using
an identical map of the network.
– A link-state router uses the link-state information to create
a topology map and to select the best path to all
destination networks in the topology.
Distance vector IPv4 IGPs:
 RIPv1 - First generation
legacy protocol
 RIPv2 - Simple distance
vector routing protocol
 IGRP - First generation
Cisco proprietary
protocol (obsolete)
 EIGRP - Advanced
version of distance
For R1, is one hop vector routing
away (distance). It can be reached
through R2 (vector).
Link-state IPv4
 OSPF - Popular
in the
• Classful routing protocols do not send subnet
mask information in their routing updates:
 Only RIPv1 and IGRP are classful.
 Created when network addresses were allocated
based on classes (class A, B, or C).
 Cannot provide variable length subnet masks
(VLSMs) and classless interdomain routing
 Create problems in discontiguous networks.
• Classless routing protocols include subnet
mask information in the routing updates:
 Support VLSM and CIDR
 IPv6 routing protocols
• A metric is a measurable value that is
assigned by the routing protocol to
different routes based on the usefulness of
that route:
 Used to determine the overall “cost” of a path
from source to destination.
 Routing protocols determine the best path
based on the route with the lowest cost.
• Distance vector routing protocols:
 Share updates between neighbors
 Not aware of the network topology
 Some send periodic updates to broadcast IP even if topology has not changed
 Updates consume bandwidth and network device
CPU resources
 RIPv2 and EIGRP use multicast addresses
 EIGRP will only send an update when topology has
 Similarly to RIPv1, RIPv2 automatically summarizes networks
at major network boundaries by default.
 To modify the default RIPv2 behavior of automatic
summarization, use the no auto-summary router
configuration mode command.
 This command has no effect when using RIPv1.
 When automatic summarization has been disabled, RIPv2 no
longer summarizes networks to their classful address at
boundary routers. RIPv2 now includes all subnets and their
appropriate masks in its routing updates.
• Each router learns about directly connected
• Each router sends “hellos” to directly
connected neighbours.
• Each router sends out a LSP containing the
state of all directly connected links to all
• Routers use the LSPs to build their map!
• Each router builds own topology map.
• Immediate flooding of LSPs=faster
• LSPs only sent when a change occurs.
• Only sends change.
• Hierarchical design.
• Additional memory.
• Additional CPU cycles for SPF algorithm.
• LSP flooding can cause bandwidth issues.
• Link State routing protocol
• Open standard
– Implemented by many vendors
• Supports only IP
• Uses cost as metric
• Uses Dijkstra SPF algorithm to determine
best route
• Hierarchical design that uses areas
• Forms neighbour relationships with adjacent
routers in the same area
• Advertises the status of directly connected links
• Updates are called Link State Advertisements
• Only sends changes outside of periodic 30
minute refresh updates
• Uses multicast addresses to communicate
routing protocol information
– – all OSPF Routers
– – Designated Routers
• Classless, supports VLSM
• AD of 110
• Builds 3 tables
– Neighbour, Topology, Routing
• Forms adjacencies with neighbours
– Exchanges hello packets on
– Only after adjacency is formed can routes be shared
• Each router identified by unique Router ID (RID)
– Can be manually specified
– If automatic highest IP on loopback interface is used
– If no loopback exists highest IP on physical interface
is used
• Hello packets sent out
– 10 sec for broadcast or p-2-p interfaces
– 30 sec for NBMA or p-2-mp interfaces
• Dead interval
– 40 sec for broadcast or p-2-p interfaces
– 120 sec for NBMA or p-2-mp interfaces
– By default is 4 x the hello interval
– Can be adjusted but not recommended normally
• To form a full neighbour relationship the following
parameters within the hello packet must match
– Area ID
– Area type
– Prefix
– Subnet Mask
– Hello & Dead interval timers
– Network type
– Authentication parameters if used
• Hello packets are basically keepalives and allow
the status of all neighbours to be known quickly
• Information is used to form the neighbour table
which contains
– RID of each neighbour
– Current state of each neighbour
– Interface directly connected to each neighbour
– IP address of remote interface on each neighbour
• In MA networks there can be many neighbours on
the same segment requiring n(n-1)/2 links for a
fully meshed network
• This creates a lot of LSA traffic
• To prevent this OSPF uses the concept of
designated routers (DR) and backup designated
routers (BDR)
• DR & BDR are “elected”
– Determined by a priority which can be manually set
• Neighbour adjacencies pass through various states :
– Down – No hellos have been heard from neighbours
– Init – Hello received by 2-way comm’s not up
– 2-Way – 2-way comm’s up, DR/BDR are elected now
– ExStart – Neighbours preparing to share information
– Exchange – Routers sharing Database Descriptors (DBD)
– Loading – Neighbours exchanging routes (LSAs)
– Full – Neighbours are fully synchronized
• Full state has some sub-states :
– Full/DR – indicates neighbour is a DR
– FULL/BDR – indicates neighbour is a BDR
– Full/DROther – indicates neighbour is neither
• On multi-access networks OSPF will only form full
adjacencies with DR/BDR routers
• Non-DR/BDR adjacencies will form but remain in
2-Way state
• Broadcast Multi-Access
– Broadcast traffic occurs
– Ethernet, ATM, Token Ring
– OSPF will elect DR/BDR
– Uses multicast traffic &
– No need to manually configured neighbours
• Point to Point
– Where routers are directed connected
– OSPF will not elect DR/BDR
– All traffic to
– No need to manually configured neighbours
• Point to Multipoint
– Where one interface connects to multiple
– P-to-MP Frame Relay
– OSPF will not elect DR/BDR
– All traffic to
– No need to manually configured neighbours
• Non-Broadcast Multi-Access (NBMA)
– Where one interface connects to multiple
routers but broadcasts cannot be sent
– Frame Relay
– OSPF will elect DR/BDR
– Must manually configure neighbours so all
OSPF traffic is unicast as multicast is not
• OSPF is hierarchical and makes use of areas
• OSPF traffic can be intra-area, inter-area or
• OSPF routers build a topology database of all links
within their specified area
• All OSPF routers within an area will have an
identical topology database
• Router updates contain only information about
links local to the area
• Area 0 is mandatory
– Considered the “backbone” or “transit” area
• All other areas must have a connection to Area 0
– Virtual links are an exception!
• OSPF routers can belong to multiple areas
– Will maintain a separate topology database for each
– Known as an Area Border Router (ABR)
• If one of the areas is external to OSPF the router
will be considered an Autonomous System Border
Router (ASBR)
– ASBRs provide access to external networks
• Internet
• Other routing protocol domains
• OSPF defines two types of external networks
• Type 1 (E1)
– Includes both the external cost, and the internal
cost to reach the ASBR, to determine the total
metric to reach the destination network
– Type 1 routes are always preferred over Type 2
routes to the same destination
• Type 2 (E2)
– Includes only the external cost to the
destination network. External cost is the
metric being advertised from outside the
OSPF domain.
– This is the default type assigned to external
• Four types of OSPF Routers
– Internal – interfaces all belong to one area
– ABR – contains interfaces in at least two
different areas
– Backbone – contain at least one interface in
Area 0
– ASBR – contain a connection to an external
• As a LS routing protocol OSPF keeps
track of link statuses and forwards updates
using Link State Advertisements (LSA)
• LSA information makes up the topology
• Several types of typical LSA
– Router LSA (Type 1)
– Network LSA (Type 2)
– Network Summary LSA (Type 3)
– ASBR Summary LSA (Type 4)
– External LSA (Type 5)
• Each type of LSA is sent at 3 times
– When adjacencies are formed
– When a change in the topology occurs
– When an LSA reaches its maximum age (30
• OSPF does send refresh updates every 30
• Cost metric based on the speed of an
– Lowest cost is preferred
– Cost can be set manually
• Allows Areas to exist without touching Area 0

• Also useful for connecting two Area 0s!

• Components of the IPv6 routing table are
very similar to the IPv4 routing table
(directly connected interfaces, static
routes, and dynamically learned routes).
• IPv6 is classless by design, all routes are
effectively level 1 ultimate routes. There is
no level 1 parent of level 2 child routes.
• In the past:
– Actual routers were used to route between VLANs.
– Each VLAN was connected to a different physical router
– Packets would arrive on the router through one through
interface, be routed and leave through another.
– Because the router interfaces were connected to VLANs
and had IP addresses from that specific VLAN, routing
between VLANs was achieved.
– Large networks with large number of VLANs required
many router interfaces.
• The router-on-a-stick approach uses a different path to route
between VLANs.
• One of the router’s physical interfaces is configured as a
802.1Q trunk port so it can understand VLAN tags.
• Logical subinterfaces are created; one subinterface per
• Each subinterface is configured with an IP address from the
VLAN it represents.
• VLAN members (hosts) are configured to use the subinterface
address as a default gateway.
• Only one of the router’s physical interface is used.
• Multilayer switches can perform Layer 2 and Layer 3 functions, replacing
the need for dedicated routers.
• Multilayer switches support dynamic routing and inter-VLAN routing.
• The multilayer switch must have IP routing enabled.
• A switch virtual interface (SVI) exists for VLAN 1 by default. On a multilayer
switch, a logical (layer 3) interface can be configured for any VLAN.
• The switch understands network-layer PDUs; therefore, can route between
its SVIs, just as a router routes between its interfaces.
• With a multilayer switch, traffic is routed internal to the switch device.
• This routing process is a suitable and scalable solution.
• WAN Technologies
– Describe WAN topology options
– Describe WAN access connectivity options
– Describe basic QoS concepts

• Infrastructure Services
– Describe DNS lookup operation
– Troubleshoot client connectivity issues involving DNS
– Configure and verify DHCP on a router (excluding static reservations)
– Troubleshoot client- and router-based DHCP connectivity issues
– Configure, verify, and troubleshoot basic HSRP
– Configure, verify, and troubleshoot inside source NAT
– Configure and verify NTP operating in a client/server mode