INTERNET-DRAFT Nick Duffield draft-ietf-psamp-framework-02.txt Albert Greenberg March 2003 Matthias Grossglauser Expires: September 2003 Jennifer Rexford AT&T Labs - Research Derek Chiou Avici Systems Benoit Claise Peram Marimuthu Ganesh Sadasivan Cisco Systems A Framework for Passive Packet Measurement Copyright (C) The Internet Society (2003). All Rights Reserved. This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. Abstract A wide range of traffic engineering and troubleshooting tasks rely on timely and detailed traffic measurements that can be consistently interpreted. We describe a framework for passive packet measurement that is (a) general enough to serve as the basis for a wide range of operational tasks, and (b) needs only a small set of packet selection operations that facilitate ubiquitous deployment in router interfaces or dedicated measurement devices, even at very high speeds. Comments on this document should be addressed to the PSAMP WG mailing list: psamp@ops.ietf.org To subscribe: psamp-request@ops.ietf.org, in body: subscribe Archive: https://ops.ietf.org/lists/psamp/ Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 1] Internet-Draft Passive Packet Measurement March 2003 0 Contents 1 Motivation ................................................. 3 2 Elements, Terminology, and Architecture .................... 4 3 Requirements ............................................... 6 3.1 Selection Process Requirements ......................... 6 3.2 Reporting Process Requirements ......................... 7 3.3 Export Process Requirements ............................ 7 3.4 Configuration Requirements ............................. 7 4 Packet Selection ............................................ 8 4.1 Filtering .............................................. 8 4.2 Systematic Sampling .................................... 8 4.3 Random Sampling ........................................ 8 4.3.1 Uniform Random Sampling ............................ 8 4.3.2 Stratified Random Sampling ......................... 9 4.3.3 Non-uniform Independent Random Sampling ............ 9 4.4 Hash-based Selection ................................... 9 4.3.1 Consistent Flow Sampling ........................... 10 4.3.2 Trajectory Sampling ................................ 10 4.5 Generation of Pseudorandom Variates .................... 11 4.6 Criteria for Choice of Selection Operations ............ 11 4.6.1 Evaluating the Need for Distinct Selection Operations 11 4.6.2 Comparison of Uniform Sampling Methods ............. 12 4.7 Constraints on the Sampling Rate ....................... 12 4.8 Selection According to Packet Treatment ................ 12 4.9 Input Sequence Numbers for Primitive Selection Operations 12 4.10 Selection Operations and Application Requirements ..... 13 4.10.1 Mandatory Selection Operations .................... 13 4.10.2 Recommended Selection Operations .................. 13 4.10.3 Optional Selection Operations ..................... 14 5 Reporting .................................................. 14 5.1 Mandatory Reporting .................................... 14 5.2 Recommended Reporting .................................. 15 5.3 Report Interpretation ................................. 15 6 Export and Congestion Avoidance ............................ 16 6.1 Collector Destination .................................. 16 6.2 Local Export ........................................... 16 6.3 Reliable vs. Unreliable Transport ...................... 16 6.4 Limiting Delay in Exporting Measurement Packets ........ 17 6.5 Configurable Export Rate Limit ......................... 17 6.6 Congestion-aware Unreliable Transport .................. 17 6.7 Collector-based Rate Reconfiguration ................... 18 6.7.1 Changing the Export Rate and Other Rates ........... 18 6.7.2 Notions of Fairness ................................ 18 6.7.3 Behavior Under Overload and Failure ................ 19 7 Parallel Measurement Processes ............................. 19 8 Configuration and Management ............................... 19 9 Feasibility and Complexity ................................. 20 9.1 Feasibility ............ ............................... 20 9.1.1 Filtering .......................................... 20 9.1.2 Sampling ........................................... 20 9.1.3 Hashing ............................................ 20 Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 2] Internet-Draft Passive Packet Measurement March 2003 9.1.4 Reporting .......................................... 20 9.1.5 Export ............................................. 21 9.2 Potential Hardware Complexity .......................... 21 10 Applications .............................................. 22 10.1 Baseline Measurement and Drill Down ................... 22 10.2 Passive Customer Performance Measurements ............. 23 10.3 Troubleshooting ....................................... 23 11 References ................................................ 24 12 Authors' Addresses ........................................ 25 13 Intellectual Property Statement ........................... 26 14 Full Copyright Statement .................................. 27 1 Motivation This document describes a framework in which to define a standard set of capabilities for network elements to sample subsets of packets by statistical and other methods. The framework will accommodate future work to (i) specify a set of selection operations by which packets are sampled (ii) specify the information that is to be made available for reporting on sampled packets; (iii) describe a protocol by which information on sampled packets is reported to applications; (iv) describe a protocol by which packet selection and reporting are configured. The motivation to standardize these capabilities comes from the need for measurement-based support for network management and control across multivendor domains. This requires domain wide consistency in the types of selection schemes available, the manner in which the resulting measurements are presented, and consequently, consistency of the interpretation that can be put on them. The capabilities are positioned as suppliers of packet samples to higher level consumers, including both remote collectors and applications, and on board measurement-based applications. Indeed, development of the standards within the framework described here should be open to influence by the requirements of standards in related IETF WGs, for example, IP Performance Metrics (IPPM) [PAMM98] and Internet Traffic Engineering (TEWG) [LCTV02]. Conversely, we expect that aspects of this framework not specifically concerned with the central issue of packet selection and report formation may be able to leverage work in other WGs. Potential examples are the format and export of measurement Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 3] Internet-Draft Passive Packet Measurement March 2003 reports, which may leverage the information model and export protocols of IP Flow Information Export (IPFIX) [QZCZCN02], and work in congestion aware unreliable transport in the Datagram Congestion Control Protocol (DCCP) [FHK02]. 2 Elements, Terminology, and Architecture This section defines the basic elements of the PSAMP framework. * PSAMP Device: a device hosting at least one of each of the following: an observation point, a measurement process, and an export process. * Observation Point: The observation point is a location in the network where packets can be observed. Examples are, a line to which a probe is attached, a shared medium, such as an Ethernet-based LAN, a single port of a router, or set of interfaces (physical or logical) of a router, an embedded measurement subsystem within an interface. * Measurement Process: the combination of a selection process followed by a reporting process. * Selection Process: A selection process selects packets for reporting at an observation point. The inputs to the selection process are the packets observed at the observation point (including packet encapsulation headers), information derived from the packets' treatment at the observation point, and selection state that may be maintained by the observation point. Selection is accomplished through operating on these inputs with one or more selection operations. * Selection Operation: A configurable packet selection operation. It takes as input the selection process input for a single packet. If the packet is selected, this same information may be considered as the output. Selection operations may change the selection state. * Selection State: the observation point may maintain state information for use by the reporting process, and/or by multiple selection operations, either on the same packet, or on different packets. Examples include sequence numbers of packets at the input of packet selectors, timestamps, iterators for pseudorandom number generators, calculated hash values, and indicators of whether a packet was selected by a given selection operation. * Composite Selection Operation: a selection operation that is expressed as an ordered composition of other selection operations. Thus a packet is selected by the composite operation if it is selected by all its constituent selection Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 4] Internet-Draft Passive Packet Measurement March 2003 operations in order. * Primitive Selection Operation: a selection operation that is not a composite of other selection operations. * Reporting Process: the creation of a report stream of information on packets selected by a selection processes, in preparation for export. The input to a reporting process comprises that information available to a selection process, for the selected packets. The report stream contains two distinguished types of information: packet reports, and report interpretation. * Packet Reports: a configurable subset of the per packet input to the reporting process. * Report Interpretation: subsidiary information relating to one or more packets, that is used for interpretation of their packet reports. Examples include configuration parameters of the PSAMP device, and configuration parameters of the selection and reporting process. * Export Process: sends the output of one or more reporting process from the PSAMP device to one or more collectors. * Collector: a collector receives a report stream exported by one or more measurement processes. In some cases, the PSAMP device may serve as the collector. * Measurement packets: one or packet reports, and perhaps report interpretation, are bundled by the export process into a measurement packet for export to a collector. The various possibilities for the high level architecture of these elements is as follows. Note in the last case: the PSAMP device may also be a collector. OP = Observation Point, MP = Measurement Process, EP = Export Process +---------------------+ +------------------+ |PSAMP Device(1) | | Collector(1) | |Observation Point(s) | | | |MP(s)--->EP----------+---------------->| | |MP(s)--->EP----------+-------+-------->| | +---------------------+ | +------------------+ | +---------------------+ | +------------------+ |PSAMP Device(2) | +-------->| Collector(2) | |Observation Point(s) | | | |MP(s)--->EP----------+---------------->| | +---------------------+ +------------------+ +---------------------+ Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 5] Internet-Draft Passive Packet Measurement March 2003 |PSAMP Device(3) | |Observation Point(s) | |MP(s)--->EP---+ | | | | |Collector(3)<-+ | +---------------------+ 3 Requirements 3.1 Selection Process Requirements. * Ubiquity: The selection operations must be simple enough to be implemented ubiquitously at maximal line rate. * Applicability: the set of selection operations must be rich enough to support a range of existing and emerging measurement based applications and protocols. This requires a workable trade-off between the range of traffic engineering applications and operational tasks it enables, and the complexity of the set of capabilities. * Extensibility: to allow for additional packet selection operations to support future applications. * Flexibility: to support selection of packets using different network protocols or encapsulation layers (e.g. IPv4, IPv6, MPLS, etc), and under packet encryption. * Visibility: robustness of packet selection w.r.t. attempts to evade measurement. * Parallel measurements: support multiple independent measurement processes at the same device. * Non-contingency: in order to satisfy the ubiquity requirement, the selection decision for each packet must not depend on future packets. Rather, the selection decision must be capable of being made on the basis of the selection process input up to and including the packet in question. This excludes selection functions that require caching of packet for selection contingent on subsequent packets. See also the timeliness requirement following. A range of candidate selection operations is given in Section 4. Some detailed requirements of all selection operations are given in Section 4.9. Those selection operations to be required by the PSAMP standard are described in Section 4.10. Parallel measurement processes are discussed in Section 8. A target set of applications for PSAMP to support are described in Section 10. Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 6] Internet-Draft Passive Packet Measurement March 2003 3.2 Reporting Process Requirements * Timeliness: reports on selected packets should be made available to the collector quickly enough to support near real time applications. * Transparency: allow transparent interpretation of measurements as communicated by PSAMP reporting, without need to obtain additional information from the measuring device. * Robustness: allow robust interpretation of measurements with respect to reports missing due to loss, e.g. in transport, or omission at the measurement device. Inclusion in reporting of information enabling accuracy of measurements to be determined. * Faithfulness: all reported quantities that relate to the packet treatment must reflect the router state and configuration encountered by the packet in the PSAMP device. * Privacy: selection of the content of packet reports will be cognizant of privacy and anonymity issues while being responsive to the needs of measurement applications, and in accordance with RFC 2804. Full packet capture of arbitrary packet streams is explicitly out of scope. A specific reporting processes meeting these requirements, and the requirement for ubiquity, is described in Section 5. 3.3 Export Process Requirements * Congestion Avoidance: export of a report stream across a network must be congestion avoiding in compliance with RFC 2914. * Secure Export: the ability to export securely, e.g. by encryption Candidate export processes meeting these requirements are described in Section 6. 3.4 Configuration Requirements * Ease of Configuration: of sampling and export parameters, e.g. for automated remote reconfiguration in response to measurements. * Secure Configuration: configuration via protocols that prevent unauthorized reconfiguration. Specific configuration capabilities that meet these requirements are discussed in Section 8. Feasibility and complexity of PSAMP operations is discussed in Section 9. Reuse of existing protocols will be encouraged provided the Duffield et. al. draft-ietf-psamp-framework-02.txt [Page 7] Internet-Draft Passive Packet Measurement March 2003 protocol capabilities are compatible with the requirements laid out in this section. 4 Packet Selection The function of packet selection is to select a subset from the stream of all packets visible at an observation point. Selection can be used to select packets of based on their content, and/or to reduce the rate of packets reports regardless of content. This section details some candidate primitive selection operations for standardization that satisfy the requirements of Section 3.1. Not all operations listed here are intended for standardization. Those that are are listed in Section 4.10. Packet selection techniques are discussed in more detail in [ZMR03]. 4.1 Filtering Filtering is the selection of packets based only the packet content, the treatment of the packet at the observation point, and deterministic functions of these occurring in the selection state. The packet is selection if these quantities fall into a specified range. Hash-based packet selection (see Section 4.3) can also be regarded as a filter) An example is a match/mask filter applied to a combination of bit positions. The packet is selected if the bits and the match are equal after taking the logical AND of both with the mask. Higher level interfaces may be used to specify mask and matches for particular fields, for example, for IP addresses. Filtering on information derived from packet treatment, e.g., AS numbers derived from routing state, is another possibility; see Section 4.8. Filtering based on calculated hashes is described separately in Section 4.4. 4.2 Systematic Sampling In systematic sampling, the triggers for sampling are periodic, either in time or in packet count. All packets occurring in a selection interval (either in time or packet count) beyond the trigger are selected. The case that the selection interval covers only the first available packet for count-based sampling is often called 1 in N sampling: packets are selected with count period N. More generally, some number M