Overview 15-441: omputer Networking Lecture 25: Wireless Peter Steenkiste Fall 2010 www.cs.cmu.edu/~prs/15-441-f10 Internet t mobility TP over noisy links Link layer challenges Wireless deployments 2 IEEE 802.11 M Protocol: SM/ ut SM oes Not (lways) Work 802.11 SM: sender - If sense channel idle for ISF (istributed Inter Frame Space) then transmit entire frame (no collision detection) - If sense channel busy then binary backoff 802.11 SM receiver: - If received OK return K after SIFS (Short IFS) - K is needed due to lack of collision detection - SIFS < IFS: priority 3 arrier Sense problems Relevant contention at the receiver, not sender Hidden terminal Exposed terminal Hidden Exposed 4 1
Hidden Terminal Effect ollision voidance Mechanisms Hidden terminals:, cannot hear each other Obstacles, signal attenuation ollisions at ollision if 2 or more nodes transmit at same time ut SM still makes sense: Get all the bandwidth if you re the only one transmitting Shouldn t cause a collision if you sense another transmission ollision detection does not work either SM/: SM with ollision voidance Problem: Two nodes, hidden from each other, transmit complete frames to base station Wasted bandwidth for long duration! Solution: Small reservation packets Nodes track reservation interval with internal network allocation vector (NV) 5 6 RTS/TS pproach efore sending data, send Ready-to-Send (RTS) Target responds with lear-to-send (TS) Others who hear TS defer transmission Packet length in RTS and TS messages Why not defer on RTS alone? If TS is not heard, or RTS collides Retransmit RTS after binary exponential backoff (There are lots of cool details embedded in this last part that went into the design of 802.11 - if you re curious, look up the MW protocol). ollision voidance: RTS-TS Exchange Explicit channel reservation Sender: send short RTS: request to send Receiver: reply with short TS: clear to send TS reserves channel for sender, notifying (possibly hidden) stations RTS and TS short: collisions less likely, of shorter duration end result similar to collision detection void hidden station collisions Not widely used Overhead is too high Not a serious problem in typical deployments 8 2
IEEE 802.11 M Protocol How bout Exposed Terminal? RTS/TS implemented using NV: Network llocation Vector lso used with data packets 802.11 frame has transmission time field Others (hearing data) defer access for NV time units an increase the carriersense threshold Signal needs to be stronger before node defers ould this create other problems? Exposed terminals are difficult to deal with Even hard to detect them! Exposed 9 10 Some IEEE 802.11 Standards IEEE 802.11 Family IEEE 802.11a PHY Standard : 8 channels : up to 54 Mbps : some deployment IEEE 802.11b PHY Standard : 3 channels : up to 11 Mbps : widely deployed. IEEE 802.11d M Standard : support for multiple regulatory domains (countries) IEEE 802.11e M Standard : QoS support : supported by many vendors IEEE 802.11f Inter-ccess Point Protocol : deployed IEEE 802.11g PHY Standard: 3 channels : OFM and P : widely deployed (as b/g) IEEE 802.11h Suppl. M Standard: spectrum managed 802.11a (TP, FS): standard IEEE 802.11i Suppl. M Standard: lternative WEP : standard IEEE 802.11n M Standard: MIMO : standardization expected late 2008 Protocol Release ata Freq. Rate (typical) Rate (max) Range (indoor) Legacy 1997 2.4 GHz 1 Mbps 2Mbps? 802.11a 1999 5 GHz 25 Mbps 54 Mbps 802.11b 1999 2.4 GHz 6.5 Mbps 11 Mbps 802.11g 2003 2.4 GHz 25 Mbps 54 Mbps 802.11n 2008 2.4/5 GHz 200 Mbps 600 Mbps ~30 m ~30 m ~30 m ~50 m 3
802.11b hannels Going Faster: 802.11g In the UK and most of EU: 13 channels, 5MHz apart, 2.412 2.472 GHz In the US: only 11 channels Each channel is 22MHz Significant overlap Non-overlapping channels are 1, 6 and 11 1, 2, 5.5 and 11 Mbps rates using SSS technology 802.11g basically extends of 802.11b Use the same technology SSS for old rates (1,2, 5.5, 11) Uses OFM technology for new rates (6 Mbs and up) Using OFM makes it easier to build 802.11a/g cards Since 802.11a uses OFM ut it creates an interoperability problem since 802.11b cards cannot interpret OFM signals Solutions: send TS using K before OFM packets in hybrid environments, or use (optional) hybrid packet format K Preamble Header K OFM K Payload K OFM OFM 802.11a Physical hannels 802.11a iscussion 36 40 44 48 52 56 60 64 channel# 5150 5180 5200 5220 5240 5260 5280 5300 5320 5350 [MHz] 149 153 157 161 channel# 5725 5745 5765 5785 5805 5825 [MHz] Point-Point Indoor center frequency = 5000 + 5*channel number [MHz] Uses OFM in the 5.2 and 5.7 GHz bands What are the benefits of 802.11a compared with 802.11b? Greater bandwidth (up to 54Mb) 54, 48, 36, 24, 18, 12, 9 and 6 Mbs Less potential interference (5GHz) More non-overlapping channels Less contention due to competition ut does not provide interoperability with 802.11b, as 802.11g does 4
Scenarios and Roadmap d Hoc Networks Point to point wireless networks Example: Your laptop to MU wireless hallenges: Poor and variable link quality (makes TP unhappy) Many people can hear when you talk Pretty well defined. d hoc networks (wireless++) Rooftop networks (multi-hop, fixed position) Mobile ad hoc networks dds challenges: routing, mobility Some deployment + some research Sensor networks (ad hoc++) Scatter 100s of nodes in a field / bridge / etc. dds challenge: Serious resource constraints urrent, popular, research. 17 ll the challenges of wireless, plus some of: No fixed infrastructure Mobility (on short time scales) haotically decentralized (:-) Multi-hop! an be arbitrarily bad: limited batteries, malicious nodes, high mobility, low density,.. Nodes are both traffic sources/sinks and forwarders The big challenge: Routing 18 d Hoc Routing Traditional Routing vs d Hoc Find multi-hop paths through network dapt to new routes and movement / environment changes eal with interference and power issues Scale well with # of nodes Localize effects of link changes Traditional network: Well-structured t ~O(N) nodes & links ll links work ~= well d Hoc network N^2 N2 links - but many stink! Topology may be really weird Reflections & multipath cause strange interference hange is frequent 19 20 5
Forwarding Packets is expensive Throughput of 802.11b =~ 11Mbits/s In reality, you can get about 6 What is throughput of a chain? -> ->? -> -> ->? ssume minimum power for radios. Routing metric should take this into account Problems using V or LS V loops are very expensive Wireless bandwidth << fiber bandwidth LS protocols have high overhead roadcast nature of wireless makes communication expensive Periodic updates waste power Need fast, frequent convergence 21 22 Many Proposed Protocols SR Variants of existing wired protocols Exploiting broadcast nature of wireless Fast recovery from link breaks Improve scalability, e.g. hierarchy On-demand protocols ynamic Source Routing (SR) d Hoc On-emand istance Vector (OV) Geographic routing protocols GPSR Source routing Intermediate t nodes can be out of date On-demand route discovery Only discover a route when you need it void periodic route advertisements esign point: on-demand may be better or worse depending on traffic patterns Examples? 23 24 6
SR omponents Route discovery The mechanism by which a sending node obtains a route to destination Route maintenance The mechanism by which a sending node detects that the network topology has changed and its route to destination is no longer valid SR Route iscovery Route discovery - basic idea Source broadcasts route-request request to estination Each node forwards request by adding own address and re-broadcasting Requests propagate outward until: Target is found, or node that has a route to estination is found 25 26 roadcasts Route Request to F roadcasts Route Request to F Route Request Source E estination F Route Request Source E estination F G H G H 27 28 7
H Responds to Route Request Transmits a Packet to F Source E estination F Source G,H,F E estination F G H G,H,F G H,F H F 29 30 Forwarding Route Requests request is forwarded if: Node is not the destination Node not already listed in recorded source route Node has not seen request with same sequence number IP TTL field may be used to limit scope estination copies route into a Route-reply packet and sends it back to Source Route ache ll source routes learned by a node are kept in Route ache Reduces cost of route discovery If intermediate node receives RR for destination and has entry for destination in route cache, it responds to RR and does not propagate RR further Nodes overhearing RR/RP may insert routes in cache 31 32 8
Sending ata heck cache for route to destination If route exists then If reachable in one hop Send packet Else insert routing header to destination and send If route does not exist, buffer packet and initiate route discovery iscussion Source routing is good for on demand routes instead of a priori distribution Route discovery protocol used to obtain routes on demand aching used to minimize use of discovery Periodic messages avoided ut need to buffer packets How do you decide between links? 33 34 Greedy Perimeter Stateless Routing (GPSR) Use positions of neighboring nodes and packet destination to forward packets No connectivity or global topology is assumed Nodes are assumed to know their location Need some address-to-location look up Two forwarding techniques is used Greedy forwarding, if possible Perimeter forwarding, otherwise GPSR Greedy forwarding sender/forwarder x chooses to forward to a neighbor y such that {d xy + d y } is minimum Xx y 9
GPSR Perimeter forwarding Right Hand Rule traverse an interior i region in clockwise edge order traverse an exterior region in counter-clockwise edge order. w v VOI x z y These sequence of edges traversed is termed as PERIMETER Sensor Networks - smart devices First introduced in late 90 s by groups at U/UL/US Small, resource limited devices PU, disk, power, bandwidth, etc. Simple scalar sensors temperature, motion Single domain of deployment farm, battlefield, bridge, rain forest for a targeted task find the tanks, count the birds, monitor the bridge Example of an ad-hoc wireless network Nodes typically not mobile helps a lot! 38 Sensor System Types Smart- ust/motes Hardware U motes 4 MHz PU 4 k data RM 128 k code 50 kb/sec 917 Mhz radio Sensors: light, temp., Sound, etc., nd a battery. Sensors and power and radios Limited battery life drives most goals Radio is most energy-expensive part. 800 instructions per bit. 200,000 instructions per packet. (!) That s about one message per second for ~2 months if no PU. Listening is expensive too. :( 39 40 10
Sensor nets goals Replace communication with computation Turn off radio receiver as often as possible Keep little state (4 K isn t your pentium 4 ten bazillion gigahertz with five ottabytes of RM). Power Which uses less power? irect sensor -> base station Tx Total Tx power: distance^2 Sensor -> sensor -> sensor -> base station? Total Tx power: n * (distance/n) ^2 =~ d^2 / n Why? Radios are omnidirectional, but only one direction matters. Multi-hop approximates directionality. Power savings often makes up for multi-hop capacity These devices are *very* power constrained! Reality: Many systems don t use adaptive power control. This is active research, and fun stuff. 41 42 Example: ggregation Important Lessons Find avg temp in 8th floor of Wean. Strawman: Flood query, let a collection point compute avg. Huge overload near the P. Lots of loss, and local nodes use lots of energy! etter: in network aggregation key to scaling Take local avg. first, & forward that. Send average temp + # of samples The challenge: How to aggregate. How long to wait? How to aggregate complex queries? How to program? 43 Many assumptions built into Internet design Wireless forces reconsideration of issues Wireless link-layer l Spatial reuse (cellular) vs wires Hidden/exposed terminal SM/ (why?) and RTS/TS d hoc wireless networks Key is routing protocols may proposals exist Mobility, limited capacity are problems On demand can reduce load; broadcast reduces overhead Sensor networks are special purpose ad hoc networks Energy is a key concern: run unattended for long periods of time an trade between computation for communication 44 11
Extra slides ETX Measure each link s delivery probability with broadcast probes (& measure reverse) P(delivery) = 1 / ( df * dr ) (K must be delivered too) Link ETX = 1 / P(delivery) Route ETX = sum of link ETX (ssumes all hops interfere - not true, but seems to work okay so far) Lecture 25:11-30-2006 45 46 apacity of multi-hop network ssume N nodes, each wants to talk to everyone else. What total throughput (g (ignore previous slide to simplify things) O(n) concurrent transmissions. Great! ut: Each has length O(sqrt(n)) (network diameter) So each Tx uses up sqrt(n) of the O(n) capacity. Per-node capacity scales as 1/sqrt(n) Yes - it goes down! More time spent Tx ing other peoples packets ut: If communication is local, can do much better, and use cool tricks to optimize Like multicast, or multicast in reverse (data fusion) Hey, that sounds like a sensor network! 47 12