540 likes | 668 Views
Wireless Network & TCP. Dr. Chan Mun Choon School of Computing, NUS Jan 30, 2004 CS 5229 . Admin. About Me Joined SOC Dec 2003 Member of Technical Staff in Bell Labs, Lucent Technologies from 1997- 2003 Office: S16 #04-07 Dr. Shorey will meet students on Feb 6 to talk about projects.
E N D
Wireless Network & TCP Dr. Chan Mun Choon School of Computing, NUS Jan 30, 2004 CS 5229 1 Chan, M.C.
Admin • About Me • Joined SOC Dec 2003 • Member of Technical Staff in Bell Labs, Lucent Technologies from 1997- 2003 • Office: S16 #04-07 • Dr. Shorey will meet students on Feb 6 to talk about projects 2 Chan, M.C.
Overview • Wireless Networks • Cellular Network • Wireless Local Area Network • TCP over Wireless Networks • Problems with TCP congestion control • Solutions 3 Chan, M.C.
Wireless Comes of Age • Guglielmo Marconi invented the wireless telegraph in 1896 • Communication by encoding alphanumeric characters in analog signal • Sent telegraphic signals across the Atlantic Ocean • Communications satellites launched in 1960s • Advances in wireless technology • Radio, television, mobile telephone 4 Chan, M.C.
Evolution of Cellular Wireless Network • First Generation • Analog • AMPS: North America • Second Generation • TDMA • GSM (SingTel/M1, Europe, AT&T) • NA-TDMA IS-136 (AT&T) • CDMA (U.S.A.) • Third Generation • WCDMA (Europe, Singapore) • CDMA2000 (U.S.A.) • Fourth Generation • OFDM, WLAN ??? 5 Chan, M.C.
First Generation Analog System • First Generation • Advanced Mobile Phone Service (AMPS) • Provide analog traffic channels • Developed by AT&T in 1970s • Early deployment in 1980s • > 40 million users in 1997 6 Chan, M.C.
Going Beyond First Generation • Capacity • Increase capacity by operating with smaller cells, add spectrum, and/or use new technology to improve spectrum efficiency • Roaming • Requires information transfer and business arrangement between systems • Introduce IS-41 • Security • AMPS authentication procedures are weak • Introduce robust network security technology based on encryption and secure key distribution • Support for non-voice services 7 Chan, M.C.
Second Generation System • Introduced in the early 1990s • Digital traffic channel instead of analog • Since data and control traffic are sent in digital form: • Encryption of traffic is simple • Error detection and corrections can be applied, voice reception quality can be better • Multiple channels per cell, as well as multiple users per channel (through TDMA or CDMA) 8 Chan, M.C.
Third Generation Systems • Provides high-speed wireless communication for multimedia • Voice: quality comparable to PSTN • Data: 144kpbs for high-speed user (driving), 384kpbs for slowly moving user (walking) and 2.048Mbps for stationary user • CDMA-based 3G systems more widely accepted • CDMA 2000 in US • UMTS in Europe • 2.5G Systems • EDGE, GPRS (GSM) • 3G1x (2G CDMA) 9 Chan, M.C.
Multiple Access • Wireless channel is broadcast channel, need to separate the desired signal from interfering signals • Earliest approach is frequency division multiple access (FDMA) 10 Chan, M.C.
FDMA (Frequency Division Multiple Access) • Similar to broadcast radio and TV, assign a different carrier frequency per call • Modulation technique determines the required carrier spacing • Each communicating wireless user gets his/her own carrier frequency on which to send data • Need to set aside some frequencies that are operated in random-access mode to enable a wireless user to request and receive a carrier for data transmission 11 Chan, M.C.
TDMA(Time Division Multiple Access) • Each user transmits data on a time slot on multiple frequencies • A time slot is a channel • A user sends data at an accelerated rate (by using many frequencies) when its time slot begins • Data is stored at receiver and played back at original slow rate 1 2 3 4 1 2 3 4 12 Chan, M.C.
Hybrid FDMA/TDMA TDMA Carrier Frequency Frequency Time Time Frequency vs. time FDMA Frequency Time • In practical systems, TDMA is often combined with FDMA 13 Chan, M.C.
Duplex techniques • Separates signals transmitted by base stations from signals transmitted by terminals • Frequency Division Duplex (FDD): use separate sets of frequencies for forward and reverse channels (upstream and downstream) • Time Division Duplex (TDD): same frequencies used in the two directions, but different time slots 14 Chan, M.C.
Examples • FDD: • Cellular systems: AMPS, NA-TDMA, CDMA, GSM • TDD • Cordless telephone systems: CT2, DECT, PHS 15 Chan, M.C.
Frequency Band Usage 16 Chan, M.C.
Frequency Bands Usage Example 17 Chan, M.C.
Issues • Cellular networks have been traditionally designed mainly for voice applications. Next generation high speed wireless networks are expected to be data-centric. What are some of the components or assumptions that needs to be changed? 18 Chan, M.C.
Wireless MAC protocols Wireless MAC protocols Fixed-assignment schemes (GSM) Random-access schemes (802.11) Demand assignment schemes (HDR) Circuit-switched CL packet-switched CO packet-switched 19 Chan, M.C.
Random access MAC protocols • Comparable to connectionless packet-switching • No reservations are made; instead a wireless endpoint simply starts sending data packets • Access to control channels in GSM uses random access protocols • 802.11 uses CSMA/CA 20 Chan, M.C.
CSMA • Carrier Sense Multiple Access • sense carrier • if idle, send • wait for ack • If there isn’t one, assume there was a collision, retransmit 21 Chan, M.C.
Hidden Terminal Problem A can hear B but not C and D B can hear A and C but not D C can hear B and D but not A B D A C C cannot detects transmission from A and thus CSMA does not work when C starts transmission to B 22 Chan, M.C.
Mechanisms for CA • Use of Request-To-Send (RTS) and Confirm-to-Send (CTS) mechanism • When a station wants to send a packet, it first sends an RTS. The receiving station responds with a CTS. Stations that can hear the RTS or the CTS then mark that the medium will be busy for the duration of the request (indicated by Duration ID in the RTS and CTS) • Stations will adjust their Network Allocation Vector (NAV): time that must elapse before a station can sample channel for idle status • this is called virtual carrier sensing • RTS/CTS are smaller than long packets that can collide 23 Chan, M.C.
Exposed Terminal Problem A can hear B but not C and D B can hear A and C but not D C can hear B and D but not A D can hear C but not A and B B D RTS CTS CTS A C C cannot transmit to B even if it will not interfere with transmission from B to A. As a result, network throughput is reduced. 24 Chan, M.C.
IEEE 802 Protocol Layers 25 Chan, M.C.
Protocol Stack 26 Chan, M.C.
802.11 MAC • IEEE 802.11 combines a demand-assignment MAC protocol with random access • PCF (Point Coordination Mode) – Polling • CFP (Contention-Free Period) in which access point polls hosts • DCF (Distributed Coordination Mode) • CP (Contention Period) in which CSMA/CA is used 27 Chan, M.C.
Interframe Space (IFS) Values • Short IFS (SIFS) • Shortest IFS • Used for immediate response actions • Point coordination function IFS (PIFS) • Midlength IFS • Used by centralized controller in PCF scheme when using polls • Distributed coordination function IFS (DIFS) • Longest IFS • Used as minimum delay of asynchronous frames contending for access • SIFS < PIFS < DIFS • e.g. in 802.11, SIFS=28ms, PIFS=78ms, DIFS=128ms, slot time=50ms 28 Chan, M.C.
IFS Usage • SIFS • Acknowledgment (ACK) • Clear to send (CTS) • Poll response • PIFS • Used by centralized controller in issuing polls • Takes precedence over normal contention traffic • DIFS • Used for all ordinary asynchronous traffic 29 Chan, M.C.
DIFS DIFS SIFS CW Random backoff time DCF mode transmission without RTS/CTS • Send immediately (after DIFS) if medium is idle • If medium was busy when sensed, wait a CW after it becomes idle (because many stations may be waiting when medium is busy; if they all send the instant the medium becomes idle, chances of collision are high) Data source Ack destination NAV other Defer access 30 Chan, M.C.
PCF Mode CP CFP CFP Super-frame CF-Burst, asynchronous traffic defers Variable Length • Allows time sensitive data to be transfer using a centralized scheduler (AP) • Makes use of PIFS, and can lock out all asynchronous traffic which uses DIFS (PIFS < DIFS) • Occupies the initial portion of a super-frame; asynchronous traffic contents for the rest of the super-frame 31 Chan, M.C.
IEEE 802.11 Architecture • Access point (AP) • Basic service set (BSS) • Stations competing for access to shared wireless medium • Isolated or connected to backbone DS through AP • Distribution system (DS) • Extended service set (ESS) • Two or more basic service sets interconnected by DS 32 Chan, M.C.
Extended Service Set (ESS) Distribution System (DS) Access points (AP) Basic Service Set (BSS) Infrastructure based architecture • Independent BSS (IBSS): has no AP • adhoc mode; only wireless stations • Infrastructure BSS defined by stations sending Associations to register with an AP 33 Chan, M.C.
Transition Types Based On Mobility • No transition • Stationary or moves only within BSS • BSS transition • Station moving from one BSS to another BSS in same ESS • ESS transition • Station moving from BSS in one ESS to BSS within another ESS 34 Chan, M.C.
TCP over wireless network 35 Chan, M.C.
The “wireless” dimension • Naturally broadcast medium • communications among some hosts are interference for the other hosts • Poor/Unreliable link quality • Harsh environment • continuously changing characteristics: uses adaptation • high error rate: uses FEC-based channel coding • bursty errors due to sudden fades: uses interleaving • Mobility • signal strength varies with location • motion affects signals • must “change” channels during handoff • Low/limited power 36 Chan, M.C.
TCP Overview TCP – connection-oriented reliable transport protocol that adapts to congestion in the network • Assumes that losses are only caused by congestion in the network • Congestion is assumed in the network if TCP sender receives triple duplicate acks or when doesn’t receive acks (timeout ~ RTT) • TCP controls congestion by changing the congestion window size • If there is a loss the sender reduces the window (and its sending rate) alleviating the congestion in the intermediate nodes. TCP always reduces the throughput to alleviate congestion (losses) 37 Chan, M.C.
TCP (Reno) Overview loss (dup. Ack) losses/disconnect ~ linear timeout Slow start Fast retransmission TCP Congestion Window Evolution, AIMD Congestion avoidance phase 38 Chan, M.C.
TCP Overview Losses = congestion is an assumption valid for fixed networks but not for wireless networks • Fading channels have high bit error rate (BER), producing momentary losses that are not caused by congestion and doesn’t necessarily mean a future reduction in available bandwidth • TCP congestion control results in a unnecessary reduction in end-to-end throughput 39 Chan, M.C.
Internet Wireless Network Architecture Most traffic goes from wired network to wireless network Sender Receiver The wireless link is assumed to be the last hop where most of the loss and delay occurs. 40 Chan, M.C.
Transport Layer Loss in Wireless Networks • Transmission errors • Harsh wireless link • Handoffs • Misrouted packets during handoff • Possible in Mobile IP • Mobile transceiver out of range 41 Chan, M.C.
Improving TCP Performance • Solves problem with transmission error over wireless links • Local recovery • End-to-end • Split connection 42 Chan, M.C.
Internet Local Recovery Performs retransmission here if possible without getting TCP involves 43 Chan, M.C.
Local Recovery • Snoop (ACM Mobicom 95) • Caches unacknowledged TCP packets in base station • Performs local retransmission using packets in local cache • Detects packet loss by snooping on sequence number of acknowledgement packets (triple duplicate acks) • Suppress duplicate acks during local retransmission • Works better if transmission time over the wireless link is significantly smaller than the coarse grain TCP timer and round trip time (in LAN environment) • Performance improves through faster retransmission and less TCP congestion control 44 Chan, M.C.
Internet End-to-End Mechanism • Modifies TCP endpoints to differentiate between congestion and transmission loss. • Help from intermediate router/base-station to differentiate between congestion and transmission loss. 45 Chan, M.C.
End-to-end Mechanisms • Explicit Loss Notification • RFC 2481 • Use bit 6 and 7 in TOS field of IP header to indicate congestion • Use some of the 6-bits in the reserved field of TCP header • TCP Hack (INFOCOM 2001) • TCP checksum covers both TCP header and data • Add separate checksum for TCP header • If data is corrupted, it is likely that header is fine since data size is usually much larger than header size • Information in the header can be used to relay to the sender that there is packet error due to transmission error instead of congestion 46 Chan, M.C.
End-to-end MechanismsWTCP • Wireless TCP (INFOCOM’99) • WAN Environment assumed • Non-congestion related packet loss • Very low bandwidth (<19.2Kbps) • Large round trip time (800ms – 4sec) • Asymmetric Channel which leads to ack compression • Occasional blackouts lasting 10s or more 47 Chan, M.C.
WTCP (Cont’d) • Congestion Control • Use the ratio of the actual rate of the sender to the observed rate at the receiver as the primary metric for rate control • Additive increase/multiplicative decrease • If sending rate >> receiving rate, decrease send rate • Else If sending rate << receiving rate, increase send rate • Else maintain • Reliability • SACK • No retransmission time-out. Instead send probe packet to request for highest sequence number received to aid SACK 48 Chan, M.C.
Internet Split Connection Buffer TCP sesssion from sender but terminates on BS A separate transport session between base station and mobile device 49 Chan, M.C.
Split Connection • Indirect-TCP and M-TCP • Split TCP connections into two TCP sessions • One TCP session is from sender (in the wireline network) to “base-station” and the other session from “base-station” to receiver (in the wireless network) • Packets are buffered at the “base-stations” until transmitted across the wireless connection • Assumption is that latency over the wireless network is not a significant part of the end-to-end delay • Violates end-to-end semantics 50 Chan, M.C.