27
Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee†, Nick Duffield‡, Ramana Rao Kompella† †Purdue University, ‡AT&T Labs–Research

Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

Embed Size (px)

Citation preview

Page 1: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

Not All Microseconds are Equal:Fine-Grained Per-Flow Measure-

ments with Reference Latency Inter-polation

Myungjin Lee†, Nick Duffield‡, Ramana Rao Kompella†

†Purdue University, ‡AT&T Labs–Research

Page 2: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

2

Low-latency applications

Several new types of applications require ex-tremely low end-to-end latency Algorithmic trading applications in financial data

center networks High performance computing applications in data

center networks Storage applications

Low latency cut-through switches Arista 7100 series Woven EFX 1000 series

Page 3: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

3

… … … …

ToR S/W

Edge Router

Core Router

…Need for high-fidelity measurements

At every router, high-fidelity measurements are critical to localize root causes

Once root cause localized, operators can fix by rerouting traffic, upgrade links or perform detailed diagnosis

Which router causes the prob-

lem??

1ms

Router

Measurement within a router is

necessary

Page 4: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

4

Measurement solutions today

SNMP and NetFlow No latency measurements

Active probes Typically end-to-end, do not localize the root cause

Expensive high-fidelity measurement box Corvil boxes (£ 90,000): used by London Stock Exchange Cannot place these boxes ubiquitously

Lossy Difference Aggregator (LDA) [Kompella, SIG-COMM’09] Provides average latency and variance at high-fidelity

within a switch Provides a good start but may not be sufficient to diag-

nose flow-specific problems

Page 5: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

5

Motivation for per-flow measurements

Key observation: Significant amount of difference in average latencies across flows at a router

Dela

y

Time

S/W

Queue

Average la-tency

Measurement period

Large de-lay

Small de-lay

Page 6: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

6

Outline of the rest of talk

Measurement model

Alternative approaches

Intuition behind our approach: Delay locality

Our architecture: Reference Latency Interpola-tion (RLI)

Evaluation

Page 7: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

7

Measurement model

Assumption: Time synchronization between router interfaces Constraint: Cannot modify regular packets to carry time-

stamps Intrusive changes to the routing forwarding path Extra bandwidth consumption up to 10% capacity

Router

Ingress I

Egress E

Page 8: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

8

Naïve approach

For each flow key, Store timestamps for each packet at I and E After a flow stops sending, I sends the packet timestamps

to E E computes individual packet delays E aggregates average latency, variance, etc for each flow

Problem: High communication costs At 10Gbps, few million packets per second Sampling reduces communication, but also reduces accu-

racy

Ingress I Egress E

10

− =2023

2730

+151

318

−=

2232Avg. delay = 22/2

= 11Avg. delay = 32/2 = 16

−+ −

Page 9: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

9

A (naïve) extension of LDA

Maintaining LDAs with many counters for flows of interest

Problem: (Potentially) high communication costs Proportional to the number of flows

Ingress I Egress E

LDA

LDA

LDA

LDA

LDA

LDA

28

15

2

1

Packet

count

Sum of time-

stamps

Coordina-tion

Per-flow la-tency

Page 10: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

10

Key observation: Delay locality

LocaTrue mean delay = W(D1 + WD2 + WD3) / 3

Localized mean delay = (WD1 + WD2 + WD3) / 3

WD1 WD3WD2

How close is localized mean delay to

true mean delay as window size varies?

Dela

y

Time

D1

D2D3

Page 11: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

11

Key observation: Delay locality

True Mean delay per key / ms

Loca

l m

ean

dela

y p

er

key /

ms

Global Mean

0.1ms: RMSRE=0.054

10ms: RMSRE=0.16

1s: RMSRE=1.72

Data sets from real router and synthetic queueing model

Page 12: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

12

Exploiting delay locality

Reference packets are injected regularly at the ingress I Special packets carrying ingress timestamp Provide some reference delay samples Used to approximate the latencies of regular packets

Dela

y

Time

ReferencePacket

IngressTimestamp

Page 13: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

13

RLI architecture

Component 1: Reference Packet generator Injects reference packets regularly

Component 2: Latency Estimator Estimates packet latencies and updates per-flow statis-

tics Estimates directly at the egress with no extra state main-

tained at ingress side (reduces storage and communica-tion overheads)

Egress E

Ingress I

1) ReferencePacket

Generator

2) LatencyEstimator

123 123

RL

IngressTimestamp

Page 14: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

14

Component 1: Reference packet generator

Question: When to inject a reference packet ?

Idea 1: 1-in-n: Inject one reference packet every n packets Problem: low accuracy under low utilization

Idea 2: 1-in-τ: Inject one reference packet every τ seconds Problem: bad in case where short-term delay variance is

high Our approach: Dynamic injection based on utilization

High utilization low injection rate Low utilization high injection rate Adaptive scheme works better than fixed rate schemes

Page 15: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

15

Component 2: Latency estimator

Question 1: How to estimate latencies using reference packets

Solution: Different estimators possible Use only the delay of a left reference packet (RLI-L) Use linear interpolation of left and right reference packets (RLI) Other non-linear estimators possible (e.g., shrinkage)

LInterpolated

delay

Dela

y

Time

Error indelay estimate

RegularPacket

ReferencePacket

Linear interpolationline

Arrival time is known

Arrival time and delay are

known

Estimateddelay

Error indelay estimate

R

Page 16: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

16

Component 2: Latency estimatorFlowkey C1 C2 C3

8 11 39

2 3 6

Interpolation buffer

Estimate

10

20

80

3 4 7

Avg. latency = C2 / C1

RL

Right Reference Packet arrived

When a flow is ex-

ported

Question 2: How to compute per-flow latency statistics Solution: Maintain 3 counters per flow at the egress side

C1: Number of packets C2: Sum of packet delays C3: Sum of squares of packet delays (for estimating variance) To minimize state, can use any flow selection strategy to main-

tain counters for only a subset of flows

Flow Key4 51Delay

Square of de-

lay

16

25

1

Update

Any flow se-lection

strategy

Up-date

Selection

Page 17: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

17

Experimental environment

Data sets No public data center traces with timestamps Real router traces with synthetic workloads: WISC Real backbone traces with synthetic queueing: CHIC

and SANJ

Simulation tool: Open source NetFlow software – YAF Supports reference packet injection mechanism Simulates a queueing model with RED active queue

management policy

Experiments with different link utilizations

Page 18: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

18

Accuracy of RLI under high link utilization

Relative error

CD

F

Median relative erroris 10-12%

Page 19: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

19

Comparison with other solutions

Utilization

Avera

ge r

ela

tive e

rror

Packet sampling rate = 0.1%

1-2 orders of magnitude dif-

ference

Page 20: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

20

Overhead of RLI

Bandwidth overhead is low less than 0.2% of link capacity

Impact to packet loss is small Packet loss difference with and without RLI is at

most 0.001% at around 80% utilization

Page 21: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

21

Summary

A scalable architecture to obtain high-fidelity per-flow latency measurements between router interfaces

Achieves a median relative error of 10-12%

Shows 1-2 orders of magnitude lower relative error compared to existing solutions

Measurements are obtained directly at the egress side

Future work: Per-packet diagnosis

Page 22: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

22

Thank you! Questions?

Page 23: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

23

Backup

Page 24: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

24

Comparison with other solutions

Relative error

CD

F

Page 25: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

25

Bandwidth overhead

Utilization

Band

wid

th c

onsu

mpti

on

Page 26: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

26

Interference with regular traffic

Per-flow delay interference (seconds)

Cum

ula

tive f

ract

ion

Page 27: Not All Microseconds are Equal: Fine-Grained Per-Flow Measurements with Reference Latency Interpolation Myungjin Lee †, Nick Duffield‡, Ramana Rao Kompella†

27

Impact to packet lossesLo

ss r

ate

diff

ere

nce

Utilization