1. Trang chủ
  2. » Công Nghệ Thông Tin

Advanced Computer Networks: Lecture 32 - Dr. Amir Qayyum

15 3 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 15
Dung lượng 336,61 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

Advanced Computer Networks: Lecture 32. This lecture will cover the following: TCP flow control issues; TCP bit allocation limitations; protection against wrap around; adaptive retransmission algorithm; Karn/Partridge algorithm; Jacobson/Karels algorithm;...

Trang 1

CS716 Advanced Computer Networks

By Dr. Amir Qayyum

Trang 2

Lecture No. 32

Trang 3

• Problem: app. delivers  tiny pieces  of data to TCP

– e.g. telnet in character mode

– Each piece sent as segment, returned as ACK

– Very inefficient

• Solutions

– Delay transmission to accumulate more data

– Nagle’s algorithm

• Send first piece

• Accumulate data until first piece ACK’d

• Send accumulated data and restart accumulation

• Not ideal for some traffic, e.g. mouse motion

Trang 4

• Problem:  slow  application reads data in tiny pieces

– Receiver advertises tiny window

– Sender fills tiny window

– Known as silly window syndrome

• Solution: due to Clark

– Advertise window opening only when MSS or ½ of buffer is  available

– Sender delays sending until window is MSS or ½ of receiver’s  buffer (estimated)

– Overridden by using PUSH

Trang 5

• Send buffer size: MaxSendBuffer

• Receive buffer size: MaxRcvBuffer

• Receiving side

– LastByteRcvd ­ LastByteRead < = MaxRcvBuffer

– AdvertisedWindow = MaxRcvBuffer ­ 

(NextByteExpected ­     NextByteRead)

• Sending side

– LastByteSent ­ LastByteAcked < = AdvertisedWindow – EffectiveWindow = AdvertisedWindow ­ (LastByteSent 

­     LastByteAcked)

– LastByteWritten ­ LastByteAcked < = MaxSendBuffer

– block sender if (LastByteWritten ­ LastByteAcked) + y > 

MaxSenderBuffer

• Always send ACK in response to arriving data segment

• Persist when AdvertisedWindow = 0

Trang 6

• Sequence numbers vs packet lifetime

– Assumed that IP packets live less than 60s

– Can we send  232 (4G) bytes in 60 seconds ?

– Only need a data rate of 573 Mbps!

– Less than an STS­12 line  (less than Gigabit  Ethernet)

• Advertised window vs delay­bandwidth

– Only  16 bits  (64kB) for advertised window

– For cross­country RTT of 100 milliseconds, 

adequate for a mere 5.24 Mbps!

Trang 7

• 32­bit SequenceNum

Bandwidth Time Until Wrap Around T1 (1.5 Mbps) 6.4 hours

Ethernet (10 Mbps) 57 minutes T3 (45 Mbps) 13 minutes FDDI (100 Mbps) 6 minutes STS­3 (155 Mbps) 4 minutes STS­12 (622 Mbps) 55 seconds STS­24 (1.2 Gbps) 28 seconds

Trang 8

• 16­bit AdvertisedWindow

Bandwidth Delay x Bandwidth Product T1 (1.5 Mbps) 18KB

Ethernet (10 Mbps) 122KB T3 (45 Mbps) 549KB FDDI (100 Mbps) 1.2MB STS­3 (155 Mbps) 1.8MB STS­12 (622 Mbps) 7.4MB

Trang 9

• Original algorithm used only  RTT   estimate

• Theory: measure RTT for each 

segment + its ACK

– Estimate  RTT

– Timeout is 2 × RTT to allow for 

variations

Trang 10

• Practice

– Use exponential moving average (  = 0.8 

to 0.9)

– Estimate =   × estimate + (1 ­  ) 

measurement

Measured 

RTT depends on 

Trang 11

• Problem: it did not handle variations well

• Ambiguity  for retransmitted packets: was ACK in 

response to first, second, etc. transmission ?

Measured 

RTT

time

transmission retransmission RTT ? ? ?

Trang 12

Adaptive Retransmission  (Original Algorithm)

• Measure SampleRTT for each segment/ACK 

pair

• Compute  weighted  average of RTT

– EstRTT =   × EstRTT +   × SampleRTT

– where    +   = 1

 between 0.8 and 0.9  between 0.1 and 0.2

• Set  timeout  based on EstRTT

– TimeOut = 2 × EstRTT

Trang 13

• Still did not handle variations well

• Did not solve network congestion problems as desired

Sender Receiver

ion

ACK

Sender Receiver

ion

ACK

Trang 14

• Estimate  variance  of RTT

– Calculate mean interpacket RTT deviation as 

an approximation of variance

   (Diff = RTT_estimate – measurement)

– RTT_estimate =

measurement

– Using another exponential moving average

– Deviation =

     x |RTT_estimate ­ measurement| + (1 ­  )  β β deviation

Trang 15

• Use variance estimate as component of RTT  estimate

– next_RTT (timeout) =

RTT_estimate + 4 × deviation

• Protects against high jitter

• Algorithm only as good as clock 

granularity(500ms on Unix)

• Accurate timeout mechanism important to 

congestion control

Ngày đăng: 05/07/2022, 12:15