2. Presented By
HELLO Everyone
Nayeem Hasan
2013-1-60-066
Nasif Ahmed
2013-1-60-052
MD.Moniruzzaman khondaker
2012-2-60-056
3. Introduction
For a real time communication with low cost, higher efficiency
and less complexity; routing protocols become one of the most
important decisions in the design of wireless networks.
The primary purpose of our topic is to compare two dynamic
routing algorithms. Besides, we represent an overview of these
algorithms distinguish similarities and differences and surveys
these algorithms, and analysis the results.
we will discuss two adaptive routing algorithms: Link state
algorithm (LSA), which is centralized algorithm and Distance
vector algorithm (DVA), which is distributed algorithm.
4. Introduction
Distance vector routing is a simple routing protocol used in
packet-switched networks that utilizes distance to decide the
best packet forwarding path. Distance is typically represented by
the hop count.
A routing protocol is a set of rules used by routers to determine
the most appropriate paths into which they should forward
packets towards their intended destinations.
TCP/IP is the protocol which is mostly used to send packet from
source to destination.
5. Introduction
Link-state routing protocol is one of the used routing protocols
used in packet switching networks for computer
communications.
The link-state protocol is performed by every switching node in
the network these nodes are called Routers.
6. Introduction
The comparison table of distance vector protocols with link state
protocol shows that distance vector protocols have frequently
periodic updates, low utilization of CPU and memory and has
high simplicity whereas the link state protocols have intensive
utilization of CPU and memory with a high complexity which
requires a well trained administrator to be handled.
7. Distance
Vector Routing
oDistance vector routing algorithm is one of the adoptive routing
algorithm.
o The adoptive routing algorithm can easily find the best routing
path in a traffic over the network since it adjusts to network when
compared with non adoptive routing algorithms.
oThe non adoptive routing algorithms which follows a static routing
table for the data to allow transmission over the network.
9. Distance
Vector Routing
Each node constructs a one-dimensional array containing the
distances (costs) to all other nodes and distributes that vector to
its immediate neighbors.
The starting assumption for distance-vector routing is that each
node knows the cost of the link to each of its directly connected
neighbors.
11. Distance
Vector Routing
Each nodes maintain a table on their own. For example: Routing
table of B.
Then B send the table to its neighbor.
Destination Cost
A 1
C 1
D 2
E 2
F 2
G 3
12. Distance
Vector Routing
Every node sends a message to its directly connected neighbors
containing its personal list of distance. ( for example, A sends its
information to its neighbors B,C,E, and F. )
If any of the recipients of the information from A find that A is
advertising a path shorter than the one they currently know about,
they update their list to give the new path length and note that
they should send packets for that destination through A. ( node B
learns from A that node E can be reached at a cost of 1; B also
knows it can reach A at a cost of 1, so it adds these to get the cost
of reaching E by means of A. B records that it can reach E at a cost
of 2 by going through A.)
13. Distance
Vector Routing
After every node has exchanged a few updates with its directly
connected neighbors, all nodes will know the least-cost path to all
the other nodes.
In addition to updating their list of distances when they receive
updates, the nodes need to keep track of which node told them
about the path that they used to calculate the cost, so that they
can create their forwarding table. ( for example, B knows that it
was A who said " I can reach E in one hop" and so B puts an entry
in its table that says "To reach E, use the link to A.)
14. Distance
Vector Routing
Information
Stored at
Node
Distance to Reach Node
A B C D E F G
0 1 1 2 1 1 2A
1 0 1 2 2 2 3B
1 1 0 1 2 2 2C
? 2 1 0 3 2 1D
1 2 2 3 0 2 3E
1 2 2 2 2 0 1F
? 3 2 1 3 1 0G
Table 2. final distances stored at each node ( global view).
15. Distance
Vector Routing
DistanceVector routing follows Bellman-Ford Algorithm. Here is the
pseudocode
function <predecessors> Bellman-Ford(G, source)
for i in 1 to |U| do
distance[i] = +infinity
predecessors[i] = null
distance[source] = 0
for i in 1 to (|U| - 1) do
for each Edge e in Edges(G) do
if distance[e.from] + length(e) < distance[e.to]
do
distance[e.to] = distance[e.from] + length(e)
predecessors[e.to] = e.from
for each Edge e in Edges(G) do
if distance[e.from] + length(e) < distance[e.to] do
error("Graph contains cycles of negative length")
return predecessors
16. Link State
Routing
Link state routing have two face:
Phase 1: Reliable Flooding
– Initial State: Each node knows the cost to its neighbor
– Final state: Each node knows the entire graph.
Phase 2: Route Calculation
– Each node uses dijkstra's algorithm to calculate the shortest
path.
Each Node sends send its link-state to all nodes in the topology
reliably.
Reliability: Employ a reliable protocol to transfer information
between neighbors.
17. Link State
Routing
1. Each router is responsible for meeting its neighbors and learning
their names.
Used a Hello Protocol, which send a data packet contains RID
and address of the network on which the packet is being sent
2. Each router constructs a link state packet which consists of a list
of names and cost for each of its neighbors.
3. The link state packet is transmitted to all other routers. Each
router stores the most recently generated link state packet from
each other router.
Link-state flooding: Sequencing and Aging procedures
Each routers store the identical Link State Database
4. Each router uses complete information on the network topology
to compute the shortest path route to each destination node.
Use Dijkstra’s algorithm to calculate the shortest path
19. Link State
Routing
For this graph each node made its own link state packet. For node B
the LSP is
Then B send the packet to its neighbor.
B (IP address)
Sequence number
Age
A 3
C 5
F 6
20. Link State
Routing
function Dijkstra(Graph, source):
create vertex set Q
for each vertex v in Graph: // Initialization
dist[v] ← INFINITY // Unknown distance from source to v
prev[v] ← UNDEFINED // Previous node in optimal path from source
add v to Q // All nodes initially in Q (unvisited nodes)
dist[source] ← 0 // Distance from source to source
while Q is not empty:
u ← vertex in Q with min dist[u] // Node with the least distance will be selected first
remove u from Q
for each neighbor v of u: // where v is still in Q.
alt ← dist[u] + length(u, v)
if alt < dist[v]: // A shorter path to v has been found
dist[v] ← alt
prev[v] ← u
return dist[], prev[]
25. Strength and
weakness of
this paper
Strength: Form this comparison the user can easily determine
that which routing algorithm will work best for their network. If
the user wants low CPU and memory utilization they can use
Distance vector routing algorithm and if the user wants fast, want
to have internal node involve ensure Hierarical Structure they can
use Link state algorithm.
26. Strength and
weakness of
this paper
Weakness:
Firstly, it doesn’t have any statically comparison between the two
paper.
Secondly, it doesn’t discuss about any data comparison. Like if the
number of data is high which algorithm works better.
Thirdly, the kind of problem that LPA and DVA have it doesn’t focus
of any of the problem
27. Conclusion
The comparison table of distance vector protocols with link state
protocol shows that distance vector protocols have frequently
periodic updates, low utilization of CPU and memory and has high
simplicity whereas the link state protocols have intensive
utilization of CPU and memory with a high complexity which
requires a well trained administrator to be handled.We could work
towards improving the algorithm.so as to avoid the major evils of
this algorithm namely Count to Infinity, Bouncing Effect and
Looping.
28. Conclusion
The future scope of this paper is to focus on security services in
routing protocols which is the protection of routing information
from threats to the integrity, authenticity, and in some cases the
confidentiality of routing updates.