steady state, fairness and transient behaviour of modern...
TRANSCRIPT
1
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Steady state, fairness and transient
behaviour of modern AQMs
Toke Høiland-Jørgensen
Karlstad University
Stanford Netseminar, October 30, 2014
2
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
3
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Primer: The bufferbloat problemI Whenever there’s a bottleneck in the network:
I Packets have to queue: this induces latencyI ”Bloated” buffers can result in seconds of queueing
0 10 20 30 40 50 60 70Time (s)
0
200
400
600
800
Late
ncy
(ms)
I Managing queues can be a way to fix this
4
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
5
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
About me
I Name: Toke Høiland-Jørgensen
I M.Sc., Comp Sci and Maths from Roskilde University,Denmark
I Currently: PhD student at Karlstad University, Sweden
I Involved in the Bufferbloat community for ~2 years
I Work area: Minimising latency by controlling queueing
6
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Where is Karlstad?
Karlstad
7
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Karlstad University
I About 16.000 students, 1.200 staff
I CS dept ~40 people; organised in three main areasI Distributed systems and communicationI Privacy/securityI Software Engineering
I National and EU research projects
I CS appointed strategic research area of the universityI Currently growing quite rapidly
8
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
9
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Smart Queue Management
Name for any technology doing something smarter than
FIFO. Can comprise:
I AQM (== drop algorithms)
I Fairness queueing
I Shaping
I Prioritisation
Example: The SQM module of the CeroWrt firmware.
10
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The ”new” AQMs
I CoDel: Controlled Delay (Nichols and Jacobson, 2012)I Directly measure queueing delay, drop if it stays high
I PIE: Proportional Integral Enhanced (Pan et al, 2013)I Periodically update drop probability from queue length
and drain rate
I Adaptive RED (Floyd et al, 2001 – not so new)I Dynamically adjust RED drop probability from average
queue size
11
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
FQ: Fairness/Flow Queueing
I SFQ: Stochastic Fairness Queueing (McKenney, 1990)I Hash flows into queues, round-robin per-packet dequeue
I DRR: Deficit Round-Robin (Shreedhar and Varghese, 1996)I Track deficit at dequeue to approximate byte fairness
I fq_codel: Flow Queueing (Dumazet, 2012)I Add sparse flow optimisation and the CoDel AQM
12
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
13
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
My test setup
Client Server
Gigabit ethernet Rate limited bottleneck
Bottleneck routerBottleneck router
Latency inducer
I Debian Linux – kernel v3.14
I Rate limiting via tbf, delay via dummynet
14
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The measurements
I Steady-state behaviourI The Realtime Response Under Load (RRUL) testI VoIP one-way delayI Web page retrievals
I Inter-flow fairnessI Four TCP flows, 10, 50, 200, 500 ms RTTs
I Transient behaviourI RRUL latency over time, from when competing flows start
Paper under submission to USENIX NSDI ’15
15
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The scenarios
I Three bandwidth settingsI 10/1, 10/10, 100/100 Mbps
I 50 ms base latency
I CUBIC TCP (except fairness tests)
I Three AQMs:I AREDI PIEI CoDel
I Three schedulers:I SFQI fq_codelI fq_nocodel
I And pfifo_fast (Linux default FIFO queue)
16
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Parameterisation1 Mbps 10 Mbps 100 Mbps
pfifo_fast
txqueuelen 127 127 1000
ARED
min 1514 12500 125000
bandwidth 1 Mbps 10 Mbps 100 Mbps
max 3028 - -
PIE
target 20 ms 20 ms 20 ms
tupdate 30 ms 30 ms 30 ms
limit 1000 1000 1000
CoDel
target 13 ms 5 ms 5 ms
interval 100 ms 100 ms 100 ms
limit 1000 1000 1000
SFQ
limit 127 127 1000
fq_codel
target 13 ms 5 ms 5 ms
interval 100 ms 100 ms 100 ms
limit 10240 10240 10240
fq_nocodel
limit 127 127 1000
interval 100 s 100 s 100 s
17
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The Good:
Steady state results
18
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
RRUL 10/1 Mbps
050100150200250300Mean induced latency (ms)
0
2
4
6
8
10
Mean
TC
P g
ood
pu
t (M
bit
/s)
pfifo_fast
pfifo_fast
ared
ared
pie
pie
codel
codel
sfq
sfq
fq_nocodel
fq_nocodel
fq_codel
fq_codel
19
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
RRUL 10/10 Mbps
020406080100Mean induced latency (ms)
8.8
8.9
9.0
9.1
9.2
9.3
9.4
9.5
9.6M
ean
TC
P g
ood
pu
t (M
bit
/s)
pfifo_fast
ared
pie codel
sfq
fq_nocodel
fq_codel
20
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
RRUL 100/100 Mbps
01020304050607080Mean induced latency (ms)
82
84
86
88
90
92
94
96M
ean
TC
P g
ood
pu
t (M
bit
/s)
pfifo_fast
ared
pie
codel
sfq
fq_nocodel
fq_codel
21
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
VoIP 10/1 Mbps
0 50 100 150 200 250 300 350 400One-way delay (ms)
0.0
0.2
0.4
0.6
0.8
1.0C
um
ula
tive
pro
bab
ilit
y
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
22
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
VoIP 100/100 Mbps
20 40 60 80 100 120One-way delay (ms)
0.0
0.2
0.4
0.6
0.8
1.0C
um
ula
tive
pro
bab
ilit
y
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
23
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Web: Huffington Post 10/10 Mbps w/RRUL
background
pfi
fo_f
ast
are
d
pie
cod
el
sfq
fq_n
oco
del
fq_c
od
el0
10002000300040005000600070008000
Mean
dow
nlo
ad
tim
e (
ms)
24
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The Bad:
Inter-flow fairness
25
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Fairness New Reno
pfi
fo_f
ast
are
d
pie
cod
el
sfq
fq_n
oco
del
fq_c
od
el
pfi
fo_f
ast
are
d
pie
cod
el
sfq
fq_n
oco
del
fq_c
od
el
pfi
fo_f
ast
are
d
pie
cod
el
sfq
fq_n
oco
del
fq_c
od
el0.0
0.2
0.4
0.6
0.8
1.0
1.2
Fair
ness
in
dex
100Mbit 10Mbit 1Mbit
26
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Fairness flow throughput 100 Mbps
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms0
10
20
30
40
50
60
70
80
Mean
ban
dw
idth
(M
bit
s/s)
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
27
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Fairness flow throughput 1 Mbps
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms
10
ms
50
ms
20
0 m
s5
00
ms0.0
0.1
0.2
0.3
0.4
0.5
Mean
ban
dw
idth
(M
bit
s/s)
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
28
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The Ugly:
Transient behaviour
29
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
100/100 Mbps
0 5 10 15 20 25Time (s)
60
80
100
120
140L
ate
ncy
(m
s)
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
30
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
10/10 Mbps
0 5 10 15 20 25Time (s)
50
100
150
200
Late
ncy
(m
s)
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
31
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
10/1 Mbps
0 5 10 15 20 25Time (s)
200
400
600
800
1000L
ate
ncy
(m
s)
pfifo_fast ared pie codel sfq fq_nocodel fq_codel
32
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Summary of results
I The Good: Steady state behaviourI AQMs can significantly improve latency under loadI FQ algorithms even more soI Although CoDel does have some issues at 100 Mbps
I The Bad: Inter-flow fairnessI AQMs exacerbate TCP RTT unfairnessI FQ does achieve almost perfect fairness
I The Ugly: Transient behaviourI AQMs take up to tens of seconds to contain latency at
competing flow startupI FQ doesn’t miss a beat
33
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
34
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
The netperf-wrapper tool
A Python wrapper for running tests; main features:
I Run several tools in concertI and parse their output to a common format (JSON)
I Store metadata along with the test results
I Automatic gathering of metadata
I Batch facilities
I Plotting; lots of plotting.
35
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Included tests
I Simple single-flow tests (ping, TCP ul/dl, UDP flood)
I Latency under load testsI 1 TCP flow up/down/bidirectionalI RRUL variantsI Periodic UDP burstsI On/off TCP flows
I RTT fairness tests
I Comparing TCPs (cubic, reno, westwood, ledbat)
I Application-specific (HTTP, VoIP)
36
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Test specificationsDATA_SETS = o([
(’TCP upload BE’,
{’command ’: find_netperf(”TCP_STREAM”, LENGTH , HOST ,
marking=”CS0 ,CS0”),
’delay ’: DELAY , ’units ’: ’Mbits/s’,
’runner ’: ’netperf_demo ’,}),
(’TCP upload BK’,
{’command ’: find_netperf(”TCP_STREAM”, LENGTH , HOST ,
marking=”CS1 ,CS1”),
’delay ’: DELAY , ’units ’: ’Mbits/s’,
’runner ’: ’netperf_demo ’,}),
(’TCP upload avg’,
{’apply_to ’: [glob(”TCP upload*”,
exclude =[”TCP upload sum”])],
’units ’: ’Mbits/s’,’runner ’: ’average ’,}),
37
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Metadata collected automatically”metadata”: {
”BATCH_NAME”: ”rrul”,
”BATCH_TIME”: ”2014 -10 -02 T15 :31:11.616664”,
”DATA_FILENAME”: ”batch -rrul -2014 -10 -02 T153111 -50ms -10Mbit -ared -cubic -01. json.gz”,
”EGRESS_INFO”: {”bql”: {”tx -0”: ”1879048192”},
”classes”: null ,
”driver”: ”e1000e”,
”iface”: ”eth2”,
”link_params”: {”ether”: ”e8 :39:35:14:03:31”,
”qlen”: ”1000”},
”nexthop”: ”10.60.1.2”,
”offloads”: {”generic -receive -offload”: false ,
”generic -segmentation -offload”: false ,
”large -receive -offload”: false ,
”tcp -segmentation -offload”: false ,
”udp -fragmentation -offload”: false},
”qdiscs”: [{”id”: ”0:”,
”name”: ”pfifo_fast”,
”params”: {”0”: ”1”,”1”: ””,”2”: ”0”,”bands”: ”3”,”priomap”: ”1”,”refcnt”: ”2”},
”parent”: ”root”}],
”src”: ”10.60.1.1”,
”target”: ”10.60.4.2”},
”GATEWAYS”: [{”iface”: ”eth0”,”ip”: ”192.168.60.1”}],
”HOST”: ”testserv -05”,
”HOSTS”: [”testserv -05”],
”IP_ADDRS”: {”eth0”: [”192.168.60.91”,”fe80 ::21e:4fff:fee6 :3884”],
”eth2”: [”10.60.1.1”,”10.60.1.5”,”fe80::ea39 :35ff:fe14 :331”],
”lo”: [”127.0.0.1”,”::1”]},
”IP_VERSION”: 4,
”KERNEL_NAME”: ”Linux”,
”KERNEL_RELEASE”: ”3.14.4 - tohojo -1”,
”LENGTH”: 140,
”LOCAL_HOST”: ”tohojo -testbed -01”,
”NAME”: ”rrul_be”,
”NETPERF_WRAPPER_VERSION”: ”0.7.0-git -cbbab94”,
”NOTE”: ””,
”REMOTE_METADATA”: {
”testbed -02”: {
”EGRESS_INFO”: {”bql”: {”tx -0”: ”1879048192”},
”classes”: [{”id”: ”1:1”, ”name”: ”tbf”, ”params”: {”leaf”: ”2:”}, ”parent”: ”1:”},
{”id”: ”2:1”, ”name”: ”red”, ”params”: {}, ”parent”: ”2:”}],
38
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Batch facilities
[Batch:: global]
# set options
ip_version = 4
length = 140
# build values from variable expansions
title = qdisc:${qdisc_label} rep:${repetition} rtt:${rtt} rate:${rate_down }/${rate_up} cc:${cc}
filename_extra = ${rtt}-${rate_up}-${qdisc_label}-${cc}-${repetition}
output_path = batch -${batch_time }/${batch_name }/${rate_up}-${repetition}
# run pre/post commands
commands = clear_caches , setup_qdiscs , tcpdump_client , tcpdump_egress , tcpdump_ingress , tcpdump_server
# iterate over arguments
for_qdiscs = ared , fq_codel , fq_nocodel , codel , pie , pfifo_fast , pfifo_fast_1000 , sfq
for_bandwidths = 100mbit , 10mbit , 1mbit
# arguments
[Arg::pie]
inherits = global
qdisc_name = pie
qdisc_args =
# commands
[Command :: tcpdump]
filename = ${data_filename}
exec = ssh ${hostname} ”python tcpdump -wrapper.py start ${filename} -i ${interface} -s ${capsize}”
type = pre
essential = yes
39
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
GUI for exploring data sets
40
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Installing netperf-wrapper
I Ubuntu/Debian: Go to http://goo.gl/ysYJ7r
I Arch Linux: Install from AUR.
I Others (including OSX w/macports):
$ sudo pip install netperf -wrapper
$ wget ftp://ftp.netperf.org/netperf/netperf -2.6.0. tar.gz
$ tar -xzf netperf -2.6.0. tar.gz
$ cd netperf -2.6.0
$ ./ configure --enable -demo
$ make
$ sudo make install
41
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Running the RRUL test
# Running the test
$ netperf -wrapper rrul netperf -west.bufferbloat.net \
-t ”Stanford wifi test”
# Viewing the result -- PyQt4 installed
$ netperf -wrapper --gui <filename >.json.gz
# Viewing the result -- otherwise
$ netperf -wrapper -f plot <filename >.json.gz
42
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
43
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Unsolved problems – research
I ”Parameterless” – not so much
I Transient behaviourI Varying bandwidths, esp. wireless
I FQ – for everything?
44
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Unsolved problems – operative
I Storage and indexing of test data
I A better ”speedtest” or similar
I Deployment – convincing the world
I Standardisation
45
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Outline
I About me
I Queue management
I Measurement results
I The netperf-wrapper testing tool
I Unsolved problems
I References and questions
46
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
References
I Software and websites:I The Bufferbloat project: http://www.bufferbloat.netI The CeroWrt router firmware: http://www.bufferbloat.net/projects/cerowrtI Netperf-wrapper: https://github.com/tohojo/netperf-wrapperI Test results dataset: https://kau.toke.dk/modern-aqms/I The RRUL test specification:
https://github.com/dtaht/deBloat/blob/master/spec/rrule.doc?raw=trueI My email: [email protected]
I AQM algorithms:I Kathleen Nichols and Van Jacobson (2012). Controlling queue delay.I Rong Pan et al (2013). PIE: A lightweight control scheme to address the bufferbloat
problem.I Sally Floyd, Ramakrishna Gummadi, and Scott Shenker (2001). Adaptive RED: An
Algorithm for Increasing the Robustness of RED’s Active Queue Management.
I FQ algorithms:I P.E. McKenney (1990). Stochastic fairness queueing.I M. Shreedhar and G. Varghese (1996). Efficient fair queuing using deficit
round-robin.I T. Høiland-Jørgensen et al (2014). FlowQueue-Codel.
http://tools.ietf.org/html/draft-hoeiland-joergensen-aqm-fq-codel-00.
47
About me Queue management Measurement results Netperf-wrapper Unsolved problems References
Questions?