SlideShare a Scribd company logo
ROUTING ALGORITHM
K.Haripritha
M.Sc(IT)
Nadar Saraswathi College of
Arts and Science.
Theni
 Main function of Network Layer:
*Routing of packets form the source machine to the destination machine.
 Routing Algorithm:
*Network Layer Software responsible for deciding which
output line an incoming packed should be transmitted on.
 Datagram:
 require computation of decision making tables for each packed
 Virtual Circuit:
 routing decision are made only when a new virtual circuit is being set up.
 Session Routing:
 data packets follow the same routing for the entire session.
Routing vs. Forwarding:
 Routing:
Filling and Updating routing tables
 Forwarding:
making the decision which routes to use based on routing
tables.
Adaptive vs. Non-Adaptive Algorithms.
 Non-Adaptive Algorithms:
Routing decision is based on pre-computed measurements
or estimates and do not update the table based on current
traffic and topology
 Adaptive Algorithms:
Change their routing decisions to reflect changes in the
topology and traffic.
 Optimization criterion:
◦ Distance,
◦ Bandwidth,
◦ Average Traffic
◦ Communication cost,
◦ Mean Queue Length,
◦ Measured Delay, …
 Algorithms:
◦ Dijkstra
◦ Flooding
 Selective Flooding
 Static Routing Algorithms
◦ Do not take into account actual network load.
 Dynamic Routing Algorithms
◦ Taking into account actual network load
◦ Distance Vector Routing: Each router maintain a table with the
best known distance to each destination and which line to use to
get there. Tables updated by exchanging information with the
neighbors.
◦ Link State Routing
 Slow Convergence to the correct answer.
 “Good news” Propagate fast
 “Bad news” Propagate slowly:
◦ The core of the problem is that when X tells Y that I has a path
somewhere, Y has no way of knowing whether it itself is on
the path.
 Distance Vector Routing was used in the ARPANET
until 1979 – when it was replaced by link state routing.
◦ Delay Metric was Queue Length thus did not take into account
line bandwidth when choosing routes.
1. Problem when line bandwidth changed for some bands from
56 kbps to 230 kbps or 1.544 Mbps.
2. Algorithm took to long to converge (the count-to-infinity
problem).
 Solution: Link State Routing
 Each router must do the following:
1. Discover its neighbors and learn their network
addresses.
2. Measure the delay or cost to each of its neighbors.
3. Construct a packet telling all it has just learned.
4. Send this packet to all other routers.
5. Compute the shortest path to every other router.
 Complete topology and all delays are experimentally
measured and distributed to every router. Dijkstra’s
algorithm can be run to find the shortest path to every
other router.
 “HELLO” packed send on each point-to-point line
from a booted router.
 Router on the other end must reply by sending its
globally unique “name”.
 Example of routers connected by a LAN.
 It is required by the Link State Routing algorithm that each
router not have a reasonable estimate of the delay/cost to each
of its neighbors.
◦ Send “ECHO” packet (ping) that the other side is required to
send back immediately.
 Measure Round Trip time; Divide by 2 to get an estimate.
 More accurate estimate by repeating the process several
times and by averaging estimates.
 Assumes symmetric delay.
 Channel Load Issue when Measuring Delay
◦ To factor the load in: round trip timer must be started when
the ECHO packed is queued.
 To ignore the load: round trip timer must be started when
ECHO packed reaches front of the queue.
 Including Traffic-induced Delays:
◦ If a router has a choice from 2 lines with the same
bandwidth, one of which is heavily loaded all the time and
one of which is not, the router will regard the route over the
unloaded line as shorter path.
◦ This choice in general will result in better performance
◦ Problem with Oscillations in the choice of best path.
 Packet Format:
◦ Identity of Sender
◦ Sequence Number
◦ Age
◦ List of Neighbors
◦ Corresponding Delay
 Distributing Link State Packets Reliably is tricky:
◦ As the packets are distributed and installed, the routers getting the first
ones will change their routes before other routers in the network update
their routing tables.
◦ Different Routers may be using different versions of the topology
(inconsistencies, loops, unreachable machines, etc.)
 Basic Algorithm: Flooding
◦ Sequence Number (incremented for each new packet sent) is used to
keep the flood in check.
◦ Routers keep track of all the source router packets they have been sent
to.
◦ New link state packets is checked against the track list:
 If new/unseen (based on the sequence number) then it is broadcasted
to all neighboring routers with exception of the sender.
 If duplicate, it is disregarded.
 If sequence number is lower than the highest one in the track list, it is
rejected.
 Problems with basic algorithm:
1. Sequence Number wrap around.
 Make a long precision number (e.g., 32-bit)
2. Crash of a router: losing track of sequence number.
3. Corruption of sequence number.
Solution: Include Age of each packet.
◦ Decrement this value once per second.
◦ When zero, this state information is disregarded.
◦ Normally a new packed is send every 10 sec.
Router information times out when:
 Router is down, or
 A Number of (e.g., 6) consecutive packets have been lost.
 Large Networks:
◦ Proportionally large routing tables are required for each router
◦ More CPU time is needed to scan them
◦ More bandwidth is needed to send status reports.
◦ At certain point network may grow so large where it is no longer
feasible for every router to have an entry for every other router.
◦ Solution: Routing has to be done hierarchically.
 Routers divided in Regions (as in telephone network):
◦ Each router knows how to route packets to destinations within
its own region.
◦ However, router does not have any information regarding the
topology of the network of other regions.
 When different networks are interconnected they are
regarded as a separate region in order to free the
routers in one network form having to know the
topological structure of the other ones.
 Huge networks will require more than two-level
hierarchy.
 How many hierarchical levels are optimal.
◦ Kamoun and Kleinrock (1979): optimal number for an N router
subnet is ln(N), requiring total of e*ln(N) entries per router.
 Sending a packed to all destinations simultaneously is called
Broadcasting.
◦ Direct Method: Source sends a distinct packet to each
destination routers in the subnet:
1. Wasteful of the bandwidth.
2. It requires source to have a list of all destinations.
 In practice this may be the only feasible solution.
◦ Flooding:
 Ordinarily ill suited for point-to-point communication:
 Generates to many packets, and
 Consumes to much bandwidth.
◦ Multi-destination Routing
 Each packets contains:
 A list of designations, or
 A bit map indicating the desired destinations.
 When packet arrives at a router:
 The router checks all the destinations to determine the set of output
lines that will be needed.
 Generates a new copy of the packed for each output line to be used and
includes in each packet only those destinations that are to use the line.
 After a sufficient number of hops, each packed will carry only one
destination and can be treated as normal packet.
 Multi-destination routing is like separately addressed packets, except
that when several packets must follow the same rout, one of them pays
full fare and the rest ride free.
 Spanning Tree:
◦ It is a subset of the subnet that includes all routers but
contains no loops.
◦ Each router knows which of its lines belong to the spanning
tree, it can copy an incoming broadcast packet onto all the
spanning tree lines except the one it arrived on.
 Makes excellent use of bandwidth (generates absolute minimum
number of packets necessary to do the job)
 Must have knowledge of some spanning tree for the method to be
applicable.
 Information available in some instances (e.g., link state
routing)
 Information not available (e.g., distance vector routing)
 Reverse Path Forwarding:
◦ Router checks if the broadcast packet arrived on the line that
is normally used for sending packets to the source of the
broadcast.
◦ If so, there is excellent chance that the broadcast packet itself
followed the best route from the router and is therefore the
first copy to arrive at the router. The router forwards copies
of it onto all lines except the one it arrived on.
◦ If the broadcast packet arrived on a line other than the
preferred one for reaching the source, the packet is discarded
as a likely duplicate.
 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)
 Application that require separate processes (i.e., each from
separate location) access and ability to work on the same data.
◦ Small group can use point-to-point messaging to accomplish
this task.
◦ Broadcasting can be used but communicating with 1000
“interested” machines out of million-node network is
inefficient.
 Need a mechanism that would send messages to well-defined
groups that are numerically large in size but small compared to
the network as a whole.
◦ Sending a message to a such a group is called multicasting.
◦ Corresponding routing algorithm is called multicast routing.
 Requirements:
◦ Create and Destroy Groups
◦ Nodes should be able to Join and Leave Groups, etc.
 Group Management.
◦ When a process joins a group it informs its host.
◦ Routers must know which of their hosts belong to which
group.
 Host must inform their routers about changes in group membership,
or
 Routers must query their hosts periodically.
◦ Information shared with Neighboring Routers (propagation
of information through the subnet).
 Link State Routing – each router is aware of the complete topology,
including which hosts belong to which groups.
◦ Pruning starting from leaf-node up toward root node.
 Distance Vector Routing – Basic pruning algorithm is based on reverse
path forwarding.
◦ Router with no hosts interested in a particular group and no connections
to other routers responds with PRUNE message to a multicast message.
◦ Also when a router with no group members among its hosts receives a
multicast message it too will respond with a PRUNE message effectively
recursively pruning the subnet.
◦ Potential Problem:
 Scales poorly to large networks.
 Network with n groups,
 Each Group on average has m members.
 For each Group m – spanning trees must be stored; total of m*n trees.
 Significant storage requirements for large number of groups.
 Increasing number of users of Portable Computers and
Personal Computer Devices. They require access to:
◦ E-mail
◦ File System, etc.
 In order to route a packet to a mobile host, the network
first has to find it.
 World Model of communication network:
◦ WAN consisting of routers and hosts,
◦ LAN’s connected to WAN, and
◦ MAN’s connected to WAN.
 Stationary Hosts:
◦ Hosts that never move.
 Migratory Hosts:
◦ Stationary hosts who move from one fixed site to another
from time to time but use the network only when they are
physically connected to it.
 Roaming Hosts:
◦ Need to maintain their connections as they move around.
 Mobile Hosts:
◦ Migratory and Roaming Hosts – that is all host that are away
from home and still want to be connected.
 All hosts are assumed to have:
◦ A permanent home location, and
◦ A permanent home address:
 Used to determine their home location (analogous to telephone
number; e.g., 1-212-555-1212).
 Routing goal in systems with mobile hosts:
◦ To make possible to send packets to mobile hosts using their
home address, and
◦ Have the packets efficiently reach them wherever they may be.
 Trick is off course to find them first.
 According to the sketch in previous slide world is divided up
(geographically) into small units – areas.
◦ Areas are typically LANs or wireless cells.
◦ Each area has one or more
 Foreign agents:
 Processes that keep track of all mobile hosts visiting the
area.
 Home agent:
 Keeps track of hosts whose home is in the area, but who
are currently visiting another area.
 REGISTRATION with Foreign Agent: When a new host
enters an area, either by connecting to it (e.g., plugging into
LAN), or wandering into the cell it must register itself with the
foreign agent of that area.
 Example: Sender wants to send a packet to a host in New York.
◦ 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).
◦ Home agent does:
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.
 In Ad-hoc networks the nodes can move or can be switched off.
◦ For example if G is switched off, A will need to deal with it because the
route that it was using (ADGI) is no longer valid.
◦ Idea: each node broadcasts a Hello message periodically. Each neighbor
is expected to respond to it. For the cases that there is no response the
information is purged for the routes that use corresponding node.
◦ List of Active Neighbors for a destination: For each possible destination,
each node, N, keeps track of its neighbors that have fed it a packed for
that destination during the last ∆T seconds.
 A node N does this by having a routing table keyed by destination
containing:
 Outgoing node to use to reach that destination,
 Hop count to the destination
 Most recent destination sequence number, and
 The list of active neighbors for that destination.

More Related Content

PPTX
Network Routing | Computer Science
PPTX
Routing algorithm
PPTX
BASICS OF ROUTING IN NETWORKS
PPTX
Routing algorithm
PPTX
Routing ppt
PPTX
Routing algorithms
PPTX
Routing and routing algorithms
PPTX
Presentation Routing algorithm
Network Routing | Computer Science
Routing algorithm
BASICS OF ROUTING IN NETWORKS
Routing algorithm
Routing ppt
Routing algorithms
Routing and routing algorithms
Presentation Routing algorithm

What's hot (20)

PPT
routing
PPTX
Introduction to backwards learning algorithm
PPT
11 routing
PPT
Routing protocols
PDF
Wireless LAN in Data Communication & Networking
PPTX
Classification of routing protocols
PPTX
Network layer Part 7
PPTX
Routing Presentation
PPT
Packet transfer mechanism using routers and IP addresses
PPTX
Routing algorithms
PPTX
Cluster based routing protocol
PPT
Layer 3
PPTX
Geographical routing presentation
PDF
Performance Analysis and Simulation of OLSR Routing Protocol in MANET
PDF
MANET, Unicast Routing Protocol, Multicast Routing Protocol.
PPTX
clas 8
PPTX
Wsn routing protocol
PPTX
Routing algorithm
PPTX
Switching concepts Data communication and networks
PPTX
OLSR | Optimized Link State Routing Protocol
routing
Introduction to backwards learning algorithm
11 routing
Routing protocols
Wireless LAN in Data Communication & Networking
Classification of routing protocols
Network layer Part 7
Routing Presentation
Packet transfer mechanism using routers and IP addresses
Routing algorithms
Cluster based routing protocol
Layer 3
Geographical routing presentation
Performance Analysis and Simulation of OLSR Routing Protocol in MANET
MANET, Unicast Routing Protocol, Multicast Routing Protocol.
clas 8
Wsn routing protocol
Routing algorithm
Switching concepts Data communication and networks
OLSR | Optimized Link State Routing Protocol
Ad

Similar to Presentation 2 (20)

PPTX
NETWORK LAYER PRESENTATION IP ADDRESSING UNIT-3.pptx
PPTX
Routing algorithms mehodology materials doc1
PPTX
Unit 3_Network Layer_Part II.pptx
PPTX
routing in computer networks for btech.pptx
PPTX
Unit 4_Network Layer_Part II.pptx
PPTX
CN_UNIT_3_routing algorithms.ppt.......x
PDF
Lecture number 5 Theory.pdf(machine learning)
PPTX
Module 3 Part B - computer networks module 2 ppt
PPTX
Experimental Analysis Of On Demand Routing Protocol
PDF
Network layer (Unit 3) part1.pdf
PPTX
Network layer new
PPTX
Computer Networks-Network layer Concepts
DOC
Acn Experiment No 2
PPTX
Routing Techniques
PDF
Answer sheet of switching & routing
PPTX
Network Layer
PPTX
Network Layer
PPT
Unit-3-Part-1 [Autosaved].ppt
PPTX
Routing Protocols.pptx
NETWORK LAYER PRESENTATION IP ADDRESSING UNIT-3.pptx
Routing algorithms mehodology materials doc1
Unit 3_Network Layer_Part II.pptx
routing in computer networks for btech.pptx
Unit 4_Network Layer_Part II.pptx
CN_UNIT_3_routing algorithms.ppt.......x
Lecture number 5 Theory.pdf(machine learning)
Module 3 Part B - computer networks module 2 ppt
Experimental Analysis Of On Demand Routing Protocol
Network layer (Unit 3) part1.pdf
Network layer new
Computer Networks-Network layer Concepts
Acn Experiment No 2
Routing Techniques
Answer sheet of switching & routing
Network Layer
Network Layer
Unit-3-Part-1 [Autosaved].ppt
Routing Protocols.pptx
Ad

More from Haripritha (9)

PPTX
Mapreduce script
PPTX
Wireless sensor networks
PPTX
Datamining
PPTX
Operating system
PPTX
PPTX
Computer Organization
PPTX
Open addressing &amp rehashing,extendable hashing
PPTX
programming language in c&c++
PPTX
encoding
Mapreduce script
Wireless sensor networks
Datamining
Operating system
Computer Organization
Open addressing &amp rehashing,extendable hashing
programming language in c&c++
encoding

Recently uploaded (20)

