31
Geneva, 24 March 2011 Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. Tanja Zseby Fraunhofer Institute for Open Communication Systems (Fraunhofer FOKUS) Berlin, Germany ITU-T Workshop on IP Traffic Flow Measurement (Geneva, Switzerland, 24 March 2011)

Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Embed Size (px)

Citation preview

Page 1: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Geneva, 24 March 2011

Introduction to IP Traffic Flow Measurements and Packet Sampling

Dr.-Ing. Tanja Zseby

Fraunhofer Institute for Open Communication Systems (Fraunhofer FOKUS)

Berlin, Germany

ITU-T Workshop onIP Traffic Flow Measurement(Geneva, Switzerland, 24 March 2011)

Page 2: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Overview

MotivationIP Packet ObservationLimitationsAggregation and Selection

Aggregation: IP Flow MeasurementsSelection: Filtering and Sampling

Multipoint MeasurementsIP Flow Information ExportSummary

2 of 30

Page 3: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Motivation

AccountingSecurity SLA ValidationFault DetectionTraffic EngineeringTraffic ProfilingResearch (Experiment Supervision)

3 of 30

Packet and Flow Measurements

Page 4: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Observation of IP Packets

4 of 30

Ac3 c2 c1

P1: < OA, c1, t1 >P2: < OA, c2, t2 > ... PN: <OA, cN, tN>

Packet Attributes at Observation pointOA – Observation pointci – Packet content (header and payload)ti – Arrival timePi – IP Packet Record

Timestamping

IP Packet Records

Observation Point

Page 5: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Calculation of Metrics

5 of 30

P1: < OA, c1, t1 >P2: < OA, c2, t2 > ... PN: <OA, cN, tN>

IP Packet Records

Quelle: [LaCD05] Lakhina, Crovella, Diot: Mining Anomalies Using Traffic Feature Distributions, SIGCOMM 2005.

Page 6: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Problem: Limited Resources

6 of 30

Capturing/processing all packets too high effort

ImprovedAlgorithms

SpecializedHardware Aggregation

Limited Resources

Processing

Selection

Storage Transport

Page 7: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Limitations

CapturingOn router capturing competes with routing tasksSpecialized hardware expensive, multiple devices needed

StorageE.g. flow cache on routers

Data exportTransmission capacityEffort to support reliable transport

7 of 30

Page 8: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Specialized Hardware

Specialized capture cards10 Gbit Ethernet, full line rate capturingHigh precision time stamping

ExamplesEndace DAG 9.2X2 (March 2010)Napatec NT20E CaptureNTT Advanced Technology PRESTA 10G

But: Expensive8 of 30

Page 9: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Aggregation: IP Flows

9 of 30

Ac3 c2 c1

Timestamping

Aggregation

IP Flow Records

Classification

1 1 1, , ,... N μ σ

f(ci)Flow 1: P1, P4, P6,…

IP Flow: set of IP packets with common properties [RFC5101]

Flow 2: P2, P3, P8, …Flow 3: P5, P7, …

Packet Records: P1, P2, P3, …

Flow 1:Flow 2:Flow 3:

2 2 2, , ,... N μ σ3 3 3, , ,... N μ σ

e.g. Cisco NetFlow, IPFIX

Page 10: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Calculation of Metrics

10 of 30

IP Flow Records

1 1 1, , ,... N μ σFlow 1:Flow 2:Flow 3:

2 2 2, , ,... N μ σ2 2 2, , ,... N μ σ

e.g. classification according to IP addresses

EntropyH(X)

Calculation of metrics possible if suitable classification (flow characteristics)

Page 11: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: Usage-based Accounting

11 of 30

Flow Measurements

Page 12: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: Usage-based accounting

Flow classificationBased on source network addressesDependent on tariff model

Generation of Accounting recordsCapture packet sizesCalculate number of bytes per flow

Today: Cisco NetFlowFlow classification based on flow keys

12 of 30

Page 13: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: IP Flow Observation

13 of 30

Network: CIRILInterval: 10.000.000Classification: SrcIP(24bit)Packtes: 34.324.092Flows: 3.588.520

Page 14: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

IP Flow Observation on Routers

14 of 30*Quelle: NetFlow Performance Analysis, Cisco Whitepaper, May 2007

Add

ition

al C

PU L

oad

[%] Additional CPU Load for IP Flow Observation (Cisco NetFlow)*

Still high resource consumption

Page 15: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Packet Selection

15 of 30

Ac3 c2 c1

Timestamping

Classification

IP Flow Records

Selection

Aggregation

1 1 1ˆ ˆˆ, , ,... N μ σFlow 1:

Flow 2:Flow 3:

2 2 2ˆ ˆˆ, , ,... N μ σ

3 3 3ˆ ˆˆ, , ,... N μ σ

