Top Banner
Review: MAC
38

Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Dec 25, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Review: MAC

Page 2: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-2

Link Layer: Introduction

Terminology:hosts and routers are nodes

communication channels that connect adjacent nodes along communication path are links

wired links wireless links LANs

layer-2 packet is a frame, encapsulates datagram

data-link layer has responsibility of transferring datagram from one node to physically adjacent node over a link

Page 3: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-3

Link layer: context

datagram transferred by different link protocols over different links:

e.g., Ethernet on first link, frame relay on intermediate links, 802.11 on last link

each link protocol provides different services

e.g., may or may not provide rdt over link

transportation analogytrip from Princeton to Lausanne

limo: Princeton to JFK plane: JFK to Geneva train: Geneva to Lausanne

tourist = datagram

transport segment = communication link

transportation mode = link layer protocol

travel agent = routing algorithm

Page 4: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-4

Link Layer Services

framing, link access: encapsulate datagram into frame, adding header, trailer channel access if shared medium “MAC” addresses used in frame headers to identify source,

dest different from IP address!

reliable delivery between adjacent nodes we learned how to do this already (chapter 3)! seldom used on low bit-error link (fiber, some twisted pair) wireless links: high error rates

Q: why both link-level and end-end reliability?

Page 5: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-5

Link Layer Services (more)

flow control: pacing between adjacent sending and receiving nodes

error detection: errors caused by signal attenuation, noise. receiver detects presence of errors:

signals sender for retransmission or drops frame

error correction: receiver identifies and corrects bit error(s) without resorting

to retransmission

half-duplex and full-duplex with half duplex, nodes at both ends of link can transmit, but

not at same time

Page 6: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-6

Multiple Access Links and ProtocolsTwo types of “links”:

point-to-point PPP for dial-up access point-to-point link between Ethernet switch and host

broadcast (shared wire or medium) old-fashioned Ethernet upstream HFC 802.11 wireless LAN

shared wire (e.g., cabled Ethernet)

shared RF (e.g., 802.11 WiFi)

shared RF(satellite)

humans at acocktail party

(shared air, acoustical)

Page 7: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-7

Multiple Access protocols

single shared broadcast channel

two or more simultaneous transmissions by nodes: interference collision if node receives two or more signals at the same time

multiple access protocol

distributed algorithm that determines how nodes share channel, i.e., determine when node can transmit

communication about channel sharing must use channel itself! no out-of-band channel for coordination

Page 8: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-8

Ideal Multiple Access Protocol

Broadcast channel of rate R bps

1. when one node wants to transmit, it can send at rate R.

2. when M nodes want to transmit, each can send at average rate R/M

3. fully decentralized: no special node to coordinate transmissions no synchronization of clocks, slots

4. simple

Page 9: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-9

MAC Protocols: a taxonomy

Three broad classes:

Channel Partitioning divide channel into smaller “pieces” (time slots, frequency,

code) allocate piece to node for exclusive use

Random Access channel not divided, allow collisions “recover” from collisions

“Taking turns” nodes take turns, but nodes with more to send can take

longer turns

Page 10: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-10

Channel Partitioning MAC protocols: TDMA

TDMA: time division multiple access

access to channel in "rounds"

each station gets fixed length slot (length = pkt trans time) in each round

unused slots go idle

example: 6-station LAN, 1,3,4 have pkt, slots 2,5,6 idle

1 3 4 1 3 4

6-slotframe

Page 11: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-11

Channel Partitioning MAC protocols: FDMA

FDMA: frequency division multiple access

channel spectrum divided into frequency bands

each station assigned fixed frequency band

unused transmission time in frequency bands go idle

example: 6-station LAN, 1,3,4 have pkt, frequency bands 2,5,6 idle

freq

uenc

y ba

nds

time

FDM cable

Page 12: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-12

Random Access Protocols

When node has packet to send transmit at full channel data rate R. no a priori coordination among nodes

two or more transmitting nodes ➜ “collision”,

random access MAC protocol specifies: how to detect collisions how to recover from collisions (e.g., via delayed retransmissions)

Examples of random access MAC protocols: slotted ALOHA ALOHA CSMA, CSMA/CD, CSMA/CA

Page 13: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-13

Slotted ALOHA

Assumptions:all frames same sizetime divided into equal size slots (time to transmit 1 frame)nodes start to transmit only slot beginning nodes are synchronizedif 2 or more nodes transmit in slot, all nodes detect collision

Operation:when node obtains fresh frame, transmits in next slot

if no collision: node can send new frame in next slot

if collision: node retransmits frame in each subsequent slot with prob. p until success

Page 14: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-14

Slotted ALOHA

Pros

single active node can continuously transmit at full rate of channel

highly decentralized: only slots in nodes need to be in sync

simple

Conscollisions, wasting slotsidle slotsnodes may be able to detect collision in less than time to transmit packetclock synchronization

Page 15: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-15

Pure (unslotted) ALOHA

unslotted Aloha: simpler, no synchronization

when frame first arrives transmit immediately

collision probability increases: frame sent at t0 collides with other frames sent in [t0-1,t0+1]

Page 16: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-16

CSMA (Carrier Sense Multiple Access)

CSMA: listen before transmit:

If channel sensed idle: transmit entire frame

If channel sensed busy, defer transmission

human analogy: don’t interrupt others!

Page 17: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-17

CSMA collisions

collisions can still occur:propagation delay means two nodes may not heareach other’s transmission

collision:entire packet transmission time wasted

spatial layout of nodes

note:role of distance & propagation delay in determining collision probability

Page 18: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-18

CSMA/CD (Collision Detection)

CSMA/CD: carrier sensing, deferral as in CSMA collisions detected within short time colliding transmissions aborted, reducing channel wastage

collision detection: easy in wired LANs: measure signal strengths, compare transmitted,

received signals difficult in wireless LANs: received signal strength overwhelmed by local

transmission strength

human analogy: the polite conversationalist

Page 19: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-19

CSMA/CD collision detection

Page 20: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-20

“Taking Turns” MAC protocols

channel partitioning MAC protocols: share channel efficiently and fairly at high load inefficient at low load: delay in channel access, 1/N bandwidth allocated

even if only 1 active node!

random access MAC protocols efficient at low load: single node can fully utilize channel high load: collision overhead

“taking turns” protocolslook for best of both worlds!

Page 21: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-21

“Taking Turns” MAC protocols

Polling:

master node “invites” slave nodes to transmit in turn

typically used with “dumb” slave devices

concerns: polling overhead latency single point of failure

(master)

master

slaves

poll

data

data

Page 22: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-22

“Taking Turns” MAC protocols

Token passing: control token passed

from one node to next sequentially.

token message concerns:

token overhead latency single point of failure

(token)

T

data

(nothingto send)

T

Page 23: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Data Link Layer 5-23

Summary of MAC protocols

channel partitioning, by time, frequency or code Time Division, Frequency Division

random access (dynamic), ALOHA, S-ALOHA, CSMA, CSMA/CD carrier sensing: easy in some technologies (wire), hard in

others (wireless) CSMA/CD used in Ethernet CSMA/CA used in 802.11

taking turns polling from central site, token passing Bluetooth, FDDI, IBM Token Ring

Page 24: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Introduction: Wireless/Mobile

Page 25: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Computers for the next decades?

Computers are integrated small, cheap, portable, replaceable - no more separate devices

Technology is in the background computer are aware of their environment and adapt (“location awareness”) computer recognize the location of the user and react appropriately (e.g.,

call forwarding, fax forwarding, “context awareness”))

Advances in technology more computing power in smaller devices flat, lightweight displays with low power consumption new user interfaces due to small dimensions more bandwidth per cubic meter multiple wireless interfaces: wireless LANs, wireless WANs, regional

wireless telecommunication networks etc. („overlay networks“)

Page 26: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Mobile communication

Two aspects of mobility: user mobility: users communicate (wireless) “anytime, anywhere, with

anyone” device portability: devices can be connected anytime, anywhere to the

network

Wireless vs. mobile Examples stationary computer notebook in a hotel wireless LANs in historic buildings Personal Digital Assistant (PDA)

The demand for mobile communication creates the need for integration of wireless networks into existing fixed networks: local area networks: standardization of IEEE 802.11,

ETSI (HIPERLAN) Internet: Mobile IP extension of the internet protocol IP wide area networks: e.g., internetworking of GSM and ISDN

Page 27: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Applications I

Vehicles transmission of news, road condition, weather, music via DAB personal communication using GSM position via GPS local ad-hoc network with vehicles close-by to prevent accidents, guidance

system, redundancy vehicle data (e.g., from busses, high-speed trains) can be transmitted in

advance for maintenance

Emergencies early transmission of patient data to the hospital, current status, first

diagnosis replacement of a fixed infrastructure in case of earthquakes, hurricanes,

fire etc. crisis, war, ...

Page 28: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Typical application: road traffic

ad ho

cUMTS, WLAN,DAB, DVB, GSM, cdma2000, TETRA, ...

Personal Travel Assistant,PDA, Laptop, GSM, UMTS, WLAN, Bluetooth, ...

Page 29: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Mobile and wireless services – Always Best Connected

UMTS2 Mbit/s

UMTS, GSM384 kbit/s

LAN100 Mbit/s,WLAN54 Mbit/s

UMTS, GSM115 kbit/s

GSM 115 kbit/s,WLAN 11 Mbit/s

GSM/GPRS 53 kbit/sBluetooth 500 kbit/s

GSM/EDGE 384 kbit/s,DSL/WLAN 3 Mbit/s

DSL/ WLAN3 Mbit/s

Page 30: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Applications II

Travelling salesmen direct access to customer files stored in a central location consistent databases for all agents mobile office

Replacement of fixed networks remote sensors, e.g., weather, earth activities flexibility for trade shows LANs in historic buildings

Entertainment, education, ... outdoor Internet access intelligent travel guide with up-to-date

location dependent information ad-hoc networks for

multi user games

HistoryInfo

Page 31: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Location dependent services

Location aware services what services, e.g., printer, fax, phone, server etc. exist in the local

environment

Follow-on services automatic call-forwarding, transmission of the actual workspace to the

current location

Information services „push“: e.g., current special offers in the supermarket „pull“: e.g., where is the Black Forrest Cherry Cake?

Support services caches, intermediate results, state information etc. „follow“ the mobile

device through the fixed network

Privacy who should gain knowledge about the location

Page 32: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Mobile devices

performanceperformance

Pager• receive only• tiny displays• simple text messages

Mobile phones• voice, data• simple graphical displays

PDA• graphical displays• character recognition• simplified WWW

Palmtop• tiny keyboard• simple versions of standard applications

Laptop/Notebook• fully functional• standard applications

Sensors,embeddedcontrollers

www.scatterweb.net

Page 33: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Effects of device portability

Power consumption limited computing power, low quality displays, small disks due to

limited battery capacity CPU: power consumption ~ CV2f

C: internal capacity, reduced by integration V: supply voltage, can be reduced to a certain limit f: clock frequency, can be reduced temporally

Loss of data higher probability, has to be included in advance into the design

(e.g., defects, theft)

Limited user interfaces compromise between size of fingers and portability integration of character/voice recognition, abstract symbols

Limited memory limited value of mass memories with moving parts flash-memory or ? as alternative

Page 34: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Wireless networks in comparison to fixed networks

Higher loss-rates due to interference emissions of, e.g., engines, lightning

Restrictive regulations of frequencies frequencies have to be coordinated, useful frequencies are almost all

occupied

Low transmission rates local some Mbit/s, regional currently, e.g., 53kbit/s with GSM/GPRS

Higher delays, higher jitter connection setup time with GSM in the second range, several hundred

milliseconds for other wireless systems

Lower security, simpler active attacking radio interface accessible for everyone, base station can be simulated,

thus attracting calls from mobile phones

Always shared medium secure access mechanisms important

Page 35: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Areas of research in mobile communication

Wireless Communication transmission quality (bandwidth, error rate, delay) modulation, coding, interference media access, regulations ...

Mobility location dependent services location transparency quality of service support (delay, jitter, security) ...

Portability power consumption limited computing power, sizes of display, ... usability ...

Page 36: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Simple reference model used here

Application

Transport

Network

Data Link

Physical

Medium

Data Link

Physical

Application

Transport

Network

Data Link

Physical

Data Link

Physical

Network Network

Radio

Page 37: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Influence of mobile communication to the layer model

service location new applications, multimedia adaptive applications congestion and flow control quality of service addressing, routing,

device location hand-over authentication media access multiplexing media access control encryption modulation interference attenuation frequency

Application layer

Transport layer

Network layer

Data link layer

Physical layer

Page 38: Review: MAC. Data Link Layer5-2 Link Layer: Introduction Terminology: hosts and routers are nodes communication channels that connect adjacent nodes along.

Overlay Networks - the global goal

regional

metropolitan area

campus-based

in-house

verticalhandover

horizontalhandover

integration of heterogeneous fixed andmobile networks with varyingtransmission characteristics