PPTX
Final Presentation General Medicine 03-08-2024.pptx
PDF
Microbial disease of the cardiovascular and lymphatic systems
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PPTX
Cell Structure & Organelles in detailed.
PDF
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
PDF
Business Ethics Teaching Materials for college
PPTX
Institutional Correction lecture only . . .
PPTX
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
PDF
RMMM.pdf make it easy to upload and study
PDF
O7-L3 Supply Chain Operations - ICLT Program
PPTX
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PPTX
PPH.pptx obstetrics and gynecology in nursing
PDF
VCE English Exam - Section C Student Revision Booklet
PDF
Supply Chain Operations Speaking Notes -ICLT Program
PDF
Complications of Minimal Access Surgery at WLH
PPTX
Renaissance Architecture: A Journey from Faith to Humanism
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PDF
Origin of periodic table-Mendeleev’s Periodic-Modern Periodic table
PDF
Basic Mud Logging Guide for educational purpose
Final Presentation General Medicine 03-08-2024.pptx
Microbial disease of the cardiovascular and lymphatic systems
Abdominal Access Techniques with Prof. Dr. R K Mishra
Cell Structure & Organelles in detailed.
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
Business Ethics Teaching Materials for college
Institutional Correction lecture only . . .
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
RMMM.pdf make it easy to upload and study
O7-L3 Supply Chain Operations - ICLT Program
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PPH.pptx obstetrics and gynecology in nursing
VCE English Exam - Section C Student Revision Booklet
Supply Chain Operations Speaking Notes -ICLT Program
Complications of Minimal Access Surgery at WLH
Renaissance Architecture: A Journey from Faith to Humanism
human mycosis Human fungal infections are called human mycosis..pptx
Origin of periodic table-Mendeleev’s Periodic-Modern Periodic table
Basic Mud Logging Guide for educational purpose

Presentation 2

  • 1. ROUTING ALGORITHM K.Haripritha M.Sc(IT) Nadar Saraswathi College of Arts and Science. Theni
  • 2.  Main function of Network Layer: *Routing of packets form the source machine to the destination machine.  Routing Algorithm: *Network Layer Software responsible for deciding which output line an incoming packed should be transmitted on.  Datagram:  require computation of decision making tables for each packed  Virtual Circuit:  routing decision are made only when a new virtual circuit is being set up.  Session Routing:  data packets follow the same routing for the entire session.
  • 3. Routing vs. Forwarding:  Routing: Filling and Updating routing tables  Forwarding: making the decision which routes to use based on routing tables. Adaptive vs. Non-Adaptive Algorithms.  Non-Adaptive Algorithms: Routing decision is based on pre-computed measurements or estimates and do not update the table based on current traffic and topology  Adaptive Algorithms: Change their routing decisions to reflect changes in the topology and traffic.
  • 4.  Optimization criterion: ◦ Distance, ◦ Bandwidth, ◦ Average Traffic ◦ Communication cost, ◦ Mean Queue Length, ◦ Measured Delay, …  Algorithms: ◦ Dijkstra ◦ Flooding  Selective Flooding
  • 5.  Static Routing Algorithms ◦ Do not take into account actual network load.  Dynamic Routing Algorithms ◦ Taking into account actual network load ◦ Distance Vector Routing: Each router maintain a table with the best known distance to each destination and which line to use to get there. Tables updated by exchanging information with the neighbors. ◦ Link State Routing
  • 6.  Slow Convergence to the correct answer.  “Good news” Propagate fast  “Bad news” Propagate slowly: ◦ The core of the problem is that when X tells Y that I has a path somewhere, Y has no way of knowing whether it itself is on the path.
  • 7.  Distance Vector Routing was used in the ARPANET until 1979 – when it was replaced by link state routing. ◦ Delay Metric was Queue Length thus did not take into account line bandwidth when choosing routes. 1. Problem when line bandwidth changed for some bands from 56 kbps to 230 kbps or 1.544 Mbps. 2. Algorithm took to long to converge (the count-to-infinity problem).  Solution: Link State Routing
  • 8.  Each router must do the following: 1. Discover its neighbors and learn their network addresses. 2. Measure the delay or cost to each of its neighbors. 3. Construct a packet telling all it has just learned. 4. Send this packet to all other routers. 5. Compute the shortest path to every other router.  Complete topology and all delays are experimentally measured and distributed to every router. Dijkstra’s algorithm can be run to find the shortest path to every other router.
  • 9.  “HELLO” packed send on each point-to-point line from a booted router.  Router on the other end must reply by sending its globally unique “name”.  Example of routers connected by a LAN.
  • 10.  It is required by the Link State Routing algorithm that each router not have a reasonable estimate of the delay/cost to each of its neighbors. ◦ Send “ECHO” packet (ping) that the other side is required to send back immediately.  Measure Round Trip time; Divide by 2 to get an estimate.  More accurate estimate by repeating the process several times and by averaging estimates.  Assumes symmetric delay.  Channel Load Issue when Measuring Delay ◦ To factor the load in: round trip timer must be started when the ECHO packed is queued.
  • 11.  To ignore the load: round trip timer must be started when ECHO packed reaches front of the queue.  Including Traffic-induced Delays: ◦ If a router has a choice from 2 lines with the same bandwidth, one of which is heavily loaded all the time and one of which is not, the router will regard the route over the unloaded line as shorter path. ◦ This choice in general will result in better performance ◦ Problem with Oscillations in the choice of best path.
  • 12.  Packet Format: ◦ Identity of Sender ◦ Sequence Number ◦ Age ◦ List of Neighbors ◦ Corresponding Delay
  • 13.  Distributing Link State Packets Reliably is tricky: ◦ As the packets are distributed and installed, the routers getting the first ones will change their routes before other routers in the network update their routing tables. ◦ Different Routers may be using different versions of the topology (inconsistencies, loops, unreachable machines, etc.)  Basic Algorithm: Flooding ◦ Sequence Number (incremented for each new packet sent) is used to keep the flood in check. ◦ Routers keep track of all the source router packets they have been sent to. ◦ New link state packets is checked against the track list:  If new/unseen (based on the sequence number) then it is broadcasted to all neighboring routers with exception of the sender.  If duplicate, it is disregarded.  If sequence number is lower than the highest one in the track list, it is rejected.
  • 14.  Problems with basic algorithm: 1. Sequence Number wrap around.  Make a long precision number (e.g., 32-bit) 2. Crash of a router: losing track of sequence number. 3. Corruption of sequence number. Solution: Include Age of each packet. ◦ Decrement this value once per second. ◦ When zero, this state information is disregarded. ◦ Normally a new packed is send every 10 sec. Router information times out when:  Router is down, or  A Number of (e.g., 6) consecutive packets have been lost.
  • 15.  Large Networks: ◦ Proportionally large routing tables are required for each router ◦ More CPU time is needed to scan them ◦ More bandwidth is needed to send status reports. ◦ At certain point network may grow so large where it is no longer feasible for every router to have an entry for every other router. ◦ Solution: Routing has to be done hierarchically.
  • 16.  Routers divided in Regions (as in telephone network): ◦ Each router knows how to route packets to destinations within its own region. ◦ However, router does not have any information regarding the topology of the network of other regions.  When different networks are interconnected they are regarded as a separate region in order to free the routers in one network form having to know the topological structure of the other ones.  Huge networks will require more than two-level hierarchy.  How many hierarchical levels are optimal. ◦ Kamoun and Kleinrock (1979): optimal number for an N router subnet is ln(N), requiring total of e*ln(N) entries per router.
  • 17.  Sending a packed to all destinations simultaneously is called Broadcasting. ◦ Direct Method: Source sends a distinct packet to each destination routers in the subnet: 1. Wasteful of the bandwidth. 2. It requires source to have a list of all destinations.  In practice this may be the only feasible solution. ◦ Flooding:  Ordinarily ill suited for point-to-point communication:  Generates to many packets, and  Consumes to much bandwidth.
  • 18. ◦ Multi-destination Routing  Each packets contains:  A list of designations, or  A bit map indicating the desired destinations.  When packet arrives at a router:  The router checks all the destinations to determine the set of output lines that will be needed.  Generates a new copy of the packed for each output line to be used and includes in each packet only those destinations that are to use the line.  After a sufficient number of hops, each packed will carry only one destination and can be treated as normal packet.  Multi-destination routing is like separately addressed packets, except that when several packets must follow the same rout, one of them pays full fare and the rest ride free.
  • 19.  Spanning Tree: ◦ It is a subset of the subnet that includes all routers but contains no loops. ◦ Each router knows which of its lines belong to the spanning tree, it can copy an incoming broadcast packet onto all the spanning tree lines except the one it arrived on.  Makes excellent use of bandwidth (generates absolute minimum number of packets necessary to do the job)  Must have knowledge of some spanning tree for the method to be applicable.  Information available in some instances (e.g., link state routing)  Information not available (e.g., distance vector routing)
  • 20.  Reverse Path Forwarding: ◦ Router checks if the broadcast packet arrived on the line that is normally used for sending packets to the source of the broadcast. ◦ If so, there is excellent chance that the broadcast packet itself followed the best route from the router and is therefore the first copy to arrive at the router. The router forwards copies of it onto all lines except the one it arrived on. ◦ If the broadcast packet arrived on a line other than the preferred one for reaching the source, the packet is discarded as a likely duplicate.
  • 21.  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)
  • 22.  Application that require separate processes (i.e., each from separate location) access and ability to work on the same data. ◦ Small group can use point-to-point messaging to accomplish this task. ◦ Broadcasting can be used but communicating with 1000 “interested” machines out of million-node network is inefficient.  Need a mechanism that would send messages to well-defined groups that are numerically large in size but small compared to the network as a whole. ◦ Sending a message to a such a group is called multicasting. ◦ Corresponding routing algorithm is called multicast routing.
  • 23.  Requirements: ◦ Create and Destroy Groups ◦ Nodes should be able to Join and Leave Groups, etc.  Group Management. ◦ When a process joins a group it informs its host. ◦ Routers must know which of their hosts belong to which group.  Host must inform their routers about changes in group membership, or  Routers must query their hosts periodically. ◦ Information shared with Neighboring Routers (propagation of information through the subnet).
  • 24.  Link State Routing – each router is aware of the complete topology, including which hosts belong to which groups. ◦ Pruning starting from leaf-node up toward root node.  Distance Vector Routing – Basic pruning algorithm is based on reverse path forwarding. ◦ Router with no hosts interested in a particular group and no connections to other routers responds with PRUNE message to a multicast message. ◦ Also when a router with no group members among its hosts receives a multicast message it too will respond with a PRUNE message effectively recursively pruning the subnet. ◦ Potential Problem:  Scales poorly to large networks.  Network with n groups,  Each Group on average has m members.  For each Group m – spanning trees must be stored; total of m*n trees.  Significant storage requirements for large number of groups.
  • 25.  Increasing number of users of Portable Computers and Personal Computer Devices. They require access to: ◦ E-mail ◦ File System, etc.  In order to route a packet to a mobile host, the network first has to find it.  World Model of communication network: ◦ WAN consisting of routers and hosts, ◦ LAN’s connected to WAN, and ◦ MAN’s connected to WAN.
  • 26.  Stationary Hosts: ◦ Hosts that never move.  Migratory Hosts: ◦ Stationary hosts who move from one fixed site to another from time to time but use the network only when they are physically connected to it.  Roaming Hosts: ◦ Need to maintain their connections as they move around.  Mobile Hosts: ◦ Migratory and Roaming Hosts – that is all host that are away from home and still want to be connected.
  • 27.  All hosts are assumed to have: ◦ A permanent home location, and ◦ A permanent home address:  Used to determine their home location (analogous to telephone number; e.g., 1-212-555-1212).  Routing goal in systems with mobile hosts: ◦ To make possible to send packets to mobile hosts using their home address, and ◦ Have the packets efficiently reach them wherever they may be.  Trick is off course to find them first.
  • 28.  According to the sketch in previous slide world is divided up (geographically) into small units – areas. ◦ Areas are typically LANs or wireless cells. ◦ Each area has one or more  Foreign agents:  Processes that keep track of all mobile hosts visiting the area.  Home agent:  Keeps track of hosts whose home is in the area, but who are currently visiting another area.  REGISTRATION with Foreign Agent: When a new host enters an area, either by connecting to it (e.g., plugging into LAN), or wandering into the cell it must register itself with the foreign agent of that area.
  • 29.  Example: Sender wants to send a packet to a host in New York. ◦ 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). ◦ Home agent does: 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.
  • 30.  In Ad-hoc networks the nodes can move or can be switched off. ◦ For example if G is switched off, A will need to deal with it because the route that it was using (ADGI) is no longer valid. ◦ Idea: each node broadcasts a Hello message periodically. Each neighbor is expected to respond to it. For the cases that there is no response the information is purged for the routes that use corresponding node. ◦ List of Active Neighbors for a destination: For each possible destination, each node, N, keeps track of its neighbors that have fed it a packed for that destination during the last ∆T seconds.  A node N does this by having a routing table keyed by destination containing:  Outgoing node to use to reach that destination,  Hop count to the destination  Most recent destination sequence number, and  The list of active neighbors for that destination.