Ad Hoc Networks
Ad Hoc Networks
Ad Hoc Networks
Chalermek Intanagonwiwat
Slides courtesy of Golden G. Richard III, Jim Thompson, Musenki, and Nitin Vaidya
Ease, speed of deployment Decreased dependence on infrastructure Can use in many scenarios where deployment of a wired network is impractical or impossible Lots of military applications, but there are others
Many Applications
Personal area networking Military environments Civilian environments
soldiers, tanks, planes cell phone, laptop, ear phone, wrist watch
Many Variations
Fully Symmetric Environment
all nodes have identical capabilities and responsibilities
Asymmetric Capabilities
transmission ranges and radios may differ battery life at different nodes may differ processing capacity may be different at different nodes speed of movement different
Emergency operations
search-and-rescue policing and fire fighting
meeting rooms sports stadiums groups of boats, small aircraft (wired REALLY impractical!!)
Asymmetric Responsibilities
only some nodes may route packets some nodes may act as leaders of nearby nodes (e.g., cluster head)
Many Variations
Traffic characteristics may differ
bandwidth timeliness constraints reliability requirements unicast / broadcast / multicast / geocast
Many Variations
Mobility patterns may be different
people sitting at an airport lounge (little mobility) taxi cabs (highly mobile) military movements (mostly clustered?) personal area network (again, mostly clustered?)
Mobility characteristics
speed predictability
direction of movement pattern of movement
Challenges
Limited wireless transmission range Broadcast nature of the wireless medium Packet losses due to transmission errors Environmental issues (chop that tree!!) Mobility-induced route changes Mobility-induced packet losses Battery constraints Potentially frequent network partitions Ease of snooping on wireless transmissions (security hazard)
Nodes A and C cannot hear each other Transmissions by nodes A and C can collide at node B On collision, both transmissions are lost Nodes A and C are hidden from each other
Routing Protocols
Proactive protocols
Determine routes independent of traffic pattern Traditional link-state and distance-vector routing protocols are proactive Maintain routes between every host pairs at all times Based on periodic updates High routing overhead Example: DSDV (Destination Sequenced Distance Vector)
Rate of link failure/repair may be high when nodes move fast New performance criteria may be used
route stability despite mobility energy consumption
Trade-Off
Latency of route discovery
Proactive protocols may have lower latency since routes are maintained at all times Reactive protocols may have higher latency because a route from X to Y will be found only when X attempts to send to Y
Hybrid protocols
Adaptive Combination of proactive and reactive Example: ZRP (Zone Routing Protocol)
Which approach achieves a better tradeoff depends on the traffic and mobility patterns
Each route is tagged with a sequence number; routes with greater sequence numbers are preferred
Represents a node that has received packet P Represents that connected nodes are within each others transmission range
Represents a node that receives packet P for the first time Represents transmission of packet P
Node C receives packet P from G and H, but does not forward it again, because node C has already forwarded packet P once
Nodes J and K both broadcast packet P to node D Since nodes J and K are hidden from each other, their transmissions may collide => Packet P may not be delivered to node D at all, despite the use of flooding!!
Node D does not forward packet P, because node D is the intended destination of packet P
Flooding completed
Nodes unreachable from S do not receive packet P (e.g., node Z) Nodes for which all paths from S go through the destination D also do not receive packet P (example: node N)
Flooding may deliver packets to too many nodes (in the worst case, all nodes reachable from sender may receive the packet)
In our example, nodes J and K may transmit to node D simultaneously, resulting in loss of the packet
in this case, destination would not receive the packet at all
Node H receives packet RREQ from two neighbors: potential for collision
Node C receives RREQ from G and H, but does not forward it again, because node C has already forwarded RREQ once
Nodes J and K both broadcast RREQ to node D Since nodes J and K are hidden from each other, their transmissions may collide
Node D does not forward RREQ, because node D is the intended target of the route discovery
If unidirectional (asymmetric) links are allowed, then RREP may need a route discovery for S from node D
To ensure this, RREQ should be forwarded only if it received on a link that is known to be bi-directional
Unless node D already knows a route to node S If a route discovery is initiated by D for a route to S, then the Route Reply is piggybacked on the Route Request from D.
DSR: More
Node S on receiving RREP, caches the route included in the RREP When node S sends a data packet to D, the entire route is included in the packet header Intermediate nodes use the source route included in a packet to determine to whom a packet should be forwarded Note that routes are discovered ONLY when a node wants to send data to a node and no route to that node is available
hence the name source routing
means
S B A C H
[C,S]
[F,J,D],[F,E,S]
F G
[G,C,S]
[J,F,E,S]
J K Z D
Represents cached route at a node (DSR maintains the cached routes in a tree format)
S B A C H
[C,S]
[F,J,D],[F,E,S]
F
[G,C,S]
[J,F,E,S]
G I
[K,G,C,S] K RREQ
J D
RREP
L A N
When node Z sends a route request Z for node C, node K sends back a route reply [Z,K,G,C] to node Z using a locally cached route
J sends a route error to S along route J-F-E-S when its attempt to forward the data packet S (with route SEFJD) on J-D fails Nodes hearing RERR update their route cache to remove link J-D
DSR: Advantages
Routes maintained only between nodes who need to communicate Route caching can further reduce route discovery overhead A single route discovery may yield many routes to the destination, due to intermediate nodes replying from local caches
reduces overhead of route maintenance
DSR: Disadvantages
Packet header size grows with route length due to source routing Flood of route requests may potentially reach all nodes in the network Care must be taken to avoid collisions between route requests propagated by neighboring nodes insertion of random delays before forwarding RREQ
Default Flows
Can use most recent flow for each <source, destination> as default Transmit no additional info on data packets Nodes on path between source and destination examine TTL of packet to see if they should forward If source, destination, TTL match most recent flow, forward as if flow ID were present
Route Shortening
Illustration:
S A B C D is source route C overhears packet when S transmits C sends gratuitous ROUTE REPLY to S, containing S C D to replace old route Associate a hop count with each flow table entry Hearing a packet with a hop count less than expected means gratuitous ROUTE REPLY should be sent
Latency
AODV attempts to improve on vanilla DSR by maintaining routing tables at the nodes, so that data packets do not have to contain routes AODV retains the desirable feature of DSR that routes are maintained only between nodes which need to communicate Implicit source routing version of DSR has largely removed the improvements that AODV had over vanilla DSR
Each time the route entry is used to send data to the destination, the expiration time is pushed forward
More RREQ
When a node re-broadcasts a Route Request, it sets up a reverse path pointing towards the source When the intended destination receives a Route Request, it replies by sending a Route Reply Route Reply travels along the reverse path setup when Route Request is forwarded If a node knows a route to the destination, it can reply directly to the node that forwarded the RREQ
AODV assumes bi-directional links!
Flags
Node C receives RREQ from G and H, but does not forward it again, because node C has already forwarded RREQ once
Node D does not forward RREQ, because node D is the intended target of the RREQ
Forward links are setup when RREP travels along the reverse path Represents a link on the forward path
Routing table entries used to forward data packet. Route is not included in packet header.
Timeouts
A routing table entry maintaining a reverse path is purged after a timeout interval
timeout should be long enough to allow RREP to come back
A routing table entry maintaining a forward path is purged if not used for an active_route_timeout interval
if no data is sent using a particular routing table entry, that entry will be deleted from the routing table (even if the route may actually still be valid)
B E
Loop would look like thisbut prevented, because the new RREQ sent by C contains a destination sequence # for D of *2*--this means that the next hop A B to D cant be used. The sequence number reveals that the route is too old!
Mobility Model
Random waypoint model
Initial random location Choose destination on grid Move to destination at speed of 0-20m/sec Pause Choose new destination and repeat
1500x300 w/ 50 nodes
900 seconds 4 512-byte packets/sec (except for 40 senders, 3 per sec) 500 seconds 4 512-byte packets/sec for 10/20 senders, 2 per sec for 40 senders
Interesting Metrics
Delivery fraction (% of packets delivered successfully) Average end-to-end delay (# secs to deliver a data packet) Normalized routing load
# of packets (routing, etc.) per data packet delivered E.g., each hop in a RREQ counts as one packet
20 sources
50 nodes, delay
10 sources
40 sources
20 sources
50 nodes, delay
30 sources
40 sources
20 sources
20 sources
20 sources
40 sources
40 sources
Observations
More stressful situations:
AODV better in terms of packet delivery % DSR attempts to use too many stale routes DSR delay much higher DSR loses many packets because route discovery takes too longsend queue fills, drops packets
Observations (cont.)
DSR almost always has better routing load (in terms of # packets!) DSR caches routes, so can eliminate many full route request/reply cycles DSR does generate a lot of RREPs..so in terms of # bytes transmitted, difference from AODV is not so great
When the first packet is sent to a destination, the destination oriented DAG is constructed The initial construction does result in flooding of control packets
Disadvantages
Request Zone
Define a Request Zone LAR is same as flooding, except that only nodes in request zone forward route request Smallest rectangle including S and expected zone for D
Route requests limited to a Request Zone that contains the Expected Zone and location of the sender node
Disadvantages
Nodes need to know their physical locations Does not take into account possible existence of obstructions for radio transmissions