100% found this document useful (1 vote)
164 views45 pages

Routing Protocols: Dalya A.Alrahim Aljubori

Routing protocols allow routers to exchange information about networks and choose the best paths to send packets between subnets. Dynamic routing protocols automatically update routing tables when network changes occur, while static routing requires manual configuration. Common dynamic routing protocols include distance vector protocols like RIP that share next hop and metric information, and link-state protocols like OSPF that build a full network map.

Uploaded by

Fatima
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
164 views45 pages

Routing Protocols: Dalya A.Alrahim Aljubori

Routing protocols allow routers to exchange information about networks and choose the best paths to send packets between subnets. Dynamic routing protocols automatically update routing tables when network changes occur, while static routing requires manual configuration. Common dynamic routing protocols include distance vector protocols like RIP that share next hop and metric information, and link-state protocols like OSPF that build a full network map.

Uploaded by

Fatima
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 45

Routing Protocols

Dalya A.Alrahim Aljubori


Table of content
1-Routing Table
2- Types of routing:
-Static routing
-Dynamic routing
3-Routing protocol
4-Dynamic Routing Protocols types
5-Classifying Routing Protocols
6-Distance Vector Routing Protocols
7-Routing Protocol Metrics
8-Routing Information Protocol (RIP)
9-Differences between RIPv1 or RIPv2
10-Routing Protocol Characteristics
11-Administrative Distance
12-Selecting the Best Route
13-Route Summarization
Routing Table

Routing is the process your computer uses to transmit a


packet between different subnets. If you want to
communicate with a computer on a different subnet from
your own, your computer must forward the data packets to
a router. A router is the software and hardware responsible
for delivering packets between two subnets. Each router
uses an internal routing table to determine the best path to
send a packet.
• A routing table is a set of rules, often viewed in table format, that is
used to determine where data packets traveling over an Internet
Protocol (IP) network will be directed. All IP-enabled devices,
including routers and switches, use routing tables.

• A routing table contains the information necessary to forward a


packet along the best path toward its destination. Each packet
contains information about its origin and destination. When a packet
is received, a network device examines the packet and matches it to
the routing table entry providing the best match for its destination.
The table then provides the device with instructions for sending the
packet to the next hop on its route across the network.
A basic routing table includes the following information:

Destination: The IP address of the packet's final destination

Next hop: The IP address to which the packet is forwarded

Interface: The outgoing network interface the device should use when forwarding
the packet to the next hop or final destination

Metric: Assigns a cost to each available route so that the most cost-effective path
can be chosen

Routes: Includes directly-attached subnets, indirect subnets that are not attached to
the device but can be accessed through one or more hops, and default routes to use
for certain types of traffic or when information is lacking.
Viewing the Routing Tables

If you want to see the routing tables, you will have to open a
Command Prompt window and then enter the ROUTE PRINT
command. Upon doing so, you will see a screen similar to the
one that’s shown in Figure A.
Two main types of routing:
1-Static routing
2-Dynamic routing

Routing tables can be maintained manually or


dynamically. Tables for static network devices do not
change unless a network administrator manually
changes them. In dynamic routing, devices build and
maintain their routing tables automatically by using
routing protocols to exchange information about the
surrounding network topology. Dynamic routing tables
allow devices to "listen" to the network and respond to
occurrences like device failures and network congestion.
Static Routing
The term static routing denotes the use of manually configured or
injected static routes for traffic forwarding purposes. Using a static
route might be appropriate in the following circumstances:

1- When it is undesirable to have dynamic routing updates forwarded


across slow bandwidth links, such as a dialup link
2-When the administrator needs total control over the routes used by
the router
3-When a backup to a dynamically learned route is necessary
4-When it is necessary to reach a network that is accessible by only
one path (a stub network)

Configuring and maintaining static routes is time-consuming.


Properly implementing static routes requires complete knowledge of
the entire network.
Dynamic Routing
Dynamic routing allows the network to adjust to changes in the
topology automatically, without administrator involvement. A static
route cannot dynamically respond to changes in the network.
If a link fails, the static route is no longer valid if it is configured to
use that failed link, so a new static route must be configured. If a
new router or new link is added, that information must also be
configured on every router in the network. In a very large or unstable
network, these changes can lead to considerable work for network
administrators. It can also take a long time for every router
in the network to receive the correct information. In situations such
as these, it might be better to have the routers receive information
about networks and links from each other using a dynamic
routing protocol. Dynamic routing protocols must do the following:
• Find sources from which routing information can be received
(usually neighboring routers)
• Select the best paths toward all reachable destinations, based on
received information
• Maintain this routing information
• Have a means of verifying routing information (periodic updates or
refreshes)

When using a dynamic routing protocol, the administrator configures


the routing protocol on each router. The routers then exchange
information about the reachable networks and the state of each
network. Routers exchange information only with other routers
running the same routing protocol. When the network topology
changes, the new information is dynamically propagated throughout
the network, and each router updates its routing table to reflect the
changes.
Routing protocol

A routing protocol specifies how routers communicate with each


other, disseminating information that enables them to select routes
between any two nodes on a computer network. Routing algorithms
determine the specific choice of route. Each router has a priori
knowledge only of networks attached to it directly. A routing protocol
shares this information first among immediate neighbors, and then
throughout the network. This way, routers gain knowledge of the
topology of the network.
The router learns about remote networks from neighbor routers or
from an administrator. The router then builds a routing table. If the
network is directly connected then the router already knows how to
get to the network. If the networks are not attached, the router must
learn how to get to the remote network with either static routing
(administrator manually enters the routes in the router's table) or
dynamic routing (happens automatically using routing protocols like
EIGRP,OSPF,etc.).
The routers then update each other about all the networks they
know. If a change occurs a router goes down, the dynamic routing
protocols automatically inform all routers about the change. If static
routing is used, then the administrator has to update all changes
into all routers and therefore no routing protocol is used.
Only Dynamic routing uses routing
protocols, which enable routers to:

• Dynamically discover and maintain routes


• Calculate routes
• Distribute routing updates to other routers
• Reach agreement with other routers about
the network topology
Dynamic Routing Protocols types

There are 3 types of Dynamic routing protocols, these are


differ by the way that discover and make calculations
about routes;

1. Distance Vector
2. Link State
3. Hybrid

Distance Vector routers find the best path from


information send from neighbors

Link State routers each have a copy of the entire network


map

Link State routers find best routes from this local map
The Table below shows the main characteristics of a few different
types of dynamic routing protocols:
• You can also classify the routing protocols
in terms of their location on a network. For
example, routing protocols can exist in, or
between, autonomous systems.
Classifying Routing Protocols
Routing protocols can be classified into different groups according to their
characteristics. Specifically, routing protocols can be classified by their:

• Purpose: Interior Gateway Protocol (IGP) or Exterior Gateway Protocol (EGP)


• Operation: Distance vector protocol, link-state protocol, or path-vector protocol
• Behavior: Classful (legacy) or classless protocol

For example, IPv4 routing protocols are classified as follows:

RIPv1 (legacy): IGP, distance vector, classful protocol


IGRP (legacy): IGP, distance vector, classful protocol developed by Cisco
(deprecated from 12.2 IOS and later)
RIPv2: IGP, distance vector, classless protocol
EIGRP: IGP, distance vector, classless protocol developed by Cisco
OSPF: IGP, link-state, classless protocol
IS-IS: IGP, link-state, classless protocol
BGP: EGP, path-vector, classless protocol
• The classful routing protocols, RIPv1 and IGRP, are
legacy protocols and are only used in older networks.
These routing protocols have evolved into the classless
routing protocols, RIPv2 and EIGRP, respectively. Link-
state routing protocols are classless by nature.
A hierarchical view of dynamic routing
protocol classification:
Distance Vector Routing Protocols
Distance vector means that routes are advertised by providing two
characteristics:

• Distance: Identifies how far it is to the destination network and is


based on a metric such as the hop count, cost, bandwidth, delay,
and more
• Vector: Specifies the direction of the next-hop router or exit interface
to reach the destination

A router using a distance vector routing protocol does not have the
knowledge of the entire path to a destination network. Distance
vector protocols use routers as sign posts along the path to the final
destination. The only information a router knows about a remote
network is the distance or metric to reach that network and which
path or interface to use to get there. Distance vector routing
protocols do not have an actual map of the network topology.
In a distance vector protocol, routing decisions
are made on a hopby-hop basis. Each router
relies on its neighbor routers to make the correct
routing decisions.The router passes only the
results of this decision (its routing table) to its
neighbors. Distance vector protocols are
typically slower to converge and do not scale
well; however, they are easy to implement and
maintain. Examples of distance vector protocols
include RIPv1, RIPv2, and Interior Gateway
Routing Protocol (IGRP).
For example, in the figure , R1 knows that the distance to reach
network 172.16.3.0/24 is one hop and that the direction is out of the
interface Serial 0/0/0 toward R2.
There are four distance vector IPv4 IGPs:

• RIPv1: First generation legacy protocol


• RIPv2: Simple distance vector routing protocol
• IGRP: First generation Cisco proprietary protocol
(obsolete and replaced by EIGRP)
• EIGRP: Advanced version of distance vector routing
Routing Protocol Metrics
There are cases when a routing protocol learns of more than one
route to the same destination. To select the best path, the routing
protocol must be able to evaluate and differentiate between the
available paths. This is accomplished through the use of routing
metrics.

A metric is a measurable value that is assigned by the routing


protocol to different routes based on the usefulness of that route. In
situations where there are multiple paths to the same remote
network, the routing metrics are 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.

Different routing protocols use different metrics. The metric used by


one routing protocol is not comparable to the metric used by another
routing protocol. Two different routing protocols might choose
different paths to the same destination.
If a routing protocol recognizes more than
one way to reach a network, it compares
the metric for each different path and
chooses the path with the lowest metric. If
multiple paths have the same metric, a
maximum of 16 can be installed in the
routing table (the maximum number of
parallel routes), and the router can
perform load balancing among them.
For example, assume that PC1 wants to send a packet to PC2. In the Figure,
the RIP routing protocol has been enabled on all routers and the network has
converged. RIP makes a routing protocol decision based on the least number
of hops. Therefore, when the packet arrives on R1, the best route to reach the
PC2 network would be to send it directly to R2 even though the link is much
slower that all other links.
In the Figure, the OSPF routing protocol has been enabled on all routers
and the network has converged. OSPF makes a routing protocol decision
based on the best bandwidth. Therefore, when the packet arrives on R1, the
best route to reach the PC2 network would be to send it to R3, which would
then forward it to R2.
Routing Information Protocol (RIP)
Is a standards-based, distance-vector, interior gateway protocol
(IGP) used by routers to exchange routing information. RIP uses
hop count to determine the best path between two locations. Hop
count is the number of routers the packet must go through till it
reaches the destination network. The maximum allowable number of
hops a packet can traverse in an IP network implementing RIP is 15
hops.
it has a maximum allowable hop count of 15 by default, meaning
that 16 is deemed unreachable. RIP works well in small networks,
but it's inefficient on large networks with slow WAN links or on
networks with a large number of routers installed.
In a RIP network, each router broadcasts its entire RIP table to its
neighboring routers every 30 seconds. When a router receives a
neighbor's RIP table, it uses the information provided to update its
own routing table and then sends the updated table to its neighbors.
RIP

is one of the oldest distance-vector routing protocols which employ


the hop count as a routing metric. RIP prevents routing loops by
implementing a limit on the number of hops allowed in a path from
source to destination. The maximum number of hops allowed for
RIP is 15, which limits the size of networks that RIP can support. A
hop count of 16 is considered an infinite distance and the route is
considered unreachable.
In most networking environments, RIP is not the preferred choice for
routing as its time to converge and scalability are poor compared to
EIGRP, OSPF, or IS-IS. However, it is easy to configure, because
RIP does not require any parameters unlike other protocols.

RIP uses the User Datagram Protocol (UDP) as its transport


protocol, and is assigned the reserved port number 520.
Versions

There are three versions of the Routing Information


Protocol: RIPv1, RIPv2, and RIPng.

RIP version 1

The original specification of RIP, defined in RFC 1058, was


published in 1988 and uses classful routing. The periodic routing
updates do not carry subnet information, lacking support for variable
length subnet masks (VLSM). This limitation makes it impossible to
have different-sized subnets inside of the same network class. In
other words, all subnets in a network class must have the same
size. There is also no support for router authentication, making RIP
vulnerable to various attacks.
RIP version 2

• Due to the deficiencies of the original RIP specification, RIP version 2


(RIPv2) was developed in 1993,and last standardized in 1998. It included
the ability to carry subnet information, thus supporting Classless Inter-
Domain Routing (CIDR). To maintain backward compatibility, the hop count
limit of 15 remained.

• (MD5) authentication for RIP was introduced in 1997.


MD5 stands for Message Digest algorithm 5

• Route tags were also added in RIP version 2. This functionality allows a
distinction between routes learned from the RIP protocol and routes learned
from other protocols.
RIPng

RIPng (RIP next generation), defined in RFC 2080,is an extension


of RIPv2 for support of IPv6, the next generation Internet Protocol.
The main differences between RIPv2 and RIPng are:
• Support of IPv6 networking.
• While RIPv2 supports RIPv1 updates authentication, RIPng does
not. IPv6 routers were, at the time, supposed to use IPsec for
authentication.
Internet Protocol Security (IPsec) is a protocol suite for secure
Internet Protocol (IP) communications by authenticating and
encrypting each IP packet of a communication session.
• RIPv2 encodes the next-hop into each route entry, RIPng requires
specific encoding of the next hop for a set of route entries.
• RIPng sends updates on UDP port 521 using the multicast group
FF02::9.
Differences between RIPv1 or RIPv2

RIPv1

This is a simple distance vector protocol. It has been enhanced with


various techniques, including Split Horizon and Poison Reverse in
order to enable it to perform better in somewhat complicated
networks.

A classful protocol, broadcasts updates every 30


seconds, hold-down period 180 seconds. Hop count is
metric (Maximum 15).
RIPv2
This version added several new features.
• RIPv2 uses multicasts, version 1 use broadcasts,
• RIPv2 supports triggered updates—when a change
occurs, a RIPv2 router will immediately propagate its
routing information to its connected neighbors.
• RIPv2 is a classless protocol. RIPv2 supports variable-
length subnet masking (VLSM)
• RIPv2 supports authentication. You can restrict what
routers you want to participate in RIPv2. This is
accomplished using a hashed password value.
RIP uses four different kinds of timers to regulate its
performance:

• Route update timer


Sets the interval (typically 30 seconds) between periodic
routing updates in which the router sends a complete
copy of its routing table out to all neighbors.
• Route invalid timer
Determines the length of time that must elapse (180
seconds) before a router determines that a route has
become invalid. It will come to this conclusion if it hasn’t
heard any updates about a particular route for that
period. When that happens, the router will send out
updates to all its neighbors letting them know that the
route is invalid.
• Holddown timer
This sets the amount of time during which routing information is
suppressed. Routes will enter into the holddown state when an
update packet is received that indicated the route is unreachable.
This continues either until an update packet is received with a better
metric or until the holddown timer expires. The default is 180
seconds.
The hold-down timer is started per route entry, when the hop count
is changing from lower value to higher value. This allows the route
to get stabilized. During this time no update can be done to that
routing entry.
• Route flush timer
The flush timer controls the time between the route is invalidated or
marked as unreachable and removal of entry from the routing table.
By default the value is 240 seconds. This is 60 seconds longer than
Invalid timer. So for 60 seconds the router will be advertising about
this unreachable route to all its neighbours. This timer must be set
to a higher value than the invalid timer.
Routing Protocol Characteristics

Routing protocols can be compared based


on the following characteristics:
• Speed of convergence: Speed of convergence defines how quickly
the routers in the network topology share routing information and
reach a state of consistent knowledge. The faster the convergence,
the more preferable the protocol. Routing loops can occur when
inconsistent routing tables are not updated due to slow convergence
in a changing network.
• Scalability: Scalability defines how large a network can become,
based on the routing protocol that is deployed. The larger the
network is, the more scalable the routing protocol needs to be.
• Classful or classless (use of VLSM): Classful routing protocols do
not include the subnet mask and cannot support variable-length
subnet mask (VLSM). Classless routing protocols include the subnet
mask in the updates. Classless routing protocols support VLSM and
better route summarization.
• Resource usage: Resource usage includes the requirements of a
routing protocol such as memory space (RAM), CPU utilization, and
link bandwidth utilization. Higher resource requirements necessitate
more powerful hardware to support the routing protocol operation, in
addition to the packet forwarding processes.

• Implementation and maintenance: Implementation and maintenance


describes the level of knowledge that is required for a network
administrator to implement and maintain the network based on the
routing protocol deployed.

Routing protocols vary in their support for many features, including


VLSM, summarization, scalability, and fast convergence. There is
no best protocol—the choice depends on many factors.
Comparing Routing Protocols
Administrative Distance

Most routing protocols have metric structures and algorithms that


are incompatible with other protocols. It is critical that a network
using multiple routing protocols be able to seamlessly
exchange route information and be able to select the best path
across multiple protocols. Cisco routers use a value called
administrative distance to select the best path when they learn of
two or more routes to the same destination from different routing
protocols.
Administrative distance rates a routing protocol’s believability. Cisco
has assigned a default administrative distance value to each routing
protocol supported on its routers. Each routing protocol is prioritized
in order, from most to least believable.

Administrative distance is a value between 0 and 255. The lower the


administrative distance value, the higher the protocol’s believability.
Administrative Distance of Routing Protocols
Selecting the Best Route

Cisco routers use the following two parameters to select the best
path when they learn two or more routes to the same destination
from different routing protocols:

1- Administrative distance: The administrative distance is used to


rate a routing protocol’s believability. This criterion is the first thing a
router uses to determine which routing protocol to believe if more
than one protocol provides route information for the same
destination.

2- Routing metric: The routing metric is a value representing the path


between the local router and the destination network, according to
the routing protocol being used. This metric is used to determine the
routing protocol’s “best” path to the destination.
Route Summarization

Route summarization (which is also called route aggregation or


supernetting). In route summarization, a single summary address in
the routing table represents a set of routes.Summarization reduces
the routing update traffic, the number of routes in the routing table,
and the overall router overhead in the router receiving the routes.
The Benefits of Route Summarization

A large flat network is not scalable because routing traffic consumes


considerable network resources. When a network change occurs, it is
propagated throughout the network, which requires processing time for
route recomputation and bandwidth to propagate routing updates.

A network hierarchy can reduce both routing traffic and unnecessary


route recomputation. To accomplish this, the network must be divided
into areas that enable route summarization. With summarization in
place, a route flap (a route that goes down and up continuously) that
occurs in one network area does not influence routing in other areas.
Instabilities are isolated and convergence is improved, thereby reducing
the amount of routing traffic, the size of the routing tables, and the
required memory and processing power for routing. Summarization is
configured manually, or occurs automatically at the major network
boundary in some routing protocols.

You might also like