Mobile and Wireless Networking 2013 / 2014
192620010 Mobile & Wireless Networking Lecture 10: Mobile - - PowerPoint PPT Presentation
192620010 Mobile & Wireless Networking Lecture 10: Mobile - - PowerPoint PPT Presentation
192620010 Mobile & Wireless Networking Lecture 10: Mobile Transport Layer & Ad Hoc Networks [Schiller, Section 8.3 & Section 9] [Reader, Part 8] Geert Heijenk Mobile and Wireless Networking 2013 / 2014 Outline of Lecture 10
Mobile and Wireless Networking 2013 / 2014
Outline of Lecture 10
Mobile transport layer
Motivation Approaches for improvement
Indirect TCP Snooping TCP Mobile TCP Selective retransmission
Recommended TCP improvements
Ad hoc networks
Concept Addressing and forwarding in ad-hoc networks Routing in ad-hoc networks
Problem description DSDV (Destination Sequenced Distance Vector) Ad-hoc On-demand Distance Vector (AODV) DSR (Dynamic Source Routing) Further alternatives
2
Mobile and Wireless Networking 2013 / 2014
3
Motivation I
Transport protocols typically designed for
Fixed end-systems Fixed, wired networks
TCP congestion control
packet loss in fixed networks typically due to (temporary) overload
situations
router have to discard packets as soon as the buffers are full TCP recognizes congestion only indirect via missing
acknowledgements, retransmissions unwise, they would only contribute to the congestion and make it even worse
slow-start algorithm as reaction
Mobile and Wireless Networking 2013 / 2014
4
Motivation II
TCP slow-start algorithm
sender calculates a congestion window for a receiver start with a congestion window size equal to one segment exponential increase of the congestion window up to the congestion
threshold, then linear increase
missing acknowledgement causes the reduction of the congestion
threshold to one half of the current congestion window
congestion window starts again with one segment
TCP fast retransmit/fast recovery
TCP sends an acknowledgement only after receiving a packet if a sender receives several acknowledgements for the same
packet, this is due to a gap in received packets at the receiver
however, the receiver got all packets up to the gap and is actually
receiving packets
therefore, packet loss is not due to severe congestion, continue
with (half of) current congestion window (do not use slow-start)
Mobile and Wireless Networking 2013 / 2014
5
Influences of mobility on TCP-mechanisms
TCP assumes congestion if packets are dropped
typically wrong in wireless networks, here we often have packet loss
due to transmission errors
furthermore, mobility itself can cause packet loss, if e.g. a mobile node
moves from one access point (e.g. foreign agent in Mobile IP) to another while there are still packets in transit and forwarding is not possible
Additional problem:
it takes a long time to increase the congestion window if the latency of
the wireless link is high
The performance of an unchanged TCP degrades severely
but TCP cannot be changed due to the large base of installation in the
fixed network (end-to-end protocol)
therefore TCP for mobility has to remain compatible
Mobile and Wireless Networking 2013 / 2014
6
Solutions: Indirect TCP / Performance Enhancing Proxy (RFC 3135)
Indirect TCP or I-TCP segments the connection
no changes to the TCP protocol for hosts connected to the wired
Internet, millions of computers use (variants of) this protocol
optimized TCP protocol for mobile hosts splitting of the TCP connection at, e.g., the foreign agent into 2 TCP
connections, no real end-to-end connection any longer
hosts in the fixed part of the net do not notice the characteristics of
the wireless part
mobile host performance enhancing proxy: access point / foreign agent „wired“ Internet „wireless“ TCP standard TCP
Mobile and Wireless Networking 2013 / 2014
7
mobile host access point2 Internet access point1 socket migration and state transfer
I-TCP socket and state migration
Socket contains current TCP connection information (seq.num, ports) During handover, current AP buffers packets Since these packets have been acknowledged, they must be forwarded to
new AP after handover is executed
Fixed-side connection must be maintained (socket)
Mobile and Wireless Networking 2013 / 2014
8
Indirect TCP III
Advantages
no changes in the fixed network necessary, no changes for the hosts
(TCP protocol) necessary, all current optimizations to TCP still work
transmission errors on the wireless link do not propagate into the fixed
network
simple to control, mobile TCP is used only for one hop between, e.g.,
a foreign agent and mobile host
therefore, a very fast retransmission of packets is possible, the delay
- n the mobile hop is known
Disadvantages
loss of end-to-end semantics, an acknowledgement to a sender does
now not any longer mean that a receiver really got a packet, foreign agents might crash
higher latency possible due to buffering of data within the foreign
agent and forwarding to a new foreign agent
Mobile and Wireless Networking 2013 / 2014
9
Solutions: Snooping TCP I
„Transparent“ extension of TCP within the foreign agent
buffering of packets sent to the mobile host lost packets on the wireless link (both directions!) will be
retransmitted immediately by the mobile host or foreign agent, respectively (so called “local” retransmission)
the foreign agent therefore “snoops” the packet flow and recognizes
acknowledgements in both directions, it also filters ACKs
changes of TCP only within the foreign agent
„wired“ Internet buffering of data end-to-end TCP connection local retransmission correspondent host foreign agent mobile host snooping of ACKs
Mobile and Wireless Networking 2013 / 2014
10
Snooping TCP II
Data transfer to the mobile host
FA buffers data until it receives ACK of the MH, FA detects packet
loss via duplicated ACKs or time-out
fast retransmission possible, transparent for the fixed network
Data transfer from the mobile host
FA detects packet loss on the wireless link via sequence numbers,
FA answers directly with a NACK to the MH
MH can now retransmit data with only a very short delay
Integration of the MAC layer
MAC layer often has similar mechanisms to those of TCP thus, the MAC layer can already detect duplicated packets due to
retransmissions and discard them
Problems
snooping TCP does not isolate the wireless link as good as I-TCP snooping might be useless depending on encryption schemes
Mobile and Wireless Networking 2013 / 2014
11
Solutions: Mobile TCP
Special handling of lengthy and/or frequent disconnections M-TCP splits as I-TCP does
unmodified TCP fixed network to supervisory host (SH) optimized TCP SH to MH
Supervisory host
no caching, no retransmission monitors all packets, if disconnection detected
set sender window size to 0 sender automatically goes into persistent mode
old or new SH reopen the window
Advantages
maintains semantics, supports disconnection, no buffer forwarding
Disadvantages
loss on wireless link propagated into fixed network adapted TCP on wireless link
Mobile and Wireless Networking 2013 / 2014
12
Selective retransmission
TCP acknowledgements are often cumulative
ACK n acknowledges correct and in-sequence receipt of packets
up to n
if single packets are missing quite often a whole packet sequence
beginning at the gap has to be retransmitted (go-back-n), thus wasting bandwidth
Selective retransmission as one solution
RFC2018 allows for acknowledgements of single packets, not only
acknowledgements of in-sequence packet streams without gaps
sender can now retransmit only the missing packets
Advantage
much higher efficiency
Disadvantage
more complex software in a receiver, more buffer needed at the
receiver
Mobile and Wireless Networking 2013 / 2014
Recommended TCP Improvements (RFC 3481)
- Appropriate Window Size (Sender & Receiver)
- Increased Initial Window (Sender)
- Limited Transmit (Sender)
- IP MTU Larger than Default
- Path MTU Discovery (Sender & Intermediate Routers)
- Selective Acknowledgments (Sender & Receiver)
- Explicit Congestion Notification (Sender, Receiver & Intermediate Routers)
- TCP Timestamps Option (Sender & Receiver)
- Disabling RFC 1144 TCP/IP Header Compression (Wireless Host)
(RObust Header Compression, ROHC, RFC3095, is OK)
13
Mobile and Wireless Networking 2013 / 2014
Outline of Lecture 10
Mobile transport layer
Motivation Approaches for improvement
Indirect TCP Snooping TCP Mobile TCP Selective retransmission
Recommended TCP improvements
Ad hoc networks
Concept Addressing and forwarding in ad-hoc networks Routing in ad-hoc networks
Problem description DSDV (Destination Sequenced Distance Vector) Ad-hoc On-demand Distance Vector (AODV) DSR (Dynamic Source Routing) Further alternatives
14
Mobile and Wireless Networking 2013 / 2014
15
Ad hoc network concept
Networks of wireless terminals that do not necessarily rely on
existing infrastructure
Although interworking with infrastructure is possible
Direct communication between terminals when needed Multi-hop communication Extended concept of mobility: network mobility (moving routers)
Mobile and Wireless Networking 2013 / 2014
16
Mobile ad hoc networks
Standard Mobile IP needs an infrastructure
Home Agent/Foreign Agent in the fixed network DNS, routing etc. are not designed for mobility
Sometimes there is no infrastructure!
remote areas, ad-hoc meetings, disaster areas cost can also be an argument against an infrastructure!
Main topic: routing
no default router available every node should be able to forward
A B C
Mobile and Wireless Networking 2013 / 2014
Addressing & forwarding in ad-hoc networks
- Broadcast (single hop)
- Beaconing
- Broadcast (multihop)
- Geocast
- Unicast
17
Mobile and Wireless Networking 2013 / 2014
Beaconing
Beaconing:
- periodic single-hop broadcast
Problems:
- risk of overload
- no feedback from medium because of broadcast
Solutions:
adapt load to number of users,
e.g., inter-beacon time / power control
18
Mobile and Wireless Networking 2013 / 2014
Broadcast (multihop)
Broadcast (multihop) Forwarding approach:
flooding: all nodes forward all newly received messages
Problems:
broadcast storm:
redundant transmissions synchronization of transmissions no acks, no feedback from medium
Solutions:
(random) delay before rebroadcasting, not all nodes rebroadcast e.g., distance-based forwarding 19
Mobile and Wireless Networking 2013 / 2014
Geocast
Geocast:
like broadcast,
but packet is only forwarded to certain geographic region
Forwarding approach
flooding to and in region routing to region
+ flooding in region
Problems:
trade-off between
accuracy and efficiency
20
Mobile and Wireless Networking 2013 / 2014
Unicast
Unicast: single destination with known address Forwarding approach
based on routing information 21
Mobile and Wireless Networking 2013 / 2014
Outline of Lecture 10
Mobile transport layer
Motivation Approaches for improvement
Indirect TCP Snooping TCP Mobile TCP Selective retransmission
Recommended TCP improvements
Ad hoc networks
Concept Addressing and forwarding in ad-hoc networks Routing in ad-hoc networks
Problem description DSDV (Destination Sequenced Distance Vector) Ad-hoc On-demand Distance Vector (AODV) DSR (Dynamic Source Routing) Further alternatives
22
Mobile and Wireless Networking 2013 / 2014
23
N1 N4 N2 N5 N3 N1 N4 N2 N5 N3 good link weak link time = t1 time = t2
Routing examples
Routing is a major topic
in principle, every node should be able to forward dynamic topology asymmetric links redundant links: too many links when terminals are close
Mobile and Wireless Networking 2013 / 2014
24
Traditional routing algorithms
Distance Vector
periodic exchange of messages with all physical neighbors that contain
information about who can be reached at what distance (monodirectional)
selection of the shortest path if several paths available
Link State
periodic notification of all routers about the current state of all physical
links (bidirectional)
router get a complete picture of the network
Mobile and Wireless Networking 2013 / 2014
25
Problems of traditional routing algorithms
Dynamic of the topology
frequent changes of connections, connection quality, participants
Limited performance of mobile systems
periodic updates of routing tables need energy without contributing
to the transmission of user data, sleep modes difficult to realize
limited bandwidth of the system is reduced even more due to the
exchange of routing information
links can be asymmetric, i.e., they can have a direction dependent
transmission quality
Problem
protocols have been designed for fixed networks with infrequent
changes and typically assume symmetric links
Mobile and Wireless Networking 2013 / 2014
26
Ad hoc routing algorithms
Pro-active
Example:
Destination Sequenced Distance Vector (DSDV)
Re-active
Example:
Ad-hoc On-demand Distance Vector (AODV) Dynamic Source Routing (DSR)
Mobile and Wireless Networking 2013 / 2014
27
DSDV (Destination Sequenced Distance Vector)
Extension of distance vector routing Sequence numbers for all routing updates
assures in-order execution of all updates avoids loops and inconsistencies
Decrease of update frequency
store time between first and best announcement of a path inhibit update if it seems to be unstable (based on the stored time
values) See [Schiller] for details
Mobile and Wireless Networking 2013 / 2014
Ad-hoc On-demand Distance Vector (AODV)
- Specified in IETF: RFC 3561
- Forms the basis for DYMO
(Dynamic On-demand MANET routing protocol) which is a planned IETF reactive routing protocol.
- Uses destination sequence numbers to avoid loops, and ensure
proper updating of routes
- Storage of routes in Route Table
- Uses only symmetric links
28
Mobile and Wireless Networking 2013 / 2014
Route Discovery
- Source broadcasts Route Request (RREQ):
<Source_Addr, Source_Seq#, Broadcast_ID, Dest_Addr, Dest_Seq#, Hop_Count>
- A node can reply to the RREQ if
- It is the destination
- It has a “fresh enough” route
to the destination
- Otherwise it rebroadcasts the RREQ
- Nodes keep track of
<Source_Addr, Broadcast_ID> and discard redundant broadcasts
29
Source Destination
Route Request Propagation
Source: Perkins & Royer
Mobile and Wireless Networking 2013 / 2014
Reverse Path Setup
- Nodes update their Route Table with
source node information before forwarding RREQ
- Reverse path entry used to forward
Route Reply (RREP) back to source if one is received
- Expiration time is long enough for
a RREP to be received and forwarded
30
with
Source Destination
Reverse Path Formation
ce
Mobile and Wireless Networking 2013 / 2014
Forward Path Setup
- Destination, or intermediate node with current route to
destination, unicasts Route Reply (RREP) back to source:
<Source_Addr, Dest_Addr, Dest_Seq#, Hop_Count, Lifetime>
- Nodes along path record forward route
in Route Table, use reverse route to forward RREP
- Source can begin sending data
when it receives first RREP
- If it later receives a RREP
with better metric, it updates its route entry
31
Source Destination
Forward Path Formation
Mobile and Wireless Networking 2013 / 2014
Destination A
Next Hop Active Upstream Neighbors
Source Source
Number
Route Table
- Fields:
- Destination IP Address
- Destination Sequence Number
- HopCount
- Next Hop IP Address
- Active Neighbors
- Expiration time
- Each time a route entry is used to transmit data, the expiration
time is updated to current time + active_route_timeout
- Route entries may be updated if a route with greater sequence
number or smaller hopcount is discovered
32
Mobile and Wireless Networking 2013 / 2014
Path Maintenance
- Movement of nodes not along active path
does not trigger protocol action
- If source node moves, it can reinitiate route discovery
- When destination or intermediate node moves,
node upstream of break sends unsolicited RREP to all active upstream neighbors
- ∞ metric, incremented Seq#
- Used to flush stale routes
- RREP is propagated to their active neighbors,
and so on back to source
- Source can reinitiate route discovery if route is still needed
- RREQs for reinitiated route discovery contain destination
sequence number of one greater than last known number
33
Mobile and Wireless Networking 2013 / 2014
Path Maintenance (example)
- Node 3 moves to new location 3’
- Node 2 notices loss of link, sends link failure to Node 1
- Node1 forwards link failure to Source
- Source reinitiates route discovery,
finds new route through Node 4
34
Source Destination 1 2 3 3’ 4 4
The Initial Route After Route Reconstruction
Source Destination 1 2 3’ 4 4
Mobile and Wireless Networking 2013 / 2014
Local Connectivity Management
- Node must periodically hear from active neighbors to know they
are still within range
- Eavesdrop on neighbor transmissions
- If no other transmissions within hello_interval, broadcast
Hello packet
- Failure to hear from a neighbor for
(1+ allowed_hello_loss) * hello_interval
indicates loss of link
35
Mobile and Wireless Networking 2013 / 2014
Optimizations
- Expanding Ring Search
- by limiting TTL at first attempt,
and increasing it at successive attempts.
- RREP generated by intermediate node
- nly if Seq# for route to destination ≥ Dest_Seq# of RREQ
- Maintaining Local Connectivity by means of layer 2 info.
- Local Repair
- node upstream of link failure tries to find
a new route to destination by sending a RREQ (with reduced TTL, and incremented Dest_Seq#)
36
Mobile and Wireless Networking 2013 / 2014
DSR (Dynamic Source Routing)
- Similar to AODV
- Big difference:
- DSR uses Source Routing
- AODV relies on storing routing table entries in intermediate nodes
RREQ and RREP carry addresses of all intermediate nodes
See [Schiller] for details
37
Mobile and Wireless Networking 2013 / 2014
38
A plethora of ad hoc routing protocols
Flat
proactive DSDV – Destination Sequenced Distance Vector FSLS – Fuzzy Sighted Link State FSR – Fisheye State Routing OLSR – Optimised Link State Routing Protocol TBRPF – Topology Broadcast Based on Reverse Path Forwarding
reactive
DSR – Dynamic Source Routing AODV – Ad hoc On demand Distance Vector
Hierarchical
CGSR – Clusterhead-Gateway Switch Routing HSR – Hierarchical State Routing LANMAR – Landmark Ad Hoc Routing ZRP – Zone Routing Protocol
Geographic position assisted
DREAM – Distance Routing Effect Algorithm for Mobility GeoCast – Geographic Addressing and Routing GPSR – Greedy Perimeter Stateless Routing LAR – Location-Aided Routing