Giuseppe Bianchi Transmission & Error control ARQ.

Post on 28-Mar-2015

229 views 2 download

Tags:

Transcript of Giuseppe Bianchi Transmission & Error control ARQ.

Giuseppe Bianchi

Transmission & Error controlTransmission & Error control

ARQARQ

Giuseppe Bianchi

Two scenariosTwo scenarios

network End to End(transport protocol issue)

Hop by Hop(datalink protocol issue)

Giuseppe Bianchi

Coping with rx errorsCoping with rx errors

Forward Error CorrectionExtra overhead capable of CORRECTING errors

Large overhead depending on protection capability

RetransmissionExtra overhead capable of DETECTING errors

Small constant overhead (2-4 bytes)Called:

» Frame Check Sequence

» Cyclic Redundance Check

Giuseppe Bianchi

Retransmission scenariosRetransmission scenariosreferred to as ARQ schemes (referred to as ARQ schemes (AAutomatic utomatic RRetransmission reetransmission reQQuest)uest)

DATA

ACK

SRC DST

Basic ACK idea

DATA

NACK

SRC DST

Basic NACK idea

Error Check:

OK

COMPONENTS: a) error checking at receiver; b) feedback to sender; c) retx

Error Check:

corrupted

DATAAutomatic retransmit

DATASRC DST

Basic ACK/Timeout idea

RetxTimeout(RTO)

DATA

DATASRC DST

DATA

Error Check:

corrupted

DATASRC DST

DATA

ACK

Giuseppe Bianchi

Sequence numbers – a mustSequence numbers – a must

Sender side:DATA

DATA

ACKRTO

DATArtx

Receiver side:

DATA

DATALINK or NETWORK(ACK lost) New data?

Old data?

Need to univocally “label” all packets circulating in the network between two end points.

1 bit (0-1) enough for Stop-and-wait

Giuseppe Bianchi

Link-level modelLink-level model

C bits/sec

In e2e scenario, C approximated by bottleneck link rate

Stop & Wait one frame/packet at a time

Pipelining (continuous ARQ) more than one frame/packet

Giuseppe Bianchi

Stop & Wait

Giuseppe Bianchi

stop-and-waitstop-and-wait

time

sender

time

receiver

One way delay

RTT

2//

CACKCMSGRTT

MSGthr

MSG/C

REMARK: throughput always lower than Available link rate!

ACK/C

For simplicity all MSG of same size; extension to != size use mean value

Giuseppe Bianchi

Upper boundUpper bound

No processing = 0

ACK size negligibleACK = 0

11

/

1/

/

CMSGRTT

Cthrefficiency

CMSGRTT

MSGthr

Giuseppe Bianchi

stop-and-wait: upper stop-and-wait: upper bound /1bound /1MSG = 1500 bytesMSG = 1500 bytes

Under-utilization with: 1) high capacity links, 2) large RTT links

Giuseppe Bianchi

Under-utilization with: 1) high capacity links, 2) large RTT links

stop-and-wait: upper stop-and-wait: upper bound /2bound /2MSG = 1500 bytesMSG = 1500 bytes

Giuseppe Bianchi

Dealing with errorsDealing with errors

TO

sender receiver

IMPORTANT ISSUE: setting the Time Out right!

Too short unnecessary rtxToo short inconsistent protocol operation

Too long waste of time

Ideally: TO = RTT+ACK/C (+2 )

Easy to say, but harder to do if RTT is not known (e.g. in e2e scenario)

Giuseppe Bianchi

Inconsistent protocol Inconsistent protocol operationoperation

M=1TO

sender receiver

M=1

M=2

M=3

M=2 will be NEVER received!

Consequence: ACK MUST be also numberedTo always guarantee consistent operation

Giuseppe Bianchi

Performance with loss Performance with loss (upper bound)(upper bound)

No processing time, negligible ACK Per packet loss probability P

Assumed indipendentP(immediate success) = (1-P)P(success at second tx) = P(1-P)P(success at third tx) = P2(1-P)

CMSGRTT

PMSG

CMSGRTTP

MSG

CMSGRTTtxE

MSG

timedeliverymessageE

messageofsizethr

/

)1(

)/(1

1

)/(][#][

Giuseppe Bianchi

Pipelining(Continuous ARQ)

Giuseppe Bianchi

Pipelining ideaPipelining idea

Up to W>1 frames can be “in fly”In fly = frames transmitted but not yet

ACKedSliding Window

Size W“Slides” forward at each received ACK

Giuseppe Bianchi

Pipelining casesPipelining cases

W=4RTT

(+1tx)

UNDER-SIZED WINDOW: THROUGHPUT INEFFICIENCY

?

timetime

WINDOW SIZING that allowsCONTINUOUS TRANSMISSION

W=10

CMSGRTT

MSGWCthr

/,min

Giuseppe Bianchi

Esercizio (fatelo)Esercizio (fatelo)MSG=500 bytesW=4C= 2 MbpsPropagation = 16 ms

How much time to transmit 6 messages?Which message size for continuous tx?

Giuseppe Bianchi

Continuous transmissionContinuous transmission

C

MSGRTT

C

MSGW

Time to transmitW frames

Time to receiveAck of first frame

Condition in which link rate is fully utilized

We may elaborate:CRTTMSGCRTTMSGW

This means that full link utilization is possible when window size (in bits) is Greater than the bandwidth (C bit/s) delay (RTT s) product!

Giuseppe Bianchi

Bandwidth-delay productBandwidth-delay product

Network: like a pipeC [bit/s] x D [s]

number of bits “flying” in the network

number of bits injected in the network by the tx, before that the first bit is rxed

D

C

64Kbps

A 15360 (64000x0.240) bits “worm” in the air!!

bandwidth-delay product = no of bytes that saturate network pipe

Giuseppe Bianchi

Long Fat NetworksLong Fat NetworksLFNs (el-ef-an(t)s): large bandwidth-delay productLFNs (el-ef-an(t)s): large bandwidth-delay product

EthernetT1, transUST1 satelliteT3 transUS

Gigabit transUS

3604806060

NETWORK RTT (ms)10.0001.5441.54445.000

1.000.000

rate (kbps)3.75011.58092.640337.500

7.500.000

BxD (bytes)

Giuseppe Bianchi

Throughput for pipeliningThroughput for pipeliningMSS = 1500 bytesMSS = 1500 bytes

Giuseppe Bianchi

Maximum achievable throughputMaximum achievable throughput(assuming infinite speed line…)(assuming infinite speed line…)

W = 65535 bytes