Internet as a Dynamic System Polly Huang NTU, EE http:/cc.ee.ntu.edu.tw/~phuang.

26
Internet as a Dynamic System Polly Huang NTU, EE http:/cc.ee.ntu.edu.tw/~phuang

Transcript of Internet as a Dynamic System Polly Huang NTU, EE http:/cc.ee.ntu.edu.tw/~phuang.

Internet as a Dynamic System

Polly HuangNTU, EEhttp:/cc.ee.ntu.edu.tw/~phuang

Modeling TCP

Outlines:Reno TCPQueuing network approachControl theoretical approachEngineering approach

Reno TCP

Increase congestion window size slow start (cwnd < ssh): cwnd += 1 steady state (cwnd ssh): cwnd +=

1/cwndDecrease congestion window size

duplicated acknowledges: cwnd = cwnd/2

timeout: cwnd = 1 ssh = cwnd/2

TCP With Different ssh

source sink

source sink

cwnd=1cwnd=2cwnd=4

ssh = 20

cwnd=1cwnd=2cwnd~3

ssh = 2

2+1/2 = 5/25/2 + 2/5 = 29/10

sshssh

10-second Quiz

cwnd/RTT(Round Trip Time)

cwnd/packet

Both curves represent some TCP attribute’s behavior. What are they?

Queuing Approach

ssh

TimeTs Te

A

Assume fixed packet size: MSSBW = A*MSS/(Te-Ts)

cwnd

The Magical (1/p)1/2

Show in a simplified analysis infinitely long TCP connections

only in the steady statecwnd += 1 per RTT

no timeoutsonly duplicated acknowledgescwnd /= 2 per drop

Average Bandwidth = MSS/RTT * (3/2p)1/2

Saw Tooth Behavior

W1

W1/2

W2

W2/2

W3

W3/2

Deriving BW

W

W/2

Total number of packets sent between two packet drops is:(W/2 + W) * (W/2) /2 = (3/8)W2

RTT * W/2

p: probability of packet loss(3/8) W2 = 1/p

W = (8/3p)1/2

BW = MSS * (3/8) W2 / (RTT * W/2) = MSS/RTT * (3/2p)1/2

W: average tooth tipW/2: average tooth dip

A Brief History

Floyd(LBL)Oct 91’

Ott(Bellcore)Aug 96’

Lakshman(Bell Lab)

Jun 97’

Mathis(PSC)Jul 97’

Padhye(U Mass)Sep 98’

Heidemann(ISI)

Jun 97’

Cardwell(U Wash)

Jul 00’

Steady Connections

Short ConnectionsConstant RTT!Constant RTT!

Control Theory Approach

A set of coupled differential equations dW(t) as a function of RTT(t) dRTT(t) as a function of W(t)

Dynamics of Window Size

steady state cwnd += 1 per RTT

no timeouts cwnd /= 2 per drop

dW(t) = 1/RTT(t) - W(t)/2 * p(drop)

Dynamics of RTT

dRTT(t) = Tfixed + dq(t)

In a bottleneck queue Packets coming in : W(t)/RTT(t) Packets going out : C (link rate)

dq(t) = -C + W(t)/RTT(t)

Deriving W(t), RTT(t), q(t)

3 equations dW(t) = 1/RTT(t) - W(t)/2 * p(drop) dRTT(t) = Tfixed + dq(t) dq(t) = -C + W(t)/RTT(t)

4 variables? W(t), RTT(t), q(t), p(drop)

p(drop): function of q(t)

Hybrid Modeling

p(drop) = 1, q(t)=qmax/C

dq(t) = 0 non-stable state

p(drop) = 0, q(t)<qmax/C dq(t) = -C + W(t)/RTT(t) stable state

Normalization

Non-linear dq(t) = -C + W(t)/RTT(t)

Take RTT as time unit, T dt/dT = RTT(t) = Tfixed + q(t)/C

Linear dq(T) = -C Tfixed – q(T) + W(T)

Can calculate # of steps to leave non-stable state

A Brief History

Shenker(Xerox)Aug 90’

Keshav(UCB)

Aug 91’

Misra(U Mass)Aug 00’

Hespanha(USC)

Mar 01’

Steady Connections

Steady state! TCP as smooth fluid!Steady state! TCP as smooth fluid!

Engineer’s Approach

Take results of traffic analysis seriously Closed-loop control (fractal scaling) Back-to-back packets (burstiness)

Model these two properties explicitly TCP as packet trains Use exhaustive tests to obtain

sizes and schedules of the trains

Represented as a finite state machine

TCP

n0 n1

A batch of packets per RTT or Timeout

Constructing a Finite State Automata

1 2

2

1

win=1, ssh=2

win=1, ssh=20

4 ...

2 2 ...

...

Light-weight TCP

Coarse-grain TCP behaviorFSA for Short TCP connections

Numbers of packets sent per round trip time or timeout

Combinations of packet dropsPreservation of the close-loop

feedback control (the KEY property)

Reno TCP (Partial)1 2 4 8 16

1 2 2 3 4 5 6 7 7

3 3 4 5 6

4 4 5 6

1 5 6 7

1 6 76

7

1

2

4 6 4 6

8

10

12 14

15-2728-30

(wnd, ssh) = (1,2)

(3,3)

(4,4)

(5,5)

(6,6)

(7,7)

22+2

EvaluationMemory

0

200

400

600

800

0 50 100

# web sessions

MB detailed

fsa tcp

% Difference in Throughput

2

2.5

3

3.5

4

0 50 100

# of web sessions

%

Traffic Fingerprint

Self-similar

Periodic Multifractal

FSA TCP’s delay difference is ~10msec!!Time series are taken every 10msec!!Not appropriate for multifractal analysis!!!

FSA TCP’s delay difference is ~10msec!!Time series are taken every 10msec!!Not appropriate for multifractal analysis!!!

Quick Summary

Analyzing Internet Characteristics Efficient high-fidelity simulations Performance analysis and protocol

designModeling TCP

Queuing: average, fixed RTT Control: variable RTT, smooth fluid Engineering: bursty packet train, fractal

Questions?

Polly HuangNTU, EEhttp://cc.ee.ntu.edu.tw/~phuang