P1, P2, P3, P4, P5, P6, P7, …X X X

Exact value substituted by estimate

Filtering f(ci)

Sampling f(ti)

Page 16: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Estimation Accuracy

16 of 30

Estimation accuracy

Selections- and estimation method

Selection parameter(Interval, size, etc.)

Characteristics of parent population

highly dynamichard to predict

Calculation and transmission of estimation accuracy

During the measurement

Per intervalPer IP Flow

Based on sample

Page 17: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: Estimation of Flow Volume

17 of 30

rel. stderr = 0.05

Additional Value per Flow

rel. stderr = 0.1

Page 18: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Flow Selection

18 of 30

Ac3 c2 c1

Timestamping

Classification

IP Flow RecordsAggregation Flow 1, Flow 2, Flow 3

Selection of flow records

Filtering

SamplingFlow Selection

Selected Flow RecordsFlow 1, Flow 3

Page 19: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Multipoint Measurements

Metrics: Path, one-way delay, lossBut Challenges:

Positioning of Measurement PointsInter-domain Observations

Cooperation of network operatorsExchange of data, data protection

Synchronization of measurement processes

Time synchronization NTP, GPS,…Synchronization of data selection 19 of 30

Page 20: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: SLA Validation

20 of 30

delay delay

Page 21: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Example: Attack Detection

21 of 30

expected path

real path

Page 22: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Multipoint Measurements

22 of 30

A B< OA, cA, tA > < OB, cB, tB >

<OA, idA, tA > < OB, idB, tB>

path OA, OB,delay= tB – tAMetric Calculation

ID Calculation

Packet ID: recognize packet at different observation points

ID Calculation

if idA = idB

Page 23: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

< OA, cA, tA >

Multipoint Packet Selection

23 of 30

A B

<OA, pkt_idA, tA > < OB, pkt_idB, tB>

path OA, OB,delay= tB – tA

Metric Calculation

ID Calculation ID Calculation

SelectionSelection

Goal: Ensure selection of same packet at all observation points

< OB, cB, tB >

Filtering f(ci)

Sampling f(ti)

Page 24: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Hash-based Selection [RFC5475]

24 of 30

c3 c2 c1

Hash(ci)

[ ][ ]

c2 xHash value:

Selection:c3

Duffield, Grossglauser: "Trajectory Sampling for Direct Traffic Observation", IEEE/ACM Transactions on Networking, vol. 9, 2001

[RFC 5475] Zseby, Molina, Duffield, Niccolini, Raspall. Sampling and Filtering Techniques for IP Packet Selection, RFC 5475, Standards Track, March 2009.

Page 25: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Challenges

Hash input: suitable header fieldsInvariant on the pathVariable between packets

Suitable hash function*PerformanceRepresentativeness of selection

Dynamic adaptation of selection ratesConfigured vs. attained selection rateCoordinated adaptation to available resources

25 of 30* [HeSZ08] Henke, Schmoll, Zseby: Empirical Evaluation of Hash Functions for Multipoint Measurements, ACM Comput. Commun. Rev. CCR 38, 3, July 2008.

Page 26: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Packet Tracking

Packet Tracking SoftwareFollow the path that a packet takesBased on hash-based selection

Deployed in PlanetLab EuropeService for PlanetLab users (researcher)Capture path of packets in network experimentersUsed for multipath routing, overlay experiments

26 of 30

Page 27: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Packet Tracking in Federated Environment

27 of 30Demonstration at SIGCOMM 2010

Page 28: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

IP Flow Information Export (IPFIX)

Future protocol for data export„Successor“ of Cisco NetFlowSupports packet and flow measurementsAllows flexible flow definitionsIntegration of data selection methods possible

Information Elements (IE)Flow information in IEs (e.g. #packets, bytes)Many information elements exists (see www.iana.org/assignments/ipfix/ipfix.xml)Vendor-specific IEs possible

28 of 30

Page 29: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

IPFIX Information Elements

Example: Usage based accountingIE: sourceIPv4Address (source IP)IE: destinationIPv4Address (destination IP)IE: ipDiffServCodePoint (DiffServ class)IE: octetDeltaCount (#octets in the Flow)

Further ExamplesIPFIX Applicability Statement (RFC 5472)

29 of 30

Page 30: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Summary

Many applications require measurementsProblem: Limited resourcesSolution: Aggregation and Data Selection

Aggregation: IP Flow MeasurementsSelection: Filtering and Sampling

Multipoint MeasurementsMeasurement of path, quality (loss, delay)Synchronization needed

IPFIX Standard flexible flow and packet reporting

30 of 30

Page 31: Introduction to IP Traffic Flow Measurements and Packet ... · Introduction to IP Traffic Flow Measurements and Packet Sampling Dr.-Ing. ... Accounting Security SLA Validation

Thank You!

[email protected]