Routing Algorithms
Routing Algorithms
Networks
ROUTING ALGORITHMS
D I
F 6 E 1
B 2 C
4 3
D D E F
F 4 C 1 D 4
E F
Packets easily built –8problem with knowing when F 8 E 8
to built them.
J
J H
H L
L N
O
N O
K
K
M
M
F H J N
A D E K G O M O
E C G D N K
H B L H
L B
April 20, 2025 29
Broadcast Routing (cont.)
Reverse Path Forwarding in spite of not
being optimal procedure:
Efficient and easy to implement Algorithm
It does not require routers to know about
spanning trees.
Does not have the overhead of destination list or
bit map in each broadcast packet (as multi-
destination addressing).
It does not require any special mechanism to
stop the process as flooding does (hop counter in
each packed and a priori knowledge of the
subnet diameter, or a list of packets already
seen per source)
1 2
1 1 2 2
2
2
1
1
A Multicast Tree for group 1 A Multicast Tree for group 2
Wireless cell
Home Agent
Mobile
Host
Home LAN
Foreign
Agent
Foreign LAN
WAN MAN
3. The foreign agent contact the mobile host’s home agent and informs it about a mobile
host in his area. This message contains:
The foreign agent’s network address,
Security information (“to convince the home agent that the mobile host is really there”).
Checking out when done (typically mobile hosts just turn-off their computers).
foreign agent 1. Pa
c
mob ket is se
packets are
ile h
ost’s nt to the
hom
e ad
3. Se dres
nder s
forei i s gi ve
gn a n
gent
’s ad
tunneled to the
dres
4. Subsequent
to the
t is t unneled
e
2. Pack gent
eigh a
for
Packets sent to the mobile host on its home LAN in NEW York are intercepted by
the home agent (step 1).
Home agent looks up mobile host’s new (temporary) location and finds the
address of the foreign agent handling the mobile host (i.e., Los Angeles).
1. It encapsulates the packet in the payload field of an outer packet and sends the
latter to the foreign agent (step 2). This mechanism is called tunneling.
After getting the encapsulated packet, the foreign agent removes the original
packet from the payload field and sends it to the mobile host as a data link frame.
2. The home agent tells the sender to henceforth send packet to the mobile host by
encapsulating them in the payload of packets explicitly addressed to the foreign
agent instead of just sending them to the mobile host's home address (step 3.)
Subsequent packets can now be routed directly to the host via foreign agent (step
4.), bypassing the home agent entirely.
A A A A
B C B C B C B C
D D D D
E E E E
F G F G F G F G
H I H I H I H I
Range of A’s Broadcast After B and D have After C,F and G have After E,H and I have
received of A’s Broadcast received of A’s Broadcast received of A’s Broadcast
Algorithm Details.
1. The Source Address, Request ID pair is looked up in local history table to see if this request has
already been seen and processed.
If duplicate – it is disregarded
If not duplicate – pair is entered in history table.
A
B C
2. The receiver node looks up the destination in its route table.
If a fresh route to the destination is know, a ROUTE REPLY packet is sent back to the source
D
informing it how to get to the destination. Fresh means that the Destination sequence
number stored in the routing table is greater than or equal to the Destination sequence
number in the ROUTE REQUEST packet. If it is less, the stored route is older than the previous
route the source had for the destination thus next step 3 is executed. E
F G
H I
After B and D have
received of A’s Broadcast
H I
After C,F and G have
received of A’s Broadcast
H I
After C,F and G have
received of A’s Broadcast
H I
After E,H and I have
received of A’s Broadcast
1. No route to I is known.
2. The sequence number for I in the ROUTE REPLY packed is
greater than the value in the routing table.
3. The sequence numbers are equal but the new route I s shorter.
This ensures that all nodes on the reverse route learn the
route to I for free as a byproduct of A’s route discovery.
Nodes that got the original REQUEST ROUTE packed but
were not on the reverse path (B, C, E, F, and H in this
example) discard the reverse route table entry when the
associated timer expires.
A A 1 F,G A
B C
B B 1 F,G
C B 2 G D
E G 2 E
F G
F F 1 A,B
G G 1 A,B
H F 2 A,B
H I
I G 2 A,B Graph after G has gone
down
1.2
1
Maximum Carrying
capacity of subnet
0.8
Packets Delivered [%]
Desirable Performance
0.6 Congested Performance
Ideal
0.4
0.2
0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
Num ber of Packets in Mil.
Slow Processors:
Queue build up due to routers slow CPU’s at performing bookkeeping task:
Queueing buffers,
Updating tables, etc.
Typically the problem is that upgrading one part of the system shifts the
bottleneck to the other someplace else. The real problem frequently is a
mismatch parts of the system. The problem will persist until all components
of the system are in balance.
Open-loop approach
Problem is solved at the design cycle
Once the system is running midcourse correction are NOT
made.
Tools for doing open-loop control:
Deciding when to accept new traffic,
Deciding when to disregard packets and which ones.
Making scheduling decision at various points in the network.
Note that all those decisions are made without regard to the
current state of the network.
A A
B B