Presentation is loading. Please wait.

Presentation is loading. Please wait.

CMPE 257 Spring 20021 CMPE 257: Wireless and Mobile Networking Spring 2002 Week 6.

Similar presentations


Presentation on theme: "CMPE 257 Spring 20021 CMPE 257: Wireless and Mobile Networking Spring 2002 Week 6."— Presentation transcript:

1 CMPE 257 Spring 20021 CMPE 257: Wireless and Mobile Networking Spring 2002 Week 6

2 CMPE 257 Spring 20022 Announcements Reading assignment 3 due today. Project status report due today. Classroom change for next class: BE 169. Reading assignment 4 due May 17.

3 CMPE 257 Spring 20023 Today Transport layer.

4 CMPE 257 Spring 20024 Transport Layer: Outline TCP/IP basics. Impact of transmission errors on TCP performance. Approaches to improve TCP performance. Classification. Discussion of selected approaches. TCP over satellite. Issues in MANETs.

5 CMPE 257 Spring 20025 Approaches to Improve Performance of TCP in Presence of Transmission Errors

6 CMPE 257 Spring 20026 Classification 1 Based on nature of actions taken to improve performance. Hide error losses from sender. If sender is unaware of the packet losses due to errors, it will not reduce congestion window. Let sender know cause of packet loss. If sender knows that a packet loss is due to errors, it will not reduce congestion window.

7 CMPE 257 Spring 20027 Classification 2 Based on where modifications are needed. At the sender node only. At the receiver node only. At intermediate node(s) only. Combinations of the above.

8 CMPE 257 Spring 20028 Various Schemes [Balakrishnan96] According to classification 1: End-to-end, Sender distinguishes between congestion and non-congestion losses. Split-connection, Hide wireless link from sender. Link-layer approaches. Intermediate approach.

9 CMPE 257 Spring 20029 Link Layer Mechanisms

10 CMPE 257 Spring 200210 Link Layer Mechanisms: Error Correction Example: Forward Error Correction (FEC) [Lin83] can be used to correct limited number of errors. Correctable errors hidden from TCP sender. FEC incurs overhead even when errors do not occur Adaptive FEC schemes can reduce the overhead by choosing appropriate FEC dynamically.

11 CMPE 257 Spring 200211 Link Layer Mechanisms: Link Level Retransmissions Link level retransmission schemes retransmit a packet at the link layer, if errors are detected. Retransmission overhead incurred only if errors occur.

12 CMPE 257 Spring 200212 Link Layer Mechanisms May combine both FEC and retransmissions: Use FEC to correct small number of errors. Use link level retransmission when FEC capability is exceeded.

13 CMPE 257 Spring 200213 Link Level Retransmissions wireless physical link network transport application physical link network transport application physical link network transport application rxmt TCP connection Link layer state

14 CMPE 257 Spring 200214 Link Level Retransmissions Issues How many times to retransmit at the link level before giving up? Finite bound -- semi-reliable link layer. No bound -- reliable link layer. What triggers link level retransmissions? Link layer timeout mechanism. Link level acks (negative acks, dupacks).

15 CMPE 257 Spring 200215 Link Layer Schemes: Summary When is a reliable link layer beneficial to TCP performance? If it provides almost in-order delivery and TCP retransmission timeout large enough to tolerate additional delays due to link level retransmits.

16 CMPE 257 Spring 200216 TCP-Aware Link Layer

17 CMPE 257 Spring 200217 Snoop Protocol [Balakrishnan95] Uses local recovery approach (a la split connection). Link level retransmissions. Differs from split connection schemes: End-to-end semantics retained. Soft state at base station.

18 CMPE 257 Spring 200218 Snoop Protocol FHMHBS wireless physical link network transport application physical link network transport application rxmt Per TCP-connection state TCP connection network link physical

19 CMPE 257 Spring 200219 Snooping Add “snoop” agent to BS routing code. Snoop agent tries to hide losses by doing local retransmissions. Monitors packets (data and ACKs).

20 CMPE 257 Spring 200220 Snoop Agent Buffers data packets at base station. Data sent by FH not yet ack’d by MH. When dupacks received by BS from MH (or local timeout), retransmit on wireless link, if packet in buffer. Times local transmission of selected packets. Prevents fast retransmit at TCP sender FH by suppressing dupacks at BS.

21 CMPE 257 Spring 200221 Snoop_data() 1.Cache packet 2.Forward to mobile. New packet? In-sequence? 1.Mark as congestion loss 2.Forward packet 1.Forward packet 2.Reset local retransmit counter no yes Packet arrives Sender retransmission Congestion loss Common case

22 CMPE 257 Spring 200222 Snoop_ack() New ACK? 1.Free buffers 2.Update RTT estimate 3.Propagate ACK to sender Duplicate ACK? First one? yes ACK arrives Common case no yes Discard no Spurious ACK Later dup ACKs Retransmit lost packet with high priority and discard ACK. Next packet lost yes

23 CMPE 257 Spring 200223 Snoop : Example FHMHBS 40393738 3634 Example assumes delayed ack - every other packet ack’d 36 37 38 35 TCP state maintained at link layer

24 CMPE 257 Spring 200224 Snoop : Example 41403839 3634 36 37 38 3539

25 CMPE 257 Spring 200225 Snoop : Example 42413940 36 Duplicate acks are not delayed 36 dupack 37 38 39 40

26 CMPE 257 Spring 200226 Snoop : Example 40 36 Duplicate acks 414342 37 38 39 40 41

27 CMPE 257 Spring 200227 Snoop : Example FHMHBS 41 36 374443 36 37 38 39 40 41 42 Discard dupack Dupack triggers retransmission of packet 37 from base station BS needs to be TCP-aware to be able to interpret TCP headers

28 CMPE 257 Spring 200228 Snoop : Example 37 36 424544 36 37 38 39 40 41 42 43 36

29 CMPE 257 Spring 200229 Snoop : Example 42 36 434645 36 37 38 39 40 41 42 43 41 36 44 TCP sender does not fast retransmit

30 CMPE 257 Spring 200230 Snoop : Example 43 36 444746 36 37 38 39 40 41 42 43 41 36 44 TCP sender does not fast retransmit 45

31 CMPE 257 Spring 200231 Snoop : Example FHMHBS 44 36 454847 36 42 43 41 36 44 45 43 46

32 CMPE 257 Spring 200232 Performance 2 Mbps Wireless link

33 CMPE 257 Spring 200233 Snoop Protocol: Advantages Snoop prevents fast retransmit from sender despite transmission errors and out-of-order delivery on the wireless link. If wireless link level delay-bandwidth product less than 4 packets, simple (TCP- unaware) link level retransmission scheme can suffice. Since delay-bandwidth product is small, retransmission scheme can deliver lost packet without causing MH to send 3 dupacks.

34 CMPE 257 Spring 200234 Snoop Protocol: Advantages Higher throughput can be achieved. Performance further improved using sack’s. Local recovery from wireless losses. Fast retransmit not triggered at sender despite out-of-order link layer delivery. End-to-end semantics retained. Soft state at base station Loss of the soft state affects performance, but not correctness.

35 CMPE 257 Spring 200235 Snoop Protocol:Disadvantages Link layer at base station needs to be TCP-aware. Scalability: state kept at BS grows with number of TCP flows. Not useful if TCP headers are encrypted (IPsec). Cannot be used if TCP data and TCP acks traverse different paths.

36 CMPE 257 Spring 200236 Snoop Protocol : Classification Link-layer approach: tries to hide wireless losses from sender. Requires modification to only BS (network-centric approach).

37 CMPE 257 Spring 200237 Delayed Dupacks Approach TCP-Unaware Approximation of TCP-Aware Link Layer. Attempts to imitate Snoop without making BS TCP-aware. Snoop implements two features at BS: Link layer retransmission. Dupack handling: reduced interference between TCP and link layer retransmissions (drop dupacks).

38 CMPE 257 Spring 200238 Delayed Dupacks Implements same two features: at BS : link layer retransmission. at MH : reducing interference between TCP and link layer retransmissions (by delaying dupacks).

39 CMPE 257 Spring 200239 Delayed Dupacks Protocols TCP receiver delays dupacks (third and subsequent) for interval D, when out-of-order packets received. Dupack delay intended to give link level retransmit time to succeed. Benefit: Delayed dupacks can result in recovery from a transmission loss without triggering a response from the TCP sender. Disadvantage: Recovery from congestion losses delayed.

40 CMPE 257 Spring 200240 Delayed Dupacks Protocols Delayed dupacks released after interval D, if missing packet not received. Link layer maintains state to allow retransmission. Link layer state is not TCP-specific

41 CMPE 257 Spring 200241 Delayed Dupacks: Example 40393738 3634 Example assumes delayed ack - every other packet ack’d Link layer acks are not shown 36 37 38 35 Link layer state

42 CMPE 257 Spring 200242 Delayed Dupacks: Example BS 41403839 3634 36 37 38 39 35 Removed from BS link layer buffer on receipt of a link layer ack (LL acks not shown in figure)

43 CMPE 257 Spring 200243 Delayed Dupacks: Example 42413940 36 Duplicate acks are not delayed 36 dupack 37 38 39 40

44 CMPE 257 Spring 200244 Delayed Dupacks: Example 40 36 Duplicate acks 414342 37 38 39 40 41 Original ack

45 CMPE 257 Spring 200245 Delayed Dupacks: Example 41 36 374443 36 37 39 40 41 42 Base station forwards dupacks dupackdupacks Delayed dupack

46 CMPE 257 Spring 200246 Delayed Dupacks: Example 37 36 424544 36 37 40 41 42 36 dupacks Delayed dupacks 43

47 CMPE 257 Spring 200247 Delayed Dupacks : Example 42434645 36 37 41 42 43 41 TCP sender does not fast retransmit 44 Delayed dupacks are discarded if lost packet received before delay D expires

48 CMPE 257 Spring 200248 Delayed Dupacks [Vaidya99] 2 Mbps wireless duplex link with 20 ms delay No congestion losses 20 ms 10 Mbps2 Mbps

49 CMPE 257 Spring 200249 Delayed Dupacks [Vaidya99] 5% packet loss due to congestion 20 ms 10 Mbps2 Mbps

50 CMPE 257 Spring 200250 Delayed Dupacks Scheme: Advantages Link layer need not be TCP-aware. Can be used even if TCP headers are encrypted. Works well for relatively small wireless RTT (compared to end-to-end RTT). Relatively small D sufficient in such cases.

51 CMPE 257 Spring 200251 Delayed Dupacks Scheme: Disadvantages Right value of dupack delay D dependent on wireless link properties. Mechanisms to determine D needed. Delays dupacks for congestion losses too, delaying congestion loss recovery.

52 CMPE 257 Spring 200252 Various Schemes End-to-end, Split-connection, Link-layer approaches.

53 CMPE 257 Spring 200253 Split Connection Approach

54 CMPE 257 Spring 200254 Split Connection Approach End-to-end TCP connection is broken into one connection on the wired part of route and one over wireless part.

55 CMPE 257 Spring 200255 Split Connection Approach Connection between wireless host MH and fixed host FH goes through base station BS. FH-MH = FH-BS + BS-MH FHMHBS Base StationMobile Host Fixed Host

56 CMPE 257 Spring 200256 Split Connection Approach Split connection results in independent control for the two parts. Congestion/error control protocols, packet size, time-outs, may be different for each part. FHMHBS Base StationMobile Host Fixed Host

57 CMPE 257 Spring 200257 Split Connection Approach wireless physical link network transport application physical link network transport application physical link network transport rxmt Per-TCP connection state TCP connection

58 CMPE 257 Spring 200258 Split Connection Approach: Classification Hides transmission errors from sender. Primary responsibility at base station.

59 CMPE 257 Spring 200259 Indirect TCP [Bakre94] FH - BS connection : standard TCP. BS - MH connection : standard TCP. Handoff.

60 CMPE 257 Spring 200260 Split Connection: Advantages BS-MH connection can be optimized independent of FH-BS connection. Different congestion/error control. Local recovery of errors. Faster recovery. Good performance achievable using appropriate BS-MH protocol. Standard TCP on BS-MH performs poorly when multiple packet losses per window. Selective ACKs improve performance.

61 CMPE 257 Spring 200261 Split Connection: Disadvantages End-to-end semantics violated. ACK may be delivered to sender before data delivered to receiver. FHMHBS 40 39 3738 36 40

62 CMPE 257 Spring 200262 Split Connection: Disadvantages BS retains hard state. BS failure can result in loss of data. If BS fails, packets 39 and 40 will be lost. Both ack’d to sender;sender does not buffer. FHMHBS 40 39 3738 36 40

63 CMPE 257 Spring 200263 Split Connection: Disadvantages BS retains hard state. Hand-off latency increases due to state transfer Data that has been ack’d to sender must be moved to new base station.

64 CMPE 257 Spring 200264 Handoff FHMHBS 40 39 3738 36 40 MH New base station Hand-off 40 39

65 CMPE 257 Spring 200265 Split Connection: Disadvantages Buffer space needed at BS for each TCP connection. BS buffers tend to get full, when wireless link slower (one window worth of data on wired connection could be stored at the base station for each split connection). Extra copying of data at BS Copying from FH-BS socket buffer to BS-MH socket buffer. Increases end-to-end latency.

66 CMPE 257 Spring 200266 Split Connection: Disadvantages May not be useful if data and acks traverse different paths. Example: data on a satellite wireless hop, acks on a dial-up channel. FHMH data ack BS

67 CMPE 257 Spring 200267 Various Schemes End-to-end Explicit notification Receiver-based discrimination Sender-based discrimination, Split-connection, Link-layer approaches.

68 CMPE 257 Spring 200268 Explicit Notification

69 CMPE 257 Spring 200269 Explicit Notification Schemes General Philosophy Approximate ideal TCP behavior. Ideally, TCP sender should simply retransmit a packet lost due to transmission errors without taking any congestion control actions. A wireless node determines that packets are lost due to errors and informs sender using an “explicit notification”. Sender, on receiving the notification, does not reduce congestion window, but retransmits lost packet.

70 CMPE 257 Spring 200270 Explicit Notification Schemes Motivated by Explicit Congestion Notification (ECN) proposals [Floyd94]. Variations proposed in literature differ in: Who sends explicit notification. How they know to send explicit notification. What sender does on receiving notification.

71 CMPE 257 Spring 200271 Explicit Loss Notification [Balakrishnan98] MH is the TCP sender. Wireless link first on path from sender to receiver. Base station keeps track of holes in packet sequence. When a dupack is received from the receiver, BS compares the dupack sequence number with recorded holes. If there is a match, an ELN bit is set in dupack. Dupack with ELN set

72 CMPE 257 Spring 200272 ELN When sender receives dupack with ELN set, it retransmits packet, but does not reduce congestion window. MHFHBS 4321134 wireless Record hole at 2 11 11

73 CMPE 257 Spring 200273 Explicit Loss Notification [Biaz99thesis] Adapts ELN proposed in [Balakrishnan96] for the case when MH is receiver. Caches TCP sequence numbers at base station, similar to Snoop. But does not cache data packets, unlike Snoop. Duplicate acks are tagged with ELN bit before being forwarded to sender if sequence number for the lost packet is cached at BS. Sender takes appropriate action on receiving ELN.

74 CMPE 257 Spring 200274 ELN [Biaz99thesis] 37 36 37 3839 38 Sequence numbers cached at base station 37 Dupack with ELN

75 CMPE 257 Spring 200275 Explicit Bad State Notification [Bakshi97] MH is TCP receiver. BS attempts to deliver packets to MH using link layer retransmission scheme. If packet cannot be delivered using small number of retransmissions, BS sends a Explicit Bad State Notification (EBSN) message to TCP sender. When TCP sender receives EBSN, it resets RTO. Timeout delayed when wireless channel in bad state.

76 CMPE 257 Spring 200276 Partial Ack Protocols [Cobb95][Biaz97] Send two types of acknowledgements. Partial ACK informs sender that a packet was received by an intermediate host (typically, base station). Normal TCP cumulative ACK needed by sender for reliability purposes.

77 CMPE 257 Spring 200277 Partial Ack Protocols When packet for which partial ack is received detected to be lost, sender does not reduce its congestion window Loss assumed to be due to wireless errors. 37 36 Partial ack 37 Cumulative ack

78 CMPE 257 Spring 200278 Variations Base station may or may not locally buffer and retransmit lost packets.

79 CMPE 257 Spring 200279 Receiver-Based Discrimination Scheme

80 CMPE 257 Spring 200280 Receiver-Based Scheme [Biaz98Asset] MH is TCP receiver. Receiver uses heuristics to guess cause of packet loss. When receiver believes that packet loss is due to errors, it sends notification to sender. TCP sender, on receiving notification, retransmits lost packet, without reducing congestion window.

81 CMPE 257 Spring 200281 Heuristics Receiver uses inter-arrival time between consecutively received packets to guess cause of packet loss. On determining a packet loss as being due to errors, the receiver may: Tag corresponding dupacks with an ELN bit, or Send an explicit notification to sender.

82 CMPE 257 Spring 200282 Receiver-Based Scheme Packet loss due to congestion FHMHBS 101211 FHMHBS 11 1012 T Congestion loss

83 CMPE 257 Spring 200283 Receiver-Based Scheme Packet loss due to transmission error FHMHBS 101211 FHMHBS 101112 Error loss 2 T

84 CMPE 257 Spring 200284 Sender-Based Discrimination Scheme

85 CMPE 257 Spring 200285 Sender-Based Discrimination [Biaz98ic3n,Biaz99techrep] Sender can attempt to determine cause of a packet loss If packet loss determined to be due to errors, do not reduce congestion window Sender can only use statistics based on round-trip times, window sizes, and loss pattern. Unless network provides more information (example: explicit loss notification)

86 CMPE 257 Spring 200286 Heuristics for Congestion Avoidance Define condition C as a function of congestion window size and observed RTTs. Condition C evaluated for new RTT. If (C == True) reduce congestion window.

87 CMPE 257 Spring 200287 Heuristics for Congestion Avoidance: Some proposals TCP Vegas [Brakmo94] expected throughput ET = W(i) / RTTmin actual throughput AT = W(i) / RTT(i) Condition C = ( ET-AT > beta)

88 CMPE 257 Spring 200288 Sender-Based Heuristics Record latest value evaluated for condition C When a packet loss is detected: If last evaluation of C is TRUE, assume packet loss due to congestion. Else assume packet loss due to transmission errors. If packet loss determined to be due to errors, do not reduce congestion window

89 CMPE 257 Spring 200289 Sender-Based Heuristics : Disadvantage Does not work quite well enough!! Reason Not much correlation between observed short-term statistics, and onset of congestion.

90 CMPE 257 Spring 200290 Sender-Based Heuristics : Advantages Only sender needs to be modified Needs further investigation to develop better heuristics Investigate longer-term heuristics.

91 CMPE 257 Spring 200291 Transport Layer: Outline TCP/IP basics. Impact of transmission errors on TCP performance. Approaches to improve TCP performance. Classification. Discussion of selected approaches. TCP over satellite. Issues in MANETs.

92 CMPE 257 Spring 200292 TCP Over Satellite

93 CMPE 257 Spring 200293 Satellite Links High bandwidth-delay product. Higher error rates than terrestrial links.

94 CMPE 257 Spring 200294 Improving TCP over Satellite Extension of sequence number space with timestamp option. Larger congestion window (window scale option) Maximum window size up to 2^30 (instead of 2^16) bytes. Acknowledge every packet (do not delay acks). Selective acks Allow multiple packet recovery per RTT and avoid slow-start.

95 CMPE 257 Spring 200295 Some Proposals Space Communications Protocol Standard- Transport Protocol (SCPS-TP) [Durst96]. During link outage, TCP sender freezes itself, and resumes when link is restored Outage assumed to occur in both directions simultaneously Ground station can detect outage of incoming link (for instance, by low signal levels). Sender does not unnecessarily timeout or retransmit until it is informed that link has recovered. Sack to recover losses quickly.

96 CMPE 257 Spring 200296 Some Proposals (Cont’d) Satellite Transport Protocol (STP) [Henderson98] Uses split connection approach. Protocol on satellite channel different from TCP. Sacks when receiver detects losses. Transmitter periodically requests receiver to ack received data. Reduces reverse channel bandwidth usage when losses are rare.

97 CMPE 257 Spring 200297 Some Proposals (Cont’d) TCP Spoofing Early ACKing. A la Snoop TCP. Ground station acks packets Should take responsibility for delivering packets. Early acks from ground station result in faster congestion window growth.

98 CMPE 257 Spring 200298 TCP in Mobile Ad Hoc Networks

99 CMPE 257 Spring 200299 Issues Route changes due to mobility. Wireless transmission errors. Problem compounded due to multiple hops. Out-of-order packet delivery. Frequent route changes may cause OOO delivery. MAC MAC protocol can impact TCP performance.

100 CMPE 257 Spring 2002100 Throughput over Multi-Hop Wireless Paths [Gerla99] When contention-based MAC protocol is used, connections over multiple hops are at a disadvantage compared to shorter connections. They have to contend for wireless access at each hop. Delay or drop probability increases with number of hops.

101 CMPE 257 Spring 2002101 Analysis of TCP Performance over MANETs [Holland99] Impact of mobility. Simulation study. Performance metric: throughput. Baseline: ideal (expected) throughput. Upper bound. Static network.

102 CMPE 257 Spring 2002102 Ideal Throughput f(i) = fraction of time for which shortest path length between sender and destination is I. T(i) = throughput when path length is I (no mobility). Ideal throughput =  f(i) * T(i)

103 CMPE 257 Spring 2002103 Throughput versus Hops TCP throughput over 2 Mbps 802.11 MAC, fixed, linear MANET.

104 CMPE 257 Spring 2002104 Throughput versus speed Speed (m/s) Average Throughput Over 50 runs Ideal Actual Throughput decreases with speed…

105 CMPE 257 Spring 2002105 Throughput versus Speed Mobility pattern # Actual throughput 20 m/s 30 m/s But not always…

106 CMPE 257 Spring 2002106 Impact of Mobility TCP Throughput Ideal throughput (Kbps) Actual throughput 2 m/s10 m/s

107 CMPE 257 Spring 2002107 Impact of Mobility Ideal throughput Actual throughput 20 m/s 30 m/s

108 CMPE 257 Spring 2002108 mobility causes link breakage, resulting in route failure TCP data and acks en route discarded Why Throughput Degrades TCP sender starts sending packets again Route is repaired No throughput despite route repair

109 CMPE 257 Spring 2002109 mobility causes link breakage, resulting in route failure TCP data and acks en route discarded Why Throughput Degrades? TCP sender times out. Backs off timer. Route is repaired TCP sender resumes sending Larger route repair delays especially harmful No throughput despite route repair

110 CMPE 257 Spring 2002110 Why Throughput Improves? Low Speed Scenario C B D A C B D A C B D A 1.5 second route failure Route from A to D is broken for ~1.5 second. When TCP sender times after 1 second, route still broken. TCP times out after another 2 seconds, and only then resumes.

111 CMPE 257 Spring 2002111 Why Throughput Improves? Higher Speed Scenario C B D A C B D A C B D A 0.75 second route failure Route from A to D is broken for ~ 0.75 second. When TCP sender times after 1 second, route is repaired.

112 CMPE 257 Spring 2002112 Why Throughput Improves? General Principle TCP timeout interval somewhat independent of speed. Network state at higher speed, when timeout occurs, may be more favorable than at lower speed. Network state: Link/route status. Route caches. Congestion.

113 CMPE 257 Spring 2002113 How to Improve Throughput Network feedback. Inform TCP of route failure explicitly. Let TCP know when route is repaired. Probing. Explicit notification. Reduces repeated TCP timeouts and backoff.

114 CMPE 257 Spring 2002114 Performance Improvement Without network feedback Ideal throughput 2 m/s speed With feedback Actual throughput

115 CMPE 257 Spring 2002115 Performance Improvement Without network feedback With feedback Ideal throughput 30 m/s speed Actual throughput

116 CMPE 257 Spring 2002116 Performance with Explicit Notification

117 CMPE 257 Spring 2002117 Issues: Network Feedback Network knows best (why packets are lost). + Network feedback beneficial. - Need to modify transport & network layer to receive/send feedback Need mechanisms for information exchange between layers.


Download ppt "CMPE 257 Spring 20021 CMPE 257: Wireless and Mobile Networking Spring 2002 Week 6."

Similar presentations


Ads by Google