Protocols for Improving Performance of TCP over Wireless Links Presented by Syed Natif Nawaz Joseph Toney Introduction Advances in wireless communication and the decreasing size and the cost of computing units have triggered an explosive growth for the mobile computing market. A mobile host is connected to a base station through a low bandwidth, high latency and error prone wireless channel. Base stations are connected to the rest of the network through the high bandwidth, low latency and relatively error free wired links. Bit Error Rate(BER) a wireless channel is 10-3 - 10-5, while that of wired link is 10-8 - 10-10 or better Contd... The transmission quality is further degraded by hand-off related intermitted delay or loss of the connection as the mobile user moves from the transmission range of one base station to that of another. Design of TCP has to take into account the heterogeneous nature of the network. Necessity to improve the performance of TCP in a wireless environment When used in wireless environment, the TCP developed for fixed networks with relatively reliable links wrongly assumes segment loss due to wireless link errors to be a sign of network congestion and invokes congestion control mechanisms that curb the flow of segments on that connection, because of which the throughput is affected badly. For a better throughput, a segment loss due to wireless link errors must be detected and retransmitted as quickly as possible. Protocols Many approaches have been proposed to improve the performance of TCP over networks with wireless links. These have been broadly categorized as Transport Level Proposals and Link Level Proposals. Various Protocols considered Transport level proposals • Indirect TCP (I-TCP) • MTCP • ESBN • Fast Retransmission contd ... Link Level proposals • Snoop Scheme • CSDP TCP unaware technique Delayed DUPACK’S scheme Indirect TCP I-TCP overcomes by utilizing the resources of MSR’s to provide transport layer communication between mobile hosts and fixed hosts. I-TCP is fully compatible with TCP/IP on fixed network Any interaction between MH & FH are split into two separate interactions. Using I-TCP MH sends a request to current MSR to establish a connection. It uses special I-TCP calls, instead of regular system calls. If the MF switches cells during the life time of an I-TCP connection the center point of the connection moves to new MSR. When the MH switches cells, the states associated with two sockets is handed over. The FH is completely unaware of the indirection. The connection is not re-established at the new MSR. ITCP Architecture Limitations of I-TCP I-TCP violates the semantics of end to end reliability. Application re-linking. Software overhead. Snoop Protocol Proposed by Elan Amir, Hari Balakrishnan, Srinivasan Seshnan & Randy H. Katz - University of California, Berkeley. Improves on Split connection approach by retaining the end to end reliability semantics. Wireless errors are handled by local retransmission at the base station. Reduces interference between TCP retransmission and link level retransmission. The probability of time out at the TCP sender is assumed small Snoop uses features like link level retransmission time out. Snoop Architecture Snoop functions Snoop_output() Types of packets from the fixed host • A new packet in the normal TCP sequence. • An out of sequence packet that has been cached earlier. • An out of sequence packet that has not been cached earlier. State machine for snoop_output Out of Sequence. Already in cache IDLE In sequence/ Send pkt Recv pkt/In cache SEND Snoop_input() Types of ACK’s from the Mobile host • • • • A spurious ACK A DUPACK A New ACK Time Out State machine for snoop_input Recv Dupack NEWACK New Ack IDLE SPURIOUS ACK TIMEOUT DUPACK DELAYED DUPACK’S SCHEME It is preferred over snoop when encryption is used. It is a TCP unaware scheme. The base station implements a link level retransmission scheme for lost packets . Link level ack’s are used to trigger link level retransmission TCP receiver reduces interference between TCP and link level retransmission by delaying third and subsequent dupacks for interval d. TCP receiver responds to the first two OOO packets by sending dupacks immediately. Dupacks for further consecutive packets are delayed for duration d Delayed Dupack Scheme Two types of packet losses and the selection of d A Packet is lost due to transmission errors on the wireless link. A packet is lost due to congestion before reaching the wireless link. Performance results of various schemes WTCP Proposed by Karunaharan Ratnam & Ibrahim Matta Northeastern University. Main feature: Requires no modification to the TCP code that runs in Mobile host/Fixed Host. This is an important advantage because in a fixed network, modifying the TCP installations in a millions of existing hosts is not possible. TCP end to end semantics is maintained. WTCP Architecture A WTCP buffer is maintained in the base station. TCP segments that arrive for a mobile host are first queued in the WTCP buffer. If the segment is the next segment expected, then it is stored in the WTCP buffer along with it’s arrival time. The sequence number for the next segment expected from the fixed host is increased by the number of bytes received. If the segment received has a larger sequence number than what is expected, the segment is buffered. The received segment is discarded if it’s sequence number is smaller than what is expected. WTCP maintains the state information for the wireless connection such as transmission window, sequence number of last acknowledgement received from mobile host and the sequence number of the last segment that was sent to the mobile host. Each time, WTCP locally retransmits, the time stamp is incremented by the amount of time, the segment has spent in the WTCP buffer. WTCP acknowledges a segment sent to the fixed host only after the mobile host actually receives and acknowledges the segment. The round trip time seen by the source is the actual round trip time taken by a segment to reach and return from a mobile host. Performance of WTCP during retransmissions Based on duplicated acknowledgment or time out, the base station locally retransmits lost segments. In case of time -outs transmission window size is reduced to one segment and so potentially wasteful wireless transmission is avoided and interference with other channels is reduced. In the regular TCP, the transmission window is opened, based on whether the connection is in slow start or a congestion avoidance phase. WTCP however, opens the wireless transmission completely assuming that an acknowledgement indicates that wireless link is in a good state. Contd ... When the base station detects a lost segment, it retransmits, (without invoking congestion control, unlike normal TCP). However, until the mobile host receives the lost segment, the reception of each our of order segment will generate a duplicate acknowledgement, the number of which can be determined by the base station and it ceases to retransmit. Effect of Local Retransmissions on RTT Estimation Inaccurate RTT estimation can cause unnecessary retransmissions by triggering time outs. Sender writes the current time stamp of the segment that generated it and the receiver echoes it back, without modifying it. However when an intermediate host buffers the segments and locally retransmits them, RTT computation can be affected If a segment gets retransmitted at the base station, RTT value computed at the source for this segment will overshoot by the residence time in the WTCP buffer. For hiding the LRT, there are two approaches. Base station subtracts the actual LRT by modifying the time stamp field of each acknowledgement forwarded to the source. • But this is not feasible!, as the clock granularity of source and base station may not be identical. After retransmission from BS, time stamp of packets transmitted to the MH • replaced by time stamp of most recent packet received from source after latest retransmission. • Invalidated, if no packet is received from source after retransmission. Simulation Model Tool Used: ns1.2a3 from LBL Simulated Network 10 Mbps 800 kbps 10 ms 100 ms Fixed Host (Source) Base Station Mobile Host Simulation parameters Parameter Value Max window size Buffer Size at BS Segment Size(including header) BER in good state BER in bad state Mean good period 10 Kb 20 Kb 1Kb 10-2 10-6 1 sec Simulation Results Effect of hiding LRT Explicit Bad State Notification General Scenario: In most bad periods, local recovery at the base station prevents packet losses on the wireless link. However the source may still time out waiting for acknowledgement of packets that have already been sent. Explicit Feedback Explicit feedback from the base station can completely eliminate the possibility of time outs occuring at the source, while the wireless link is in a bad state. The use of explicit feedback for congestion control in the internet is known to work well in the form of ICMP source quench messages. So when a wireless links enters a bad state, a base station configured to function as a gateway supporting ICMP messages, sends a source quench message to the source and is expected to prevent unnecessary time outs. This should improve the goodput as well as throughput, for the connection but the results have been shown to be otherwise. A source quench message from the base station will not be able to prevent time out of packets that are already on the network. It will of course stem the flow of any further packets and reduce the probability of timeouts. An important observation here is the timeout of packets that have already been sent to the base station have too be avoided. A mechanism to thwart the source's attempts to invoke congestion control in response to delays on the wireless links. EBSN To avoid source time out, the BS cannot send acknowledgements of the packets not sent to the MH, back to the source. Neither can acknowledgements of previously acknowledged packets be sent, because they will be interpreted as duplicate acknowledgements. Solution is to send a EBSN. EBSN causes the previous time out to be canceled and a new time out put in place, based on the existing estimate of round trip time and variance. The correct time out a value at the source is readjusted from the MH following the receipt of the first new acknowledgement from the MH, following any EBSN message received. A new acknowledgement is an indicator that the link has finally arrived at a good state and this will ensure steady inflow of acknowledgements. Advantages & Disadvantages of EBSN Advantages: Source time out is prevented during local recovery. Improves goodput and throughput of the connection. Effect of clock on performance is reduced. Disadvantages Requires modification of TCP code at source. Other schemes MTCP Similar to I-TCP except that the last TCP byte of data is acknowledged to the source only after it is received by the mobile host. Source falsely believes that every byte of data except the last byte is received by the receiver, it can take remedial measures based on whether the last byte is received or not. Fast Retransmission Addresses the issue of mobile host hand off. During mobile host hand off TCP segments can be lost or delayed. The Mobile host has to unnecessarily wait for a long duration for the source to retransmit. In fast retransmit, the IP in mobile host triggers TCP to generate a certain number of duplicate acknowledgements, causing the source to retransmit the lost segment without waiting for the time out period to expire. This requires modification to the TCP code at the mobile host. Channel State Dependent Packet Scheduling Pure link layer approach. FIFO scheduling of data in links with bursty losses yields poor utilization of the channel. A set of algorithms are provided to enhance the channel utilization based on the arrival time of the packet, whether it is a new packet or retransmission and the length of each output queue. Conclusion Various Link Layer and Transport Level proposals for improving the performance of TCP over Wireless Links have been studied. I-TCP Snoop Scheme WTCP EBSN Delayed Dupack Schemes. References Karunaharan Ratnam and Ibrahim Matta. WTCP:An Efficient Transmission Control Protocol for Networks with Wireless Links. Technical Report NUCCS-97-11, Northeastern University. July 1997. Nitin Vaidya, Miten Mehta, Charles Perkins and Gabriel Montenegro. Delayed Duplicate Acknowledgements: A TCP-Unaware Approach to Improve Performance of TCP over Wireless. Technical Report 99-003, February 1999. Ajay Bakre and B.R. Badrinath. I-TCP: Indirect TCP for Mobile Hosts.DCSTR-314, Rutgers University, October 1994. Elan Amir, Hari Balakrishnan, Srinivasan Seshan and Randy H. Katz. Efficient TCP over Wireless Links. Bikram S. Bakshi, P. Krishna, N.H. Vaidya and D.K. Pradhan. Improving Performance of TCP over Wireless Networks. Texas A & M University.