Outline - PowerPoint PPT Presentation

About This Presentation
Title:

Outline

Description:

Web, email, FTP and telnet use TCP. Video and audio do not use TCP ... cars. The cars in the aisle further from the exit have to let the most other cars in ... – PowerPoint PPT presentation

Number of Views:30
Avg rating:3.0/5.0
Slides: 63
Provided by: mmm3
Category:
Tags: outline

less

Transcript and Presenter's Notes

Title: Outline


1
Outline
  • Introduction to TCP
  • The single bottleneck case (Deterministic)
  • Large network model (Stochastic)
  • Matching TCP dynamics and MPEG video dynamics
  • Inputoutput network models

2
The Dynamics of TCP
  • Stephan Bohacek
  • with
  • Boris Rozovskii, Joao Hespanha, Katia Obraczka,

3
TCP/IP
  • IP is the addressing system.
  • TCP is provides congestion control.
  • 95 of Internet data uses TCP
  • Web, email, FTP and telnet use TCP
  • Video and audio do not use TCP
  • In the future video is expected to use a larger
    portion of the Internet bandwidth.

4
Why Study TCP?
  • The stability of the Internet is vital for the
    economy. Thus, it is important that TCP is
    stable, reasonable fair and reasonable efficient.
  • TCP Friendly
  • Video and audio cannot use TCP.
  • Video and audio must share network resources with
    TCP flows.
  • Video/audio congestion control protocols must be
    compatible with TCP.

5
Network Congestion
queue
Router 1
1Mbs
1Mbs
Router 3
1Mbs
Router 2
maximum sending rate
  • Networks provide best effort delivery.
  • If a router has a packet it will send it to its
    next hop.
  • If the outgoing link is occupied, then the
    router puts the packet in a queue.
  • If the queue is full it drops the packet.
  • The router does not inform the sender of the
    packet that it has dropped the packet.
  • Routers do not reroute packets over alternative
    paths.

6
An Introduction to TCP
  • TCP is acknowledgment based. The sender sends a
    packet of data. When the receiver receives the
    packet, it responds by sending an acknowledgment
    packet to the sender.

Sender
receiver
7
An Introduction to TCP
  • TCP is acknowledgment based. The sender sends a
    packet of data. When the receiver receives the
    packet, it responds by sending an acknowledgment
    packet to the sender.
  • If the sender fails to receive an acknowledgment,
    it assumes that the packet has been dropped and
    decreases the sending rate.
  • If the sender receives an acknowledgment, it
    assumes that the network is not congested and
    increases the sending rate.

8
Some Details About TCP
  • The congestion window, X, defines the maximum
    number unacknowledged packets.
  • When the sender receives an acknowledgment it
    increases the congestion window by 1/Xt.
  • When a packet drop is detected, the sender
    divides the congestion window in half.

Note the congestion window is not the sending
rate. sending rate congestion window /
roundtrip time.
9
How the Congestion Window Increases
X4
send pkt A
Number of unacknowledged packets equals Cwnd.
Send no more packets.
Packet arrives at receiver. Receiver sends an
acknowledgment.
send pkt B
send pkt C
send pkt D
ack A
roundtrip time
ack B
X4.25
time
ack C
send pkt E
X4.5
ack D
send pkt F
X4.75
X5
send pkt G
send pkt H
send pkt F
receiver
sender
10
TCP
drop detected
cwnd (congestion window)
time
11
The Single Bottleneck Case
source 1
destination 1
100Mbs
100Mbs
Single bottleneck
source 2
destination 2
10Mb
router
router
source n
destination n
source i sends to destination i
12
The Single Bottleneck Case
  • In the case of TCP on the single bottleneck
    topology with equal propagation delays, all flows
    synchronize exponentially fast.
  • Hence, in this setting, TCP is stable, fair.
  • Furthermore, the queue never empties, so the
    maximum throughput is achieved, thus TCP is
    efficient.

congestion window
13
The Single Bottleneck Case
  • Every time the queue fills, each flow gets
    exactly one drop.

1
30ms
1
1
2
10ms
1
1
3
1
2
3
Q
Q
1
3
2
1
2
10ms
Packets enter the queue exactly as fast as the
leave.
3
14
The Single Bottleneck Case
  • Every roundtrip time, the congestion window
    increases by one.

1
30ms
1
1
2
1
10ms
1
1
3
1
2
3
Q
Q
1
3
2
1
10ms
  • But when the congestion window increases by one,
    two packets are send consecutively.
  • This second packet is causes the queue size to
    increase by one.
  • If the queue is full, when two packets are sent,
    then the second packet is dropped.

15
The Single Bottleneck Case
Let CWi(k) be the congestion window of the ith
flow during the kth roundtrip time cycle.
16
General Topology(topology network
configuration)
  • Worst case
  • Each flow has a congestion window 1
  • The network is totally utilized.
  • The next roundtrip time all flows increment there
    congestion window to 2.
  • Half of the packets are dropped.
  • Congestion windows decrease back to 1.
  • No congestion collapse. 1/3 of all data gets
    through.
  • Typical case
  • Each flows congestion window is between 10 and 40
  • Each roundtrip time the utilization increases by
    between 1/10 and 1/40

17
Unequal propagation delays
S1
D1
10ms
10ms
10ms
60ms
Q1
Q2
S2
20ms
D2
  • Flow S1?D1 has a shorter roundtrip time, so it
    increases the its congestion window faster.
  • When the queue in Q1 fills because S1 ?D1 is
    sending too fast S2 ?D2 may or may not get a
    drop.
  • S2 ?D2 congestion window must be three times as
    large to send at the same rate as S1 ?D1.

18
The Parking Lot Topology parking lot after a
football game
The cars in the aisle further from the exit have
to let the most other cars in front of them. This
aisle moves at the exit rate ? 2-5
cars
alternating merge
exit
19
The Parking Lot Topology
Competing TCP flows
S1
D1
S2
Dn-1
Dn
Sn
router
router
router
router
source
destination
Si? Di have a small roundtrip time. These flows
have fast dynamics and have closely spaced
drops. source ? destination has large roundtrip
time and takes a long time to recover from a
drop. Furthermore this experiences many drops.
20
Stochastic Models of TCP
Single bottleneck case is deterministic
congestion window
The multi-hop case can be modeled
probabilistically
congestion window
Time (seconds)
21
Ingredients of our TCP Model
  • Roundtrip time a one dimensional mean reverting
    stochastic process.
  • Packet loss each packet is drop with
    probability g where g depends on roundtrip time
    and a hidden Markov process.

22
A Simple Stochastic Model of the Roundtrip Time
Define Rt to be the queuing delay. Roundtrip time
propagation delay
mean reverting mean ?/?
CIR Model (short-term interest rates)
gamma distribution
Note that the stationary distribution does not
depend on ?.
forward equation
? controls the rate at which the transition
probability converges to the stationary
distribution.
23
Gamma Distribution
queues
qt1
qt2
qtn-1
qtn
source
destination
?i - arrival rate at ith queue
?i - departure rate at ith queue
Heavy-traffic assumption Account for most of the
delay
If ? i ? j and ?i ?j, then the roundtrip time
is distributed according to the Gamma
distribution with ? n and ? ? - ?.
24
Estimation of ?, ?, and ? (many approaches)
note the change in representation
likelihood ratio
maximum likelihood estimates
25
Estimation of ?, ?, and ?
Select a set of observations Rtk where tk ltlt
tk1 Hence, Rtk are approximately i.i.d.
under the independence assumption
mean of log( Rt )
mean of Rt
the maximum likelihood estimates satisfy
26
Estimating Diffusion
27
Estimation of ?, ?, and ?
The transition probability is known
? and ? are found as before and
Computationally difficult
28
Roundtrip Time Quasi-stationary Distribution
l
2
f
0.17
s
0.38
Night
Midday
P(RTT)
P(RTT)
RTT
RTT
ns-2 simulation
0.08
Observed RTT Dist
0.07
Fitted RTT Dist
0.06
0.05
P(RTT)
0.04
0.03
0.02
0.01
0
50
55
60
65
70
75
80
85
90
95
100
RTT
29
Models for Packet Drop Probability
Let St be the sending rate at time t. Let Rt be
the roundtrip time experienced by a packet sent
at time t. Let ?t be the congestion level at
time t. Let g be the probability that a packet is
dropped
general model
memoryless
depends on roundtrip time only


Preliminary work indicates that, for reasonable
sending rates, the drop probability mostly
depends on roundtrip time.
Since drops are rare, it is difficult to collect
data for slow sending rates.
30
Determining the Conditional Drop Probability
assume the congestion level, ?, is constant
observable
We assume that given Rtk, dk is independent of
Rtk-1
system of linear equations
31
Histogram of Observed RTT Increments (real data)
Gaussian (RTT028) Queue empties slowly
Queue empties quickly
Agrees with queuing theory (Diffusion
Approximation)
32
Modified Diffusion Approximation for a Single
Queue
33
Observed Conditional Drop Probabilities
observed conditional drop probability
12 noon
3pm
6pm
P(Drop Roundtrip Time )
9am
night
34
Drop Event Probability
35
Drop Model Parameter Variation
g(Rt, ?t) ?0(?t) ?1(? ) T1(R) ?2(? ) T2(R)

36
Basic Stochastic Model of TCP
Xt congestion window Rt Tprop roundtrip time
Nt is a Cox process with intensity n(Rt, Xt, ?t)
n(Rt, Xt, ?t) Xt / Rt g(Rt, Xt, ?t)
drop probability
Sending Rate Xt / Rt Packets per RTT /
Seconds per RTT Packets / Second
Drop Probability g(Rt, Xt, ?t)
37
Stochastic Model of TCPwith fast recovery
After a drop is detected, the congestion window,
X, is halved and remains constant until the
dropped packet is resent and acknowledged.
fast recovery
  • A drop is detected at t0, so W0R0
  • Wt gt 0 for 0 lt t lt R0
  • WRo 0 and the congestion window continues to
    increase until the next drop occurs.

38
Stochastic Model of TCPwith fast recovery and
time-out
When a time-out occurs, the congestion window is
set to 1.
39
The Forward Equation
No Time-outs Stationary environment (model
parameters are constant)
Assumptions
40
Midday RTT and Drop Data
? 4, ? 0.85, ? 0.5
Roundtrip Time Stationary Distribution
Drop Probability
0.03
Fitted
Measured
0.025
0.02
drop prob
0.015
0.01
0.005
0
0
2
4
6
8
10
12
14
RTT
41
ns-2 (network simulator)topology
Competing TCP Sources
A
B
D
C
Destination
Source
1
2
3
4
5
S
T
U
V
42
ns-2 Simulation
? 2, ? 0.17, ? 0.34
Roundtrip Time Stationary Distribution
Marginal Density p(X)
0.07
Fitted
Measured
0.06
0.05
0.04
P(RTT)
0.03
0.02
0.01
0
0
5
10
15
20
25
30
35
40
45
50
RTT
Drop Probability
Marginal Density p(X,R)
0.045
30
0.04
25
0.035
0.03
20
X - Congestion Window
0.025
15
drop prob
0.02
0.015
10
0.01
5
0.005
0
0
20
30
40
50
60
70
R - Roundtrip Time
-0.005
50
60
70
80
90
100
110
RTT
43
The Dependence on Drop Probability
Drops are modeled as a Cox process with
intensity n(Rt, Xt, ?t) Xt / Rt g(Rt, Xt, ?t)
Scale
The TCP Friendly Rule
2
10
1
Mean Congestion Window
10
The TCP Friendly Rule
E(X) C / E(p)1/2

0
10
-3
-2
-1
10
10
10
p
44
Dependence on ?
Recall that ? controls the rate at which the
transition probability converges to the
stationary distribution.
45
When is it safe to send video?
Objective We are want to transmit a movie over
the Internet. Problem We dont want to overly
interfere with TCP file transfers. Solution
Match the dynamics send the video at the same
rate that TCP would send data. (This is the
current dogma. But it may not be the best
approach.)
work in progress
46
MPEG 1 Model
  • MPEG has three types of frames
  • I Frame No time correlation is used. The
    compression is the same as image compression.
  • P Frame Some time correlation is used.
  • B Frame Extensive time correlation between
    frames is used.

GOP Group of Pictures
47
MPEG 1 Model
The size of I frames is decomposed into two Ik
Jk Lk
The J component is constant during a scene
constant. The scene changes with probability q
Jk1 Jk with probability q Jk1 Yk with
probability 1 q and Yk is i.i.d. lognormal.
The L component is i.i.d. and is normally
distributed.
The size of the P and B frames are i.i.d.
lognormal.
48
MPEG 1 Modelsmoothing
  • In order to avoid bursts, the sending rate is
    smoothed in two ways
  • Instead of breaking the video into frame, it is
    broken into GOPs.
  • The sending rate is smoothed (low-pass filtered).

new GOP frames
smoother
Vk1 ?Vk (1- ?)(Jk Lk P1k P2k P3k
B1k B2k B3k B4k B5k B6k B7k B8k)
Jk1 Jk with probability q Jk1 Yk with
probability 1 q and Yk is i.i.d. lognormal.
with 0 ? ? lt 1.
49
Two Dynamical Systems
TCP
Vk1 ?Vk (1- ?)(Jk Lk P1k P2k P3k
B1k B2k B3k B4k B5k B6k B7k B8k)
MPEG Video
Jk1 Jk with probability q Jk1 Yk with
probability 1 q and Yk is i.i.d. lognormal
50
Comparing TCP and MPEG distributions
The Wizard of OZ with ? 0.95 and LA to San Jose
during the day, but varying Tprop 90ms.
P(MPEG gt TCP) 0.42
51
Comparing TCP and MPEG distributions
The Wizard of OZ with ? 0.95 and LA to San Jose
during the day, but varying Tprop 70ms.
P(MPEG gt TCP) 0.24
52
Exit Times for TCP
Question
How long does a TCP flow send at a rate that is
higher than 50 of other TCP flows?
Answer
where
50th Percentile
53
Exit Times for TCP
Basic model
Define
Define
Let
Then
54
Exit Times of a MPEG flow from the TCPs 50
percentile sending rate
  • There are two ways to leave Q
  • R decreases
  • Video sending rate decreases.

55
Exit Times of a MPEG flow from the TCPs 50
percentile
Let
where
then
56
Exit Times of a MPEG flow from the TCPs 50
percentile
For Tprop between 60 and 80, there is a benefit
to smoothing. For Tprop gt 80, the MPEG flow may
interfere with TCP flows
57
Variation of loss probability with sending rate
Internet
loss probability
sending rate
Initial test stimulate with a periodic square
wave
One packet every 10ms
sending rate
One packet every 40ms
20s
58
Variation of loss probability with sending rate
ns configuration
Flow under test S ? D
Paths for competing flows 1 ? 5, 1 ? 6, 1 ? 7, 1
? 8 2 ? 6, 2 ? 7, 2 ? 8 3 ? 7, 3 ? 8, 4 ? 8
For each path there was either one, three, or
five TCP flows.
59
Variation of loss probability with sending rate
ns simulations
The step response is similar to a step response
of a linear system with the damping decreasing as
the congestion increases.
Simulation time 27days
60
Variation of loss probability with sending rate
LA (USC) ? LA (Culver City)
It appears that sending rate and loss probability
are not related!
experiment duration 1 week
61
Future Directions
  • The Internet as an input/output system.
  • So far we assumed that the roundtrip time and
    drop probability is independent of our sending
    rate. What is the effect of sending data too
    fast? If the dependence of the drop probability
    on sending rate is known, then the behavior of
    competing TCP flows can be determined and the
    effect of the sending rate can be determined.
  • Time-varying model parameters
  • The work so far assumes that the parameters are
    independent of time. The effect of their
    variation should be accounted for.

62
the end
Write a Comment
User Comments (0)
About PowerShow.com