0% found this document useful (0 votes)
19 views54 pages

Data and Computer Communications: Tenth Edition by William Stallings

data and computer communications by william stallings 10th edition chapter 19

Uploaded by

everna44
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views54 pages

Data and Computer Communications: Tenth Edition by William Stallings

data and computer communications by william stallings 10th edition chapter 19

Uploaded by

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

Data and Computer

Communications

Tenth Edition
by William Stallings

Data and Computer Communications, Tenth


Edition by William Stallings, (c) Pearson
Education - 2013
CHAPTER 19

Routing
Routing in Switched Data Networks
"I tell you," went on Syme with passion, "that every
time a train comes in I feel that it has broken past
batteries of besiegers, and that man has won a battle
against chaos. You say contemptuously that when one
has left Sloane Square one must come to Victoria. I
say that one might do a thousand things instead, and
that whenever I really come there I have the sense of
hairbreadth escape. And when I hear the guard shout
out the word 'Victoria', it is not an unmeaning word.
It is to me the cry of a herald announcing conquest. It
is to me indeed 'Victoria'; it is the victory of Adam."
—The Man Who Was Thursday,
G.K. Chesterton
Routing in Packet Switching
Networks
 Key design issue for (packet) switched networks
 Select route across network between end nodes
 Characteristics required:

Correctness

Simplicity

Robustness

Stability

Fairness

Optimality

Efficiency
Table 19.1
Elements of Routing Techniques
for Packet-Switching Networks
Performance Criteria
 Used for selection of route
 Simplest is to choose “minimum hop”
 Can be generalized as “least cost” routing
 Because “least cost” is more flexible it is
more common than “minimum hop”
Decision Time and Place
Decision time
• Packet or virtual circuit basis
• Fixed or dynamically changing

Decision place
• Distributed - made by each node
• More complex, but more robust
• Centralized – made by a designated node
• Source – made by source station
Network Information Source
and Update Timing
 Routing decisions usually based on knowledge
of network, traffic load, and link cost

Distributed routing
• Using local knowledge, information from adjacent nodes,
information from all nodes on a potential route

Central routing
• Collect information from all nodes

Issue of update timing


• Depends on routing strategy
• Fixed - never updated
• Adaptive - regular updates
Routing Strategies - Fixed
Routing
 Use a single permanent route for each
source to destination pair of nodes
 Determined using a least cost algorithm
 Route is fixed

Until a change in network topology

Based on expected traffic or capacity
 Advantage is simplicity
 Disadvantage is lack of flexibility

Does not react to network failure or congestion
Routing Strategies - Flooding
 Packet sent by node to every neighbor
 Eventually multiple copies arrive at destination
 No network information required
 Each packet is uniquely numbered so duplicates
can be discarded
 Need to limit incessant retransmission of
packets

Nodes can remember identity of packets
retransmitted

Can include a hop count in packets
Properties of Flooding
Can be used
All possible Highly to send
routes are tried robust emergency
messages

At least one packet


will have taken
minimum hop
route

Nodes directly or
indirectly
connected to
source are visited

High traffic
Security
Disadvantages: load
concerns
generated
Routing Strategies - Random
Routing
 Simplicity of flooding with much less traffic load
 Node selects one outgoing path for
retransmission of incoming packet
 Selection can be random or round robin
 Arefinement is to select outgoing path based on
probability calculation
 No network information needed
 Random route is typically neither least cost nor
minimum hop
Routing Strategies - Adaptive
Routing
 Used by almost all packet switching networks
 Routing decisions change as conditions on the
network change due to failure or congestion
 Requires information about network
Disadvantages: Decisions more complex

Tradeoff between quality of network information and


overhead
Reacting too quickly can cause oscillation

Reacting too slowly means information may be irrelevant


Adaptive Routing Advantages

Improved
performance

Aid in congestion
control

These benefits
depend on the
soundness of the
design and nature of
the load
• Like
adjacent
All nodes
• Takes
advantag
e of
delay
• Route
and to
outgoing
outage

nodes
link with
informati
shortest
on
queue

Adjacent
• Distribut
• Can
ed or
include
centraliz
bias for
ed
each
(isolated)
destinati
on
Local
• Rarely
used -
does not
make use
of information source
of
available
informati
way to classify is on the basis
 A convenient
on
Routing Strategies
Classification of Adaptive
ARPANET Routing Strategies
1st Generation
Distance Vector Routing
 1969
 Distributed adaptive using estimated delay

Queue length used as estimate of delay
 Version of Bellman-Ford algorithm
 Node exchanges delay vector with neighbors
 Update routing table based on incoming
information
 Doesn't consider line speed, just queue length
and responds slowly to congestion
ARPANET Routing Strategies
2nd Generation
Link-State Routing
 1979
 Distributed adaptive using delay criterion

Using timestamps of arrival, departure and ACK times
 Re-computes average delays every 10 seconds
 Any changes are flooded to all other nodes
 Re-computes routing using Dijkstra’s algorithm
 Good under light and medium loads
 Under heavy loads, little correlation between
reported delays and those experienced
ARPANET Routing Strategies
3rd Generation
 1987
 Link cost calculation changed

Damp routing oscillations

Reduce routing overhead
 Measure average delay over last 10 seconds
and transform into link utilization estimate
 Normalize this based on current value and
previous results
 Set link cost as function of average utilization
Internet Routing Protocols
 Routers are responsible for receiving and
forwarding packets through the interconnected set
of networks

Makes routing decisions based on knowledge of the
topology and traffic/delay conditions of the internet

Routers exchange routing information using a special
routing protocol
 Two concepts in considering the routing function:

Routing information
 Information about the topology and delays of the internet

Routing algorithm
 The algorithm used to make a routing decision for a particular datagram,
based on current routing information
Autonomous Systems (AS)
 Exhibits the following characteristics:

Is a set of routers and networks managed by
a single organization

Consists of a group of routers exchanging
information via a common routing protocol

Except in times of failure, is connected (in a
graph-theoretic sense); there is a path
between any pair of nodes
Interior Router Protocol
(IRP)
 A shared routing protocol which passes
routing information between routers within
an AS
 Custom tailored to specific applications
and requirements
Exterior Router Protocol
(ERP)
 Protocol used to pass routing information between routers
in different ASs
 Will need to pass less information than an IRP for the
following reason:

If a datagram is to be transferred from a host in one AS to a host
in another AS, a router in the first system need only determine
the target AS and devise a route to get into that target system

Once the datagram enters the target AS, the routers within that
system can cooperate to deliver the datagram

The ERP is not concerned with, and does not know about, the
details of the route
Examples

• Border Gateway Protocol (BGP)


• Open Shortest Path First (OSPF)
Approaches to Routing

 Internetrouting protocols employ one of


three approaches to gathering and using
routing information:
Distance-vector routing

Path-vector routing

Link-state routing
Distance-Vector Routing
 Requires that each node exchange information with
its neighboring nodes

Two nodes are said to be neighbors if they are both
directly connected to the same network
 Used in the first-generation routing algorithm for
ARPANET
 Each node maintains a vector of link costs for each
directly attached network and distance and next-hop
vectors for each destination
 Routing Information Protocol (RIP) uses this
approach
Link-State Routing
 Designed to overcome the drawbacks of distance-vector
routing
 When a router is initialized, it determines the link cost on
each of its network interfaces
 The router then advertises this set of link costs to all other
routers in the internet topology, not just neighboring routers
 From then on, the router monitors its link costs
 Whenever there is a significant change the router again
advertises its set of link costs to all other routers in the
configuration
 The OSPF protocol is an example
 The second-generation routing algorithm for ARPANET also
uses this approach
Path-Vector Routing
 Alternative to dispense with routing metrics and
simply provide information about which networks can
be reached by a given router and the ASsvisited in
order to reach the destination network by this route

 Differs from a distance-vector algorithm in two


respects:

The path-vector approach does not include a distance or
cost estimate

Each block of routing information lists all of the ASs
visited in order to reach the destination network by this
route
Border Gateway Protocol
(BGP)
 Was developed for use in conjunction with internets that
employ the TCP/IP suite
 Has become the preferred exterior router protocol for the
Internet
 Designed to allow routers in different autonomous systems
to cooperate in the exchange of routing information
 Protocol operates in terms of messages, which are sent
over TCP connections
 Current version is known as BGP-4 (RFC 4271)
Three functional procedures:
Neighbor acquisition
Neighbor reachability
Network reachability
Table 19.2
BGP-4 Messages
Neighbor Acquisition
 Occurs when two neighboring routers in different
autonomous systems agree to exchange routing
information regularly
 Two routers send Open messages to each other after a
TCP connection is established

If each router accepts the request, it returns a Keepalive
message in response
 Protocol does not address the issue of how one router
knows the address or even the existence of another
router nor how it decides that it needs to
exchange routing information with that
particular router
Open Shortest Path First
(OSPF) Protocol
 RFC 2328
 Used as the interior router protocol in
TCP/IP networks
 Computes a route through the internet that
incurs the least cost based on a user-
configurable metric of cost
 Is able to equalize loads over multiple
equal-cost paths
Table 19.3

Routing
Table for R6
Dijkstra’s Algorithm
 Finds shortest paths from given source
nodesto all other nodes
 Develop paths in order of increasing path
length
 Algorithm runs in stages

Each time adding node with next shortest
path
 Algorithmterminates when all nodes have been
added to T
Dijkstra’s Algorithm Method

Step 1 [Initialization]
T = {s} Set of nodes so far Initial path costs to neighboring
L(n) = w(s, n) for n ≠ s
incorporated nodes are simply link costs

Step 2 [Get Next Node]


Also incorporate the edge that is
Find neighboring node not in T
Incorporate node into T incident on that node and a node
with least-cost path from s
in T that contributes to the path

Step 3 [Update Least-Cost Paths]


If latter term is minimum, path from s to n is path
L(n) = min[L(n), L(x) + w(x, n)] for all n Ï T from s to x concatenated with edge from x to n
Table 19.4(a)

Example of Least-Cost Routing


Algorithms
(using Figure 19.1)

Dijkstra'a Algorithm (s = 1)
Bellman-Ford Algorithm
 Find shortest paths from given node
subject to constraint that paths contain at
most one link
 Findthe shortest paths with a constraint of
paths of at most two links
 Proceeds in stages
Bellman-Ford Algorithm

Step 2 [Update]
For each successive h  0
For each n ≠ s, compute:
Lh+1(n)=minj[Lh(j)+w(j,n)]
Step1 [Initialization] Connect n with predecessor
L0(n) = , for all n  s node j that gives min
Lh(s) = 0, for all h Eliminate any connection of n
with different predecessor node
formed during an earlier
iteration
Path from s to n terminates with
link from j to n
Table 19.4(b)

Example of Least-Cost
Routing Algorithms
(using Figure 19.1)

Bellman-Ford Algorithm (s = 1)
Comparison
 Bellman-Ford

Calculation for node n
needs link cost to  Dijkstra
neighboring nodes plus 
Each node needs
total cost to each complete topology
neighbor from s 
Must know link costs

Each node can maintain of all links in network
set of costs and paths for 
Must exchange
every other node information with all

Can exchange other nodes
information with direct
neighbors

Can update costs and
paths based on
information from
neighbors and knowledge
of link costs
Dependent on
Evaluation
• Processing
time of
algorithms Implementation
• Amount of specific
information
required from
other nodes
Both converge
under static
topology and
costs

If link costs
change,
Both converge
algorithms
to same solution
attempt to catch
If link costs up
depend on
traffic, which
Summary
 Internet routing
 Routing in packet-
switching networks protocols

Autonomous systems

Characteristics

Approaches to routing

Routing strategies


Border gateway
Examples: Routing in protocol
ARPANET 
OSPF protocol

First generation: 
Distance Vector
Least-cost algorithms
Routing

Dijkstra’s algorithm

Second generation:

Bellman-Ford
Link-State Routing algorithm

Third generation

Comparison

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy