Docsity

SW Analysis - Computer Networks - Lecture Slides, Slides of Computer Networks

Partial preview of the text

Download SW Analysis - Computer Networks - Lecture Slides and more Slides Computer Networks in PDF only on Docsity!

SWS, RWS, Max Sequence Number^ •^

SWS

?^

MaxSeqNum – 1

-^

Why? Suppose MaxSeqNum = 7

-^

Frames sent: 0, 1, 2, 3, 4, 5, 6, 7

-^

Suppose acks losts– Frames resent

-^ receiver expects 0, 1, 2, 3, .., 7 - second batch but get duplicate avoid -^

≤ 0, 1, 2, 3, 4, 5, 6, 0, 1, 2, 3

SWS, RWS, Max Sequence Number • receiver knows there is a problem whenRWS = 1 • what if RWS = SWS = 7 • Sender sends 0,1, 2, …, 6 successfullyreceived – acks lost

Idle

LL C SendTx

Y / Success

YesFail

No ReTxAll Active

LLC Send

empty

?^ ack Slide Window

No Tx Y / no space

Window full?

Tout >

Max

retries N

FSM:

Sliding Window Protocol:

Sender Process

Tout

Idle

Active

LLC RecvStart TxTime outFail

LLC RecvStart Rx

Empty?

N

N

In seq?

N Buffer

endRx Withinwindow?

N / discard

Y Ack Max seq,slide

Y

Y Success

FSM: Sliding Window Protocol:Receiver process:

A^

B

frame 1

t^0 A

B

frame a

frame 2 frame 1

A^

B

frame a+

frame 2

A^

B

frame N

Start ack 1

t+a^0 t+a+1^0 ack 1 t+2a+1^0

Sliding Window efficiency:

SWP: Efficiency

  • Case 1:

N > 2a+

•^

A transmits continuously without pause

-^

U = 1

  • Case 2:

N < 2a+

•^

U = N / 2a+

Approximation for k

a N NP P

a

P

N

U

a N P aP

U

a N when N k

a N when a k

1.0 0.8 0.6 0.4 0.2 0.

1

10

100

1000

a N = 7 gobackN = 7 selective rejectSlidingwindow

N = 127 selectivereject N = 127 goback N

Utilisation for different protocols(Stallings)

3 10 P^ =

−

DLL and the Internet

  • home PC calls ISP
    • home PC simple – character oriented terminal – shell account on hosts - time sharing machine – graphics based – PC acts as Internet hosts – all Internet services including graphicsavailable.

DLL and the Internet

-^ How Home PC connects to the Internet: - PC calls ISP’s router via modem. – After modem answers, establish a physical connection. –^ PC sends router a series of LCP packets in the payloadof a PPP frame - - used to select PPP parameters & responses – NCP packets are sent to configure NWL options – PC wants to run TCP / IP stack - needs IP addresses • NCP for dynamic address allocation

P-P-P

-^ Framing – fixed frame format •^ Link Control Protocol - bring up lines, testing negotiation options, bring downlines – User sends ISP host IP packets & receives IP packets. – User finishes, NCP tears down connection, face IPaddress. – LCP shuts down DLL connection – Finally computer tells modem to hang up – releasephysical connection

HDLC- A P-P Protocol

flag byte

1 byte

2 bytes

variable

flag byte

(^1111111) address 1 byte

control

protocol

payload

Check sum

When byte of kbs in the payload

Information, supervisory