Flexible Netflow Overview

NetFlow is a Cisco IOS technology that provides statistics on packets flowing through the router. NetFlow is the standard for acquiring IP operational data from IP networks. NetFlow provides data to enable network and security monitoring, network planning, traffic analysis, and IP accounting.

Flexible NetFlow improves on original NetFlow by adding the capability to customize the traffic analysis parameters for your specific requirements. Flexible NetFlow facilitates the creation of more complex configurations for traffic analysis and data export through the use of reusable configuration components.

Prerequisites for Flexible NetFlow

  • You are familiar with the Flexible NetFlow key fields as they are defined in the following commands:
    • match flow

    • match interface
    • match {ipv4 | ipv6 }
    • match routing
    • match transpor t
  • You are familiar with the Flexible NetFlow nonkey fields as they are defined in the following commands:
    • collect counter
    • collect flow
    • collect interface
    • collect {ipv4 | ipv6 }
    • collect routing
    • collect timestamp sys-uptime
    • collect transport
  • The networking device must be running a Cisco release that supports Flexible NetFlow.

IPv4 Traffic

  • The networking device must be configured for IPv4 routing.

  • One of the following must be enabled on your device and on any interfaces on which you want to enable Flexible NetFlow: Cisco Express Forwarding or distributed Cisco Express Forwarding.

IPv6 Traffic

  • The networking device must be configured for IPv6 routing.

  • One of the following must be enabled on your device and on any interfaces on which you want to enable Flexible NetFlow: Cisco Express Forwarding IPv6 or distributed Cisco Express Forwarding.

Restrictions for Flexible Netflow

  • It is recommended that the total dataplane memory consumed by Flexible Netflow or Original Netflow is limited to a maximum of 25% of the amount of data plane DRAM for an ESP/FP.

  • Flexible Netflow export will not work over an IPSEC VPN tunnel if the source of the netflow data is the same router where the VPN tunnel is terminated unless you configure the output-features command under the flow exporter.

Information About Flexible Netflow

Flexible NetFlow Overview

Flexible NetFlow facilitates the creation of more complex configurations for traffic analysis and data export through the use of reusable configuration components.

Typical Uses for NetFlow

NetFlow is typically used for several key customer applications, including the following:

  • Network monitoring. NetFlow data enables extensive near-real-time network monitoring capabilities. Flow-based analysis techniques are used by network operators to visualize traffic patterns associated with individual routers and switches and network-wide traffic patterns (providing aggregate traffic or application-based views) to provide proactive problem detection, efficient troubleshooting, and rapid problem resolution.

  • Application monitoring and profiling. NetFlow data enables network managers to gain a detailed time-based view of application usage over the network. This information is used to plan, understand new services, and allocate network and application resources (for example, web server sizing and VoIP deployment) to meet customer demands responsively.

  • User monitoring and profiling. NetFlow data enables network engineers to gain detailed understanding of customer and user use of network and application resources. This information may then be used to efficiently plan and allocate access, backbone, and application resources and to detect and resolve potential security and policy violations.

  • Network planning. NetFlow can be used to capture data over a long period of time, affording the opportunity to track and anticipate network growth and plan upgrades to increase the number of routing devices, ports, and higher-bandwidth interfaces. NetFlow services data optimizes network planning for peering, backbone upgrades, and routing policy. NetFlow helps to minimize the total cost of network operations while maximizing network performance, capacity, and reliability. NetFlow detects unwanted WAN traffic, validates bandwidth and quality of service (QoS), and allows the analysis of new network applications. NetFlow will give you valuable information to reduce the cost of operating your network.

  • Security analysis. NetFlow identifies and classifies distributed denial of service (dDoS) attacks, viruses, and worms in real time. Changes in network behavior indicate anomalies that are clearly demonstrated in Flexible NetFlow data. The data is also a valuable forensic tool to understand and replay the history of security incidents.

  • Billing and accounting. NetFlow data provides fine-grained metering (for instance, flow data includes details such as IP addresses, packet and byte counts, time stamps, type of service (ToS), and application ports) for highly flexible and detailed resource utilization accounting. Service providers may use the information for billing based on time of day, bandwidth usage, application usage, quality of service, and so on. Enterprise customers may use the information for departmental charge back or cost allocation for resource utilization.

  • NetFlow data warehousing and data mining. NetFlow data (or derived information) can be warehoused for later retrieval and analysis in support of proactive marketing and customer service programs (for example, discovering which applications and services are being used by internal and external users and targeting them for improved service, advertising, and so on). In addition, Flexible NetFlow data gives market researchers access to the "who," "what," "where," and "how long" information relevant to enterprises and service providers.

Use of Flows in Original NetFlow and Flexible NetFlow

Original NetFlow and Flexible NetFlow both use the concept of flows. A flow is defined as a stream of packets between a given source and a given destination.

Original NetFlow and Flexible NetFlow both use the values in key fields in IP datagrams, such as the IP source or destination address and the source or destination transport protocol port, as the criteria for determining when a new flow must be created in the cache while network traffic is being monitored. When the value of the data in the key field of a datagram is unique with respect to the flows that already exist, a new flow is created.

Original NetFlow and Flexible NetFlow both use nonkey fields as the criteria for identifying fields from which data is captured from the flows. The flows are populated with data that is captured from the values in the nonkey fields.

The figure below is an example of the process for inspecting packets and creating flow records in the cache. In this example, two unique flows are created in the cache because different values are in the source and destination IP address key fields.

Figure 1. Packet Inspection

Original NetFlow and Benefits of Flexible NetFlow

Flexible NetFlow allows the flow to be user defined. The benefits of Flexible NetFlow include:

  • High-capacity flow recognition, including scalability and aggregation of flow information.

  • Enhanced flow infrastructure for security monitoring and dDoS detection and identification.

  • New information from packets to adapt flow information to a particular service or operation in the network. The flow information available will be customizable by Flexible NetFlow users.

  • Extensive use of Cisco’s flexible and extensible NetFlow Version 9.

  • A comprehensive IP accounting feature that can be used to replace many accounting features, such as IP accounting, Border Gateway Protocol (BGP) Policy Accounting, and persistent caches.

Flexible NetFlow allows you to understand network behavior with more efficiency, with specific flow information tailored for various services used in the network. The following are some example applications for a Flexible NetFlow feature:

  • Flexible NetFlow enhances Cisco NetFlow as a security monitoring tool. For instance, new flow keys can be defined for packet length or MAC address, allowing users to search for a specific type of attack in the network.

  • Flexible NetFlow allows you to quickly identify how much application traffic is being sent between hosts by specifically tracking TCP or UDP applications by the class of service (CoS) in the packets.

  • The accounting of traffic entering a Multiprotocol Label Switching (MPLS) or IP core network and its destination for each next hop per class of service. This capability allows the building of an edge-to-edge traffic matrix.

The figure below is an example of how Flexible NetFlow might be deployed in a network.

Figure 2. Typical Deployment for Flexible NetFlow

Flexible NetFlow Components

Flexible NetFlow consists of components that can be used together in several variations to perform traffic analysis and data export. The user-defined flow records and the component structure of Flexible NetFlow facilitates the creation of various configurations for traffic analysis and data export on a networking device with a minimum number of configuration commands. Each flow monitor can have a unique combination of flow record, flow exporter, and cache type. If you change a parameter such as the destination IP address for a flow exporter, it is automatically changed for all the flow monitors that use the flow exporter. The same flow monitor can be used in conjunction with different flow samplers to sample the same type of network traffic at different rates on different interfaces. The following sections provide more information on Flexible NetFlow components:

Flow Records

In Flexible NetFlow a combination of key and non-key fields is called a flow record. Flexible NetFlow records are assigned to Flexible NetFlow flow monitors to define the cache that is used for storing flow data. Flexible NetFlow includes several predefined records that can help you get started using Flexible NetFlow.

To use Flexible NetFlow to its fullest potential, you need to create your own customized records, as described in the following section(s):

NetFlow Predefined Records

Flexible NetFlow includes several predefined records that you can use to start monitoring traffic in your network. The predefined records are available to help you quickly deploy Flexible NetFlow and are easier to use than user-defined flow records. You can choose from a list of already defined records that may meet the needs for network monitoring. As Flexible NetFlow evolves, popular user-defined flow records will be made available as predefined records to make them easier to implement.

The predefined records ensure backward compatibility with your existing NetFlow collector configurations for the data that is exported. Each of the predefined records has a unique combination of key and nonkey fields that offer you the built-in ability to monitor various types of traffic in your network without customizing Flexible NetFlow on your router.

Two of the predefined records (NetFlow original and NetFlow IPv4/IPv6 original output), which are functionally equivalent, emulate original (ingress) NetFlow and the Egress NetFlow Accounting feature in original NetFlow, respectively. Some of the other Flexible NetFlow predefined records are based on the aggregation cache schemes available in original NetFlow. The Flexible NetFlow predefined records that are based on the aggregation cache schemes available in original NetFlow do not perform aggregation. Instead each flow is tracked separately by the predefined records.

User-Defined Records

Flexible NetFlow enables you to define your own records for a Flexible NetFlow flow monitor cache by specifying the key and nonkey fields to customize the data collection to your specific requirements. When you define your own records for a Flexible NetFlow flow monitor cache, they are referred to as user-defined records. The values in nonkey fields are added to flows to provide additional information about the traffic in the flows. A change in the value of a nonkey field does not create a new flow. In most cases the values for nonkey fields are taken from only the first packet in the flow. Flexible NetFlow enables you to capture counter values such as the number of bytes and packets in a flow as nonkey fields.

Flexible NetFlow adds a new Version 9 export format field type for the header and packet section types. Flexible NetFlow will communicate to the NetFlow collector the configured section sizes in the corresponding Version 9 export template fields. The payload sections will have a corresponding length field that can be used to collect the actual size of the collected section.

Flow Monitors

Flow monitors are the Flexible NetFlow component that is applied to interfaces to perform network traffic monitoring.

Flow data is collected from the network traffic and added to the flow monitor cache during the monitoring process based on the key and nonkey fields in the flow record.

Flexible NetFlow can be used to perform different types of analysis on the same traffic. In the figure below, packet 1 is analyzed using a record designed for standard traffic analysis on the input interface and a record designed for security analysis on the output interface.

Figure 3. Example of Using Two Flow Monitors to Analyze the Same Traffic


The figure below shows a more complex example of how you can apply different types of flow monitors with custom records.

Figure 4. Complex Example of Using Multiple Types of Flow Monitors with Custom Records


Normal

The default cache type is “normal”. In this mode, the entries in the cache are aged out according to the timeout active and timeout inactive settings. When a cache entry is aged out, it is removed from the cache and exported via any exporters configured.

Flow Exporters

Flow exporters export the data in the flow monitor cache to a remote system, such as a server running NetFlow collector, for analysis and storage. Flow exporters are created as separate entities in the configuration. Flow exporters are assigned to flow monitors to provide data export capability for the flow monitors. You can create several flow exporters and assign them to one or more flow monitors to provide several export destinations. You can create one flow exporter and apply it to several flow monitors.

NetFlow Data Export Format Version 9

The basic output of NetFlow is a flow record. Several different formats for flow records have evolved as NetFlow has matured. The most recent evolution of the NetFlow export format is known as Version 9. The distinguishing feature of the NetFlow Version 9 export format is that it is template-based. Templates provide an extensible design to the record format, a feature that should allow future enhancements to NetFlow services without requiring concurrent changes to the basic flow-record format. Using templates provides several key benefits:

  • Third-party business partners who produce applications that provide collector or display services for NetFlow do not have to recompile their applications each time a new NetFlow feature is added. Instead, they should be able to use an external data file that documents the known template formats.

  • New features can be added to NetFlow quickly without breaking current implementations.

  • NetFlow is “future-proofed” against new or developing protocols because the Version 9 format can be adapted to provide support for them.

The Version 9 export format consists of a packet header followed by one or more template flow or data flow sets. A template flow set provides a description of the fields that will be present in future data flow sets. These data flow sets may occur later within the same export packet or in subsequent export packets. Template flow and data flow sets can be intermingled within a single export packet, as illustrated in the figure below.

Figure 5. Version 9 Export Packet

NetFlow Version 9 will periodically export the template data so the NetFlow collector will understand what data is to be sent and also export the data flow set for the template. The key advantage to Flexible NetFlow is that the user configures a flow record, which is effectively converted to a Version 9 template and then forwarded to the collector. The figure below is a detailed example of the NetFlow Version 9 export format, including the header, template flow, and data flow sets.

Figure 6. Detailed Example of the NetFlow Version 9 Export Format

Flow Samplers

Flow samplers are created as separate components in a router’s configuration. Flow samplers are used to reduce the load on the device that is running by limiting the number of packets that are selected for analysis.

Flow sampling exchanges monitoring accuracy for router performance. When you apply a sampler to a flow monitor, the overhead load on the router of running the flow monitor is reduced because the number of packets that the flow monitor must analyze is reduced. The reduction in the number of packets that are analyzed by the flow monitor causes a corresponding reduction in the accuracy of the information stored in the flow monitor’s cache.

Samplers are combined with flow monitors when they are applied to an interface with the ip flow monitor command.

Security Monitoring with Flexible NetFlow

Flexible NetFlow can be used as a network attack detection tool with capabilities to track all parts of the IP header and even packet sections and characterize this information into flows. Security monitoring systems can analyze Flexible NetFlow data, and upon finding an issue in the network, create a virtual bucket or virtual cache that will be configured to track specific information and identify details about the attack pattern or worm propagation. The capability to create caches dynamically with specific information combined with input filtering (for example, filtering all flows to a specific destination) makes Flexible NetFlow a powerful security monitoring tool.

One common type of attack occurs when TCP flags are used to flood open TCP requests to a destination server (for example, a SYN flood attack). The attacking device sends a stream of TCP SYNs to a given destination address but never sends the ACK in response to the servers SYN-ACK as part of the TCP three-way handshake. The flow information needed for a security detection server requires the tracking of three key fields: destination address or subnet, TCP flags, and packet count. The security detection server may be monitoring general Flexible NetFlow information, and this data may trigger a detailed view of this particular attack by the Flexible NetFlow dynamically creating a new flow monitor in the router’s configuration. The new flow monitor might include input filtering to limit what traffic is visible in the Flexible NetFlow cache along with the tracking of the specific information to diagnose the TCP-based attack. In this case the user may want to filter all flow information to the server destination address or subnet to limit the amount of information the security detection server needs to evaluate. If the security detection server decided it understood this attack, it might then program another flow monitor to collect and export payload information or sections of packets to take a deeper look at a signature within the packet. This example is just one of many possible ways that Flexible NetFlow can be used to detect security incidents.

Feature Comparison of Original NetFlow and Flexible NetFlow

The table below provides a feature-by-feature comparison of original NetFlow and Flexible NetFlow.

Table 1. Feature-by-Feature Comparison of Original NetFlow and Flexible NetFlow

Feature

Original NetFlow

Flexible NetFlow

Comments

NetFlow Data Capture

Supported

Supported

Data capture is available with the predefined and user-defined records in Flexible NetFlow. Flexible NetFlow has several predefined keys that emulate the traffic analysis capabilities of original NetFlow.

NetFlow Data Export

Supported

Supported

Flow exporters export data from the Flexible NetFlow flow monitor caches to remote systems.

NetFlow for IPv6

Supported

Supported

IPv6 support was removed from original NetFlow in Cisco IOS Release 12.4(20)T.

The Flexible NetFlow--IPv6 Unicast Flows feature implemented IPv6 support for Flexible NetFlow in Cisco IOS Release 12.4(20)T.

NetFlow BGP Next Hop Support

Supported

Supported

Available in the predefined and user-defined keys in Flexible NetFlow records.

Random Packet Sampled NetFlow

Supported

Supported

Available with Flexible NetFlow sampling.

NetFlow v9 Export Format

Supported

Supported

Available with Flexible NetFlow exporters.

NetFlow Subinterface Support

Supported

Supported

Flexible NetFlow monitors can be assigned to subinterfaces.

NetFlow Multiple Export Destinations

Supported

Supported

Available with Flexible NetFlow exporters.

NetFlow ToS-Based Router Aggregation

Supported

Supported

Available in the predefined and user-defined records in Flexible NetFlow records.

NetFlow Minimum Prefix Mask for Router-Based Aggregation

Supported

Supported

Available in the predefined and user-defined records.

NetFlow Input Filters

Supported

Not supported

--

NetFlow MIB

Supported

Not supported

--

Egress NetFlow Accounting

Supported

Supported

Flexible NetFlow monitors can be used to monitor egress traffic on interfaces and subinterfaces.

Criteria for Identifying Traffic to Be Used in Analysis in Flexible NetFlow

If the predefined Flexible NetFlow records are not suitable for your traffic requirements, you can create a user-defined (custom) record using the Flexible NetFlow collect and match commands. Before you can create a customized record, you must decide the criteria that you are going to use for the key and nonkey fields.

If you want to create a customized record for detecting network attacks, you must include the appropriate key and nonkey fields in the record to ensure that the router creates the flows and captures the data that you need to analyze the attack and respond to it. For example, SYN flood attacks are a common denial of service (DoS) attack in which TCP flags are used to flood open TCP requests to a destination host. When a normal TCP connection starts, a destination host receives a SYN (synchronize/start) packet from a source host and sends back a SYN ACK (synchronize acknowledge). The destination host must then hear an ACK (acknowledge) of the SYN ACK before the connection is established. This is referred to as the "TCP three-way handshake While the destination host waits for the ACK to the SYN ACK, a connection queue of finite size on the destination host keeps track of connections waiting to be completed. This queue typically empties quickly because the ACK is expected to arrive a few milliseconds after the SYN ACK. The TCP SYN attack exploits this design by having an attacking source host generate TCP SYN packets with random source addresses toward a victim host. The victim destination host sends a SYN ACK back to the random source address and adds an entry to the connection queue. Because the SYN ACK is destined for an incorrect or nonexistent host, the last part of the TCP three-way handshake is never completed and the entry remains in the connection queue until a timer expires, typically for about one minute. When the source host rapidly generates TCP SYN packets from random IP addresses, the connection queue can be filled and TCP services (such as e-mail, file transfer, or WWW) can be denied to legitimate users.

The information needed for a security monitoring record for this type of DoS attack might include the following key and nonkey fields:

  • Key fields:
    • Destination IP address or destination IP subnet
    • TCP flags
    • Packet count
  • Nonkey fields
    • Destination IP address
    • Source IP address
    • Interface input and output

Tip


Many users configure a general Flexible NetFlow monitor that triggers a more detailed Flexible NetFlow view of a DoS attack using these key and nonkey fields.


Benefit of Emulating Original NetFlow with Flexible NetFlow

Emulating original NetFlow with Flexible NetFlow enables to you to deploy Flexible NetFlow quickly because you can use a predefined record instead of designing and configuring a custom user-defined record. You need only configure a flow monitor and apply it to an interface for Flexible NetFlow to start working like original NetFlow. You can add an optional exporter if you want to analyze the data that you collect with an application such as NetFlow collector.

Each flow monitor has a separate cache assigned to it. Each flow monitor requires a record to define the contents and layout of its cache entries. The record format can be one of the predefined record formats, or an advanced user may create his or her own record format using the collect and match commands in Flexible NetFlow flow record configuration mode.

Flow exporters are used to send the data that you collect with Flexible NetFlow to a remote system such as a NetFlow Collection Engine. Exporters use UDP as the transport protocol and use the Version 9 export format.

If you are familiar with original NetFlow, you already understand the format and content of the data that you collect and export with Flexible NetFlow when you emulate original NetFlow. You will be able to use the same techniques for analyzing the data.

Flexible NetFlow Predefined Records

Flexible NetFlow predefined records are based on the original NetFlow ingress and egress caches and the aggregation caches. The difference between the original NetFlow aggregation caches and the corresponding predefined Flexible NetFlow records is that the predefined records do not perform aggregation. Flexible NetFlow predefined records are associated with a Flexible NetFlow flow monitor the same way that you associate a user-defined (custom) record.

Benefits of Flexible NetFlow Predefined Records

If you have been using original NetFlow or original NetFlow with aggregation caches you can continue to capture the same traffic data for analysis when you migrate to Flexible NetFlow by using the predefined records available with Flexible NetFlow. Many users will find that the preexisting Flexible NetFlow records are suitable for the majority of their traffic analysis requirements.

NetFlow Original and NetFlow IPv4 Original Input Predefined Records

The Flexible NetFlow "NetFlow original" and "NetFlow IPv4 original input" predefined records can be used interchangeably because they have the same key and nonkey fields. The key and nonkey fields and the counters for the Flexible NetFlow "NetFlow original" and "NetFlow IPv4 original input" predefined records are shown in the table below.

Table 2. Key and Nonkey Fields Used by the Flexible NetFlow NetFlow Original and NetFlow IPv4 Original Input Predefined Records

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the type of service (ToS) field.

IP Protocol

Key

Value in the IP protocol field.

IP Source Address

Key

IP source address.

IP Destination Address

Key

IP destination address.

Transport Source Port

Key

Value of the transport layer source port field.

Transport Destination Port

Key

Value of the transport layer destination port field.

Interface Input

Key

Interface on which the traffic is received.

Flow Sampler ID

Key

ID number of the flow sampler (if flow sampling is enabled).

IP Source AS

Nonkey

Source autonomous system number.

IP Destination AS

Nonkey

Destination autonomous system number.

IP Next Hop Address

Nonkey

IP address of the next hop.

IP Source Mask

Nonkey

Mask for the IP source address.

IP Destination Mask

Nonkey

Mask for the IP destination address.

TCP Flags

Nonkey

Value in the TCP flag field.

Interface Output

Nonkey

Interface on which the traffic is transmitted.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

NetFlow IPv4 Original Output Predefined Record

The Flexible NetFlow "NetFlow IPv4 original output" predefined record is used to emulate the original NetFlow Egress NetFlow Accounting feature that was released in Cisco IOS Release 12.3(11)T. The key and nonkey fields and the counters for the Flexible NetFlow "NetFlow IPv4 original output" predefined record are shown in the table below.

Table 3. Key and Nonkey Fields Used by the Flexible NetFlow NetFlow IPv4 Original Output Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Protocol

Key

Value in the IP protocol field.

IP Source Address

Key

IP source address.

IP Destination Address

Key

IP destination address.

Transport Source Port

Key

Value of the transport layer source port field.

Transport Destination Port

Key

Value of the transport layer destination port field.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Sampler ID

Key

ID number of the flow sampler (if flow sampling is enabled).

IP Source AS

Nonkey

Source autonomous system number.

IP Destination AS

Nonkey

Destination autonomous system number.

IP Next Hop Address

Nonkey

IP address of the next hop.

IP Source Mask

Nonkey

Mask for the IP source address.

IP Destination Mask

Nonkey

Mask for the IP destination address.

TCP Flags

Nonkey

Value in the TCP flag field.

Interface Input

Nonkey

Interface on which the traffic is received.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

NetFlow IPv6 Original Input Predefined Record

The key and nonkey fields and the counters for the Flexible NetFlow "NetFlow IPv6 original input" predefined record are shown in the table below.

Table 4. Key and Nonkey Fields Used by the Flexible NetFlow NetFlow IPv6 Original Input Predefined Record

Field

Key or NonKey Field

Definition

Traffic Class

Key

Value in the traffic class field.

Flow Label

Key

Flow label.

Protocol

Key

Value in the protocol field.

Extension Map

Key

Value in the extension map bitmap.

IP Source Address

Key

IP source address.

IP Destination Address

Key

IP destination address.

Transport Source Port

Key

Value of the transport layer source port field.

Transport Destination Port

Key

Value of the transport layer destination port field.

Interface Input

Key

Interface on which the traffic is received.

Flow Direction

Key

The direction of the flow.

Flow Sampler

Key

ID number of the flow sampler (if flow sampling is enabled).

Routing Source AS

Nonkey

Source autonomous system number.

Routing Destination AS

Nonkey

Destination autonomous system number.

Routing Next-hop Address

Nonkey

IP address of the next hop.

IP Source Mask

Nonkey

Mask for the IP source address.

IP Destination Mask

Nonkey

Mask for the IP destination address.

Transport TCP Flags

Nonkey

Value in the TCP flag field.

Interface Output

Nonkey

Interface over which the traffic is transmitted.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

NetFlow IPv6 Original Output Predefined Record

The key and nonkey fields and the counters for the Flexible NetFlow "NetFlow IPv6 original output" predefined record are shown in the table below.

Table 5. Key and Nonkey Fields Used by the Flexible NetFlow NetFlow IPv6 Original Output Predefined Record

Field

Key or Nonkey Field

Definition

Traffic Class

Key

Value in the traffic class field.

Flow Label

Key

The flow label.

Protocol

Key

Value in the protocol field.

Extension Map

Key

Value in the extension map bitmap.

IP Source Address

Key

IP source address.

IP Destination Address

Key

IP destination address.

Transport Source Port

Key

Value of the transport layer source port field.

Transport Destination Port

Key

Value of the transport layer destination port field.

Interface Output

Key

Interface over which the traffic is transmitted.

Flow Direction

Key

The direction of the flow.

Flow Sampler

Key

ID number of the flow sampler (if flow sampling is enabled).

Routing Source AS

Nonkey

Source autonomous system number.

Routing Destination AS

Nonkey

Destination autonomous system number.

Routing Next-hop Address

Nonkey

IP address of the next hop.

IP Source Mask

Nonkey

Mask for the IP source address.

IP Destination Mask

Nonkey

Mask for the IP destination address.

Transport TCP Flags

Nonkey

Value in the TCP flag field.

Interface Input

Nonkey

Interface on which the traffic is received.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Autonomous System Predefined Record

The Flexible NetFlow "autonomous system" predefined record creates flows based on autonomous system-to-autonomous system traffic flow data. The Flexible NetFlow "autonomous system" predefined record uses the same key and nonkey fields as the original NetFlow "autonomous system" aggregation cache.


Note


This predefined record can be used to analyze IPv4 and IPv6 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "autonomous system" predefined record.

Table 6. Key and Nonkey Fields Used by the Flexible NetFlow Autonomous System Predefined Record

Field

Key or Nonkey Field

Definition

IP Source AS

Key

Autonomous system of the source IP address (peer or origin).

IP Destination AS

Key

Autonomous system of the destination IP address (peer or origin).

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds since this device was first booted) when the last packet was switched.

Autonomous System ToS Predefined Record

The Flexible NetFlow "autonomous system ToS" predefined record creates flows based on autonomous system-to-autonomous system and type of service (ToS) traffic flow data. The Flexible NetFlow "autonomous system ToS" predefined record uses the same key and nonkey fields as the original NetFlow "autonomous system ToS" aggregation cache.


Note


This predefined record can be used to analyze only IPv4 traffic.



Tip


This predefined record is particularly useful for generating autonomous system-to-autonomous system traffic flow data.


The table below lists the key and nonkey fields used in the Flexible NetFlow "autonomous system ToS" predefined record.

Table 7. Key and Nonkey Fields Used by the Flexible NetFlow Autonomous System ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

BGP Next-Hop Predefined Record

The Flexible NetFlow "BGP next-hop" predefined record creates flows based on Border Gateway Protocol (BGP) traffic flow data.


Note


This predefined record can be used to analyze only IPv6 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "BGP next-hop" predefined record.

Table 8. Key and Nonkey Fields Used by the Flexible NetFlow BGP Next-Hop Predefined Record

Field

Key or Nonkey Field

Definition

Routing Source AS

Key

Autonomous system of the source IP address.

Routing Destination AS

Key

Autonomous system of the destination IP address.

Routing Next-hop Address IPv6 BGP

Key

IPv6 address of the BGP next hop.

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Timestamp Sys-uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Timestamp Sys-uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

BGP Next-Hop ToS Predefined Record

The Flexible NetFlow "BGP next-hop ToS" predefined record creates flows based on BGP and ToS traffic flow data. The Flexible NetFlow "BGP next-hop ToS" predefined record uses the same key and nonkey fields as the original NetFlow "BGP next-hop ToS" aggregation cache.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the "BGP next-hop ToS" predefined record.

Table 9. Key and Nonkey Fields Used by the Flexible NetFlow BGP Next-Hop ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

IPv4 Next Hop Address BGP

Key

IPv4 address of the BGP next hop.

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Destination Prefix Predefined Record

The Flexible NetFlow "destination prefix" predefined record creates flows based on destination prefix traffic flow data. The Flexible NetFlow "destination prefix" predefined record uses the same key and nonkey fields as the original NetFlow "destination prefix" aggregation cache.


Note


This predefined record can be used to analyze IPv4 and IPv6 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "destination prefix" predefined record.

Table 10. Key and Nonkey Fields Used by the Flexible NetFlow Destination Prefix Predefined Record

Field

Key or Nonkey Field

Definition

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

IPv4 or IPv6 Destination Prefix

Key

Destination IP address ANDed with the destination prefix mask.

IPv4 or IPv6 Destination Mask

Key

Number of bits in the destination prefix.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Destination Prefix ToS Predefined Record

The Flexible NetFlow "destination prefix ToS" predefined record creates flows based on destination prefix and ToS traffic flow data. The Flexible NetFlow "destination prefix ToS" predefined record uses the same key and nonkey fields as the original NetFlow "destination prefix ToS" aggregation cache.

This predefined record is particularly useful for capturing data with which you can examine the destinations of network traffic passing through a NetFlow-enabled device.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "destination prefix ToS" predefined record.

Table 11. Key and Nonkey Fields Used by the Flexible NetFlow Destination Prefix ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

IPv4 Destination Prefix

Key

Destination IP address ANDed with the destination prefix mask.

IPv4 Destination Mask

Key

Number of bits in the destination prefix.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Prefix Predefined Record

The Flexible NetFlow "prefix" predefined record creates flows based on the source and destination prefixes in the traffic flow data. The Flexible NetFlow "prefix" predefined record uses the same key and nonkey fields as the original NetFlow "prefix" aggregation cache.


Note


This predefined record can be used to analyze IPv4 and IPv6 traffic. For IPv6 traffic, a minimum prefix mask length of 0 bits is assumed.


The table below lists the key and nonkey fields used in the Flexible NetFlow "prefix" predefined record.

Table 12. Key and Nonkey Fields Used by the Flexible NetFlow Prefix Predefined Record

Field

Key or Nonkey Field

Definition

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

IPv4 or IPv6 Source Prefix

Key

Source IP address ANDed with the source prefix mask, or the prefix to which the source IP address of the aggregated flows belongs.

IPv4 or IPv6 Source Mask

Key

Number of bits in the source prefix.

IPv4 or IPv6 Destination Prefix

Key

Destination IP address ANDed with the destination prefix mask.

IPv4 or IPv6 Destination Mask

Key

Number of bits in the destination prefix.

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Prefix Port Predefined Record

The Flexible NetFlow "prefix port" predefined record creates flows based on source and destination prefixes and ports in the traffic flow data. The Flexible NetFlow "prefix port" predefined record uses the same key and nonkey fields as the original NetFlow "prefix port" aggregation cache.

This predefined record is particularly useful for capturing data with which you can examine the sources and destinations of network traffic passing through a NetFlow-enabled device.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the destination Flexible NetFlow "prefix port" predefined record.

Table 13. Key and Nonkey Fields Used by the Flexible NetFlow Prefix Port Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Protocol

Key

Value in the IP protocol field.

IPv4 Source Prefix

Key

Source IP address ANDed with the source prefix mask, or the prefix to which the source IP address of the aggregated flows belongs.

IPv4 Source Mask

Key

Number of bits in the source prefix.

IPv4 Destination Prefix

Key

Destination IP address ANDed with the destination prefix mask.

IPv4 Destination Mask

Key

Number of bits in the destination prefix.

Transport Source Port

Key

Value in the transport layer source port field.

Transport Destination Port

Key

Value in the transport layer destination port field.

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Prefix ToS Predefined Record

The Flexible NetFlow "prefix ToS" predefined record creates flows based on source and destination prefixes and ToS traffic flow data. The Flexible NetFlow "prefix ToS" predefined record uses the same key and nonkey fields as the original NetFlow "destination prefix ToS" aggregation cache.

This predefined record is particularly useful for capturing data with which you can examine the sources and destinations of network traffic passing through a NetFlow-enabled device.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "prefix ToS" predefined record.

Table 14. Key and Nonkey Fields Used by the Flexible NetFlow Prefix ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IP Destination autonomous system

Key

Autonomous system of the destination IP address (peer or origin).

IPv4 Source Prefix

Key

Source IP address ANDed with the source prefix mask, or the prefix to which the source IP address of the aggregated flows belongs.

IPv4 Source Mask

Key

Number of bits in the source prefix.

IPv4 Destination Prefix

Key

Destination IP address ANDed with the destination prefix mask.

IPv4 Destination Mask

Key

Number of bits in the destination prefix.

Interface Input

Key

Interface on which the traffic is received.

Interface Output

Key

Interface on which the traffic is transmitted.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Protocol Port Predefined Record

The Flexible NetFlow "protocol port" predefined record creates flows based on protocols and ports in the traffic flow data. The Flexible NetFlow "protocol port" predefined record uses the same key and nonkey fields as the original NetFlow "protocol port" aggregation cache.


Note


This predefined record can be used to analyze IPv4 and IPv6 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "protocol port" predefined record.

Table 15. Key and Nonkey Fields Used by the Flexible NetFlow Protocol Port Predefined Record

Field

Key or Nonkey Field

Definition

IP Protocol

Key

Value in the IP protocol field.

Transport Source Port

Key

Value in the transport layer source port field.

Transport Destination Port

Key

Value in the transport layer destination port field.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Protocol Port ToS Predefined Record

The Flexible NetFlow "protocol port ToS" predefined record creates flows based on the protocol, port, and ToS value in the traffic data. The Flexible NetFlow "protocol port ToS" predefined record uses the same key and nonkey fields as the original NetFlow "protocol port ToS" aggregation cache.

This predefined record is particularly useful for capturing data with which you can examine network usage by type of traffic.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "protocol port ToS" predefined record.

Table 16. Key and Nonkey Fields Used by the Flexible NetFlow Protocol Port ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Protocol

Key

Value in the IP protocol field.

Transport Source Port

Key

Value in the transport layer source port field.

Transport Destination Port

Key

Value in the transport layer destination port field.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Source Prefix Predefined Record

The Flexible NetFlow "source prefix" predefined record creates flows based on source prefixes in the network traffic. The Flexible NetFlow "source prefix" predefined record uses the same key and nonkey fields as the original NetFlow "source prefix" aggregation cache.


Note


This predefined record can be used to analyze IPv4 and IPv6 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "source prefix" predefined record.

Table 17. Key and Nonkey Fields Used by the Flexible NetFlow Source Prefix Predefined Record

Field

Key or Nonkey Field

Definition

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IPv4 or IPv6 Source Prefix

Key

Source IP address ANDed with the source prefix mask, or the prefix to which the source IP address of the aggregated flows belongs.

IPv4 or IPv6 Source Mask

Key

Number of bits in the source prefix.

Interface Input

Key

Interface on which the traffic is received.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

Source Prefix ToS Predefined Record

The Flexible NetFlow "source prefix ToS" predefined record creates flows based on source prefixes and ToS values in the network traffic. The Flexible NetFlow "source prefix ToS" predefined record uses the same key and nonkey fields as the original NetFlow "source prefix ToS" aggregation cache.

This predefined record is particularly useful for capturing data with which you can examine the sources of network traffic passing through a NetFlow-enabled device.


Note


This predefined record can be used to analyze only IPv4 traffic.


The table below lists the key and nonkey fields used in the Flexible NetFlow "source prefix ToS" predefined record.

Table 18. Key and Nonkey Fields Used by the Flexible NetFlow Source Prefix ToS Predefined Record

Field

Key or Nonkey Field

Definition

IP ToS

Key

Value in the ToS field.

IP Source autonomous system

Key

Autonomous system of the source IP address (peer or origin).

IPv4 Source Prefix

Key

Source IP address ANDed with the source prefix mask, or the prefix to which the source IP address of the aggregated flows belongs.

IPv4 Source Mask

Key

Number of bits in the source prefix.

Interface Input

Key

Interface on which the traffic is received.

Flow Direction

Key

Direction in which the flow is being monitored.

Counter Bytes

Nonkey

Number of bytes seen in the flow.

Counter Packets

Nonkey

Number of packets seen in the flow.

Time Stamp System Uptime First

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the first packet was switched.

Time Stamp System Uptime Last

Nonkey

System uptime (time, in milliseconds, since this device was first booted) when the last packet was switched.

How to Configure Flexible Netflow

Creating a Flow Record

Perform this task to configure a customized flow record.

Customized flow records are used to analyze traffic data for a specific purpose. A customized flow record must have at least one match criterion for use as the key field and typically has at least one collect criterion for use as a nonkey field.

There are hundreds of possible permutations of customized flow records. This task shows the steps that are used to create one of the possible permutations. Modify the steps in this task as appropriate to create a customized flow record for your requirements.

SUMMARY STEPS

  1. enable
  2. configure terminal
  3. flow record record-name
  4. description description
  5. match {ip | ipv6 } {destination | source } address
  6. Repeat Step 5 as required to configure additional key fields for the record.
  7. match flow cts {source | destination } group-tag
  8. Repeat the above step as required to configure additional nonkey fields for the record.
  9. end
  10. show flow record record-name
  11. show running-config flow record record-name

DETAILED STEPS

  Command or Action Purpose

Step 1

enable

Example:


Device> enable

Enables privileged EXEC mode.

  • Enter your password if prompted.

Step 2

configure terminal

Example:


Device# configure terminal

Enters global configuration mode.

Step 3

flow record record-name

Example:


Device(config)# flow record FLOW-RECORD-1

Creates a flow record and enters Flexible NetFlow flow record configuration mode.

  • This command also allows you to modify an existing flow record.

Step 4

description description

Example:


Device(config-flow-record)# description Used for basic traffic analysis

(Optional) Creates a description for the flow record.

Step 5

match {ip | ipv6 } {destination | source } address

Example:


Device(config-flow-record)# match ipv4 destination address

Note

 

This example configures the IPv4 destination address as a key field for the record. For information about the other key fields available for the match ipv4 command, and the other match commands that are available to configure key fields.

Step 6

Repeat Step 5 as required to configure additional key fields for the record.

Step 7

match flow cts {source | destination } group-tag

Example:


Device(config-flow-record)# match flow cts source group-tag

Device(config-flow-record)# match flow cts destination group-tag

Note

 

This example configures the CTS source group tag and destination group tag as a key field for the record. For information about the other key fields available for the match ipv4/ ipv6 command, and the other match commands that are available to configure key fields.

Note

 
  • Ingress:
    • In an incoming packet, if a header is present, SGT will reflect the same value as the header. If no value is present, it will show zero.

    • The DGT value will not depend on the ingress port SGACL configuration.

  • Egress:
    • If either propagate SGT or CTS is disabled on the egress interface, then SGT will be zero.

    • In an outgoing packet, if SGACL configuration that corresponds to the (SGT, DGT) exists, DGT will be non-zero.

    • If SGACL is disabled on the egress port/VLAN or if global SGACL enforcement is disabled, then DGT will be zero

Step 8

Example:



Configures the input interface as a nonkey field for the record.

Note

 

This example configures the input interface as a nonkey field for the record.

Step 9

Repeat the above step as required to configure additional nonkey fields for the record.

Step 10

end

Example:


Device(config-flow-record)# end

Exits Flexible NetFlow flow record configuration mode and returns to privileged EXEC mode.

Step 11

show flow record record-name

Example:


Device# show flow record FLOW_RECORD-1

(Optional) Displays the current status of the specified flow record.

Step 12

show running-config flow record record-name

Example:


Device# show running-config flow record FLOW_RECORD-1 

(Optional) Displays the configuration of the specified flow record.

Displaying the Current Status of a Flow Record

Perform this optional task to display the current status of a flow record.

Procedure


Step 1

enable

The enable command enters privileged EXEC mode (enter the password if prompted).

Example:


Device> enable
Device#

Step 2

show flow record

The show flow record command shows the current status of the flow monitor that you specify.

Example:


Device# show flow record

flow record FLOW-RECORD-2:
  Description:        Used for basic IPv6 traffic analysis
  No. of users:       1
  Total field space:  53 bytes
  Fields:
    match ipv6 destination address
    collect counter bytes
    collect counter packets
flow record FLOW-RECORD-1:
  Description:        Used for basic IPv4 traffic analysis
  No. of users:       1
  Total field space:  29 bytes
  Fields:
    match ipv4 destination address
    collect counter bytes
    collect counter packets

Verifying the Flow Record Configuration

Perform this optional task to verify the configuration commands that you entered.

Procedure


Step 1

enable

The enable command enters privileged EXEC mode (enter the password if prompted).

Example:


Device> enable
Device#

Step 2

show running-config flow record

The show running-config flow record command shows the configuration commands of the flow monitor that you specify.

Example:


Device# show running-config flow record

Current configuration:
!
flow record FLOW-RECORD-2
 description Used for basic IPv6 traffic analysis
 match ipv6 destination address
 collect counter bytes
 collect counter packets
!
flow record FLOW-RECORD-1
 description Used for basic IPv4 traffic analysis
 match ipv4 destination address
 collect counter bytes
 collect counter packets
 

!

Configuring a Flow Monitor for IPv4 or IPv6 Traffic Using the Predefined Record

To configure a flow monitor for IPv4/IPv6 traffic using the Flexible NetFlow "NetFlow IPv4/IPv6 original input" predefined record for the flow monitor, perform the following required task.

Each flow monitor has a separate cache assigned to it. Each flow monitor requires a record to define the contents and layout of its cache entries. The record format can be one of the predefined record formats, or an advanced user may create his or her own record format using the collect and match commands in Flexible NetFlow flow record configuration mode.


Note


You must remove a flow monitor from all of the interfaces to which you have applied it before you can modify the record format of the flow monitor.


SUMMARY STEPS

  1. enable
  2. configure terminal
  3. flow monitor monitor-name
  4. description description
  5. record netflow {ipv4 | ipv6} original-input
  6. end
  7. show flow monitor [[name ] monitor-name [cache [format {csv | record | table }]][statistics ]]
  8. show running-config flow monitor monitor-name

DETAILED STEPS

  Command or Action Purpose

Step 1

enable

Example:


Device> enable

Enables privileged EXEC mode.

  • Enter your password if prompted.

Step 2

configure terminal

Example:


Device# configure terminal

Enters global configuration mode.

Step 3

flow monitor monitor-name

Example:


Device(config)# flow monitor FLOW-MONITOR-1

Creates a flow monitor and enters Flexible NetFlow flow monitor configuration mode.

  • This command also allows you to modify an existing flow monitor.

Step 4

description description

Example:


Device(config-flow-monitor)# description Used for monitoring IPv4 traffic

(Optional) Creates a description for the flow monitor.

Step 5

record netflow {ipv4 | ipv6} original-input

Example:


Device(config-flow-monitor)# record netflow ipv4 original-input 

Specifies the record for the flow monitor.

Step 6

end

Example:


Device(config-flow-monitor)# end

Exits Flexible NetFlow flow monitor configuration mode and returns to privileged EXEC mode.

Step 7

show flow monitor [[name ] monitor-name [cache [format {csv | record | table }]][statistics ]]

Example:


Device# show flow monitor FLOW-MONITOR-2 cache

(Optional) Displays the status and statistics for a Flexible NetFlow flow monitor.

Step 8

show running-config flow monitor monitor-name

Example:


Device# show flow monitor FLOW_MONITOR-1

(Optional) Displays the configuration of the specified flow monitor.

Configuring a Flow Exporter for the Flow Monitor

Perform this optional task to configure a flow exporter for the flow monitor in order to export the data that is collected by Flexible NetFlow to a remote system for further analysis and storage.

Flow exporters are used to send the data that you collect with Flexible NetFlow to a remote system such as a NetFlow Collection Engine. Exporters use UDP as the transport protocol and use the Version 9 export format.


Note


Each flow exporter supports only one destination. If you want to export the data to multiple destinations, you must configure multiple flow exporters and assign them to the flow monitor.

You can export to a destination using either an IPv4 or IPv6 address.



Note


When you configure an exporter, configure the exporter in such a way that the source interface is defined as a WAN interface. This configuration helps you prevent any unpredictable behavior because the NAT is not applied on the packets.


SUMMARY STEPS

  1. enable
  2. configure terminal
  3. flow exporter exporter-name
  4. description description
  5. destination {hostname | ip-address } [vrf vrf-name ]
  6. export-protocol {netflow-v5 | netflow-v9 | ipfix }
  7. transport udp udp-port
  8. exit
  9. flow monitor flow-monitor-name
  10. exporter exporter-name
  11. end
  12. show flow exporter exporter-name
  13. show running-config flow exporter exporter-name

DETAILED STEPS

  Command or Action Purpose

Step 1

enable

Example:


Device> enable

Enables privileged EXEC mode.

  • Enter your password if prompted.

Step 2

configure terminal

Example:


Device# configure terminal

Enters global configuration mode.

Step 3

flow exporter exporter-name

Example:


Device(config)# flow exporter EXPORTER-1

Creates a flow exporter and enters Flexible NetFlow flow exporter configuration mode.

  • This command also allows you to modify an existing flow exporter.

Step 4

description description

Example:


Device(config-flow-exporter)# description Exports to datacenter

(Optional) Creates a description for the flow exporter.

Step 5

destination {hostname | ip-address } [vrf vrf-name ]

Example:


Device(config-flow-exporter)# destination 172.16.10.2

Specifies the hostname or IP address of the system to which the exporter sends data.

Note

 

You can export to a destination using either an IPv4 or IPv6 address.

Step 6

export-protocol {netflow-v5 | netflow-v9 | ipfix }

Example:


Device(config-flow-exporter)# export-protocol netflow-v9

Specifies the version of the NetFlow export protocol used by the exporter.

  • Default: netflow-v9 .

Step 7

transport udp udp-port

Example:


Device(config-flow-exporter)# transport udp 65

Configures UDP as the transport protocol and specifies the UDP port on which the destination system is listening for exported Flexible NetFlow traffic.

Step 8

exit

Example:


Device(config-flow-exporter)# exit

Exits Flexible NetFlow flow exporter configuration mode and returns to global configuration mode.

Step 9

flow monitor flow-monitor-name

Example:


Device(config)# flow monitor FLOW-MONITOR-1

Enters Flexible NetFlow flow monitor configuration mode for the flow monitor that you created previously.

Step 10

exporter exporter-name

Example:


Device(config-flow-monitor)# exporter EXPORTER-1 

Specifies the name of an exporter that you created previously.

Step 11

end

Example:


Device(config-flow-monitor)# end

Exits Flexible NetFlow flow monitor configuration mode and returns to privileged EXEC mode.

Step 12

show flow exporter exporter-name

Example:


Device# show flow exporter FLOW_EXPORTER-1

(Optional) Displays the current status of the specified flow exporter.

Step 13

show running-config flow exporter exporter-name

Example:


Device<# show running-config flow exporter FLOW_EXPORTER-1 

(Optional) Displays the configuration of the specified flow exporter.

Creating a Flow Monitor

Perform this required task to create a customized flow monitor.

Each flow monitor has a separate cache assigned to it. Each flow monitor requires a record to define the contents and layout of its cache entries. These record formats can be a user-defined format. An advanced user can create a customized format using the flow record command.

Before you begin

If you want to use a customized record, you must create the customized record before you can perform this task. If you want to add a flow exporter to the flow monitor for data export, you must create the exporter before you can complete this task.


Note


You must use the no ip flow monitor command to remove a flow monitor from all of the interfaces to which you have applied it before you can modify the parameters for the record command on the flow monitor.


SUMMARY STEPS

  1. enable
  2. configure terminal
  3. flow monitor monitor-name
  4. description description
  5. record {record-name }
  6. cache {timeout {active } seconds | { normal }
  7. Repeat Step 6 as required to finish modifying the cache parameters for this flow monitor.
  8. exporter exporter-name
  9. end
  10. show flow monitor [[name ] monitor-name [cache [format {csv | record | table } ]] ]
  11. show running-config flow monitor monitor-name

DETAILED STEPS

  Command or Action Purpose

Step 1

enable

Example:


Device> enable

Enables privileged EXEC mode.

  • Enter your password if prompted.

Step 2

configure terminal

Example:


Device# configure terminal

Enters global configuration mode.

Step 3

flow monitor monitor-name

Example:


Device(config)# flow monitor FLOW-MONITOR-1

Creates a flow monitor and enters Flexible NetFlow flow monitor configuration mode.

  • This command also allows you to modify an existing flow monitor.

Step 4

description description

Example:


Device(config-flow-monitor)# description Used for basic ipv4 traffic analysis

(Optional) Creates a description for the flow monitor.

Step 5

record {record-name }

Example:


Device(config-flow-monitor)# record FLOW-RECORD-1

Specifies the record for the flow monitor.

Step 6

cache {timeout {active } seconds | { normal }

Example:

    Step 7

    Repeat Step 6 as required to finish modifying the cache parameters for this flow monitor.

    Step 8

    exporter exporter-name

    Example:

    
    Device(config-flow-monitor)# exporter EXPORTER-1 

    (Optional) Specifies the name of an exporter that was created previously.

    Step 9

    end

    Example:

    
    Device(config-flow-monitor)# end

    Exits Flexible NetFlow flow monitor configuration mode and returns to privileged EXEC mode.

    Step 10

    show flow monitor [[name ] monitor-name [cache [format {csv | record | table } ]] ]

    Example:

    
    Device# show flow monitor FLOW-MONITOR-2 cache

    (Optional) Displays the status for a Flexible NetFlow flow monitor.

    Step 11

    show running-config flow monitor monitor-name

    Example:

    
    Device# show running-config flow monitor FLOW_MONITOR-1

    (Optional) Displays the configuration of the specified flow monitor.

    Displaying the Current Status of a Flow Monitor

    Perform this optional task to display the current status of a flow monitor.

    SUMMARY STEPS

    1. enable
    2. show flow monitor monitor-name

    DETAILED STEPS


    Step 1

    enable

    The enable command enters privileged EXEC mode (enter the password if prompted).

    Example:

    
    Device> enable
    Device#
    

    Step 2

    show flow monitor monitor-name

    The show flow monitor command shows the current status of the flow monitor that you specify.

    Example:

    
    Device# show flow monitor FLOW-MONITOR-1
    
    Flow Monitor FLOW-MONITOR-1:
      Description:       Used for basic ipv4 traffic analysis
      Flow Record:       FLOW-RECORD-1
      Flow Exporter:     EXPORTER-1
      Cache:
        Type:              normal
        Status:            allocated
        
        Inactive Timeout:  15 secs
        Active Timeout:    1800 secs
        Update Timeout:    1800 secs
      

    Displaying the Data in the Flow Monitor Cache

    Perform this optional task to display the data in the flow monitor cache.

    Before you begin

    The interface on which you applied the input flow monitor must be receiving traffic that meets the criteria defined by the NetFlow original record before you can display the flows in the flow monitor cache.

    SUMMARY STEPS

    1. enable
    2. show flow monitor name monitor-name cache format record

    DETAILED STEPS


    Step 1

    enable

    The enable command enters privileged EXEC mode (enter the password if prompted).

    Example:

    
    Device> enable
    Device#
    

    Step 2

    show flow monitor name monitor-name cache format record

    The show flow monitor name monitor-name cache format record command string displays the status, statistics, and flow data in the cache for a flow monitor.

    Example:

    
    Device# show flow monitor name FLOW-MONITOR-1 cache format record
    
    Cache type:                            Normal
      
      Current entries:                            4
      High Watermark:                             4
      Flows added:                              101
      Flows aged:                                97
        - Active timeout   (  1800 secs)          3
        - Inactive timeout (    15 secs)         94
        - Event aged                              0
        - Watermark aged                          0
        - Emergency aged                          0
    IPV4 DESTINATION ADDRESS:  172.16.10.5
    ipv4 source address:       10.10.11.1
    trns source port:          25
    trns destination port:     25
    counter bytes:             72840
    counter packets:           1821
    IPV4 DESTINATION ADDRESS:  172.16.10.2
    ipv4 source address:       10.10.10.2
    trns source port:          20
    trns destination port:     20
    counter bytes:             3913860
    counter packets:           7326
    IPV4 DESTINATION ADDRESS:  172.16.10.200
    ipv4 source address:       192.168.67.6
    trns source port:          0
    trns destination port:     3073
    counter bytes:             51072
    counter packets:           1824
    
    Device# show flow monitor name FLOW-MONITOR-2 cache format record
    
    Cache type:                            Normal
      
      Current entries:                            2
      High Watermark:                             3
      Flows added:                               95
      Flows aged:                                93
        - Active timeout   (  1800 secs)          0
        - Inactive timeout (    15 secs)         93
        - Event aged                              0
        - Watermark aged                          0
        - Emergency aged                          0
    IPV6 DESTINATION ADDRESS:  2001:DB8:4:ABCD::2
    ipv6 source address:       2001:DB8:1:ABCD::1
    trns source port:          33572
    trns destination port:     23
    counter bytes:             19140
    counter packets:           349
    IPV6 DESTINATION ADDRESS:  FF02::9
    ipv6 source address:       FE80::A8AA:BBFF:FEBB:CC03
    trns source port:          521
    trns destination port:     521
    counter bytes:             92
    counter packets:           1
    

    Verifying the Flow Monitor Configuration

    Perform this optional task to verify the configuration commands that you entered.

    SUMMARY STEPS

    1. enable
    2. show running-config flow monitor

    DETAILED STEPS


    Step 1

    enable

    The enable command enters privileged EXEC mode (enter the password if prompted).

    Example:

    
    Device> enable
    Device#
    

    Step 2

    show running-config flow monitor

    The show running-config flow monitor command shows the configuration commands of the flow monitor that you specify.

    Example:

    
    Device# show running-config flow monitor FLOW-MONITOR-1
    
    Current configuration:
    !
    flow monitor FLOW-MONITOR-1
     description Used for basic ipv4 traffic analysis
     record FLOW-RECORD-1
     exporter EXPORTER-1
     
    !
    

    Applying a Flow Monitor to an Interface

    Before it can be activated, a flow monitor must be applied to at least one interface. Perform this required task to activate a flow monitor.

    While running the ip flow monitor command for the first interface to enable FNF monitor, you may see the following warning message displaying a GLOBAL memory allocation failure. This log is triggered by enabling FNF monitoring with a large cache size.

    Jul  4 01:45:00.255: %CPPEXMEM-3-NOMEM: F0/0: cpp_cp_svr: QFP: 0, GLOBAL memory allocation of 90120448 bytes by FNF failed
    Jul  4 01:45:00.258: %CPPEXMEM-3-TOPUSER: F0/0: cpp_cp_svr: QFP: 0, Top User: CPR STILE EXMEM GRAPH, Allocations: 877, Type: GLOBAL
    Jul  4 01:45:00.258: %CPPEXMEM-3-TOPUSER: F0/0: cpp_cp_svr: QFP: 0, Top User: SBC, Bytes Allocated: 53850112, Type: GLOBAL
    

    The warning message does not necessarily indicate a flow monitor application failure. The warning message can indicate internal steps that FNF uses for applying memory from the EXMEM infrastructure.

    To ensure that the FNF monitor is enabled successfully, use the show flow monitor monitor-name command to check Status (allocated or not allocated) of a flow monitor. For more information, see Displaying the Current Status of a Flow Monitor.

    SUMMARY STEPS

    1. enable
    2. configure terminal
    3. interface type number
    4. {ip | ipv6 } flow monitor monitor-name {input | output }
    5. Repeat Steps 3 and 4 to activate a flow monitor on any other interfaces in the device over which you want to monitor traffic.
    6. end
    7. show flow interface type number
    8. show flow monitor name monitor-name cache format record

    DETAILED STEPS

      Command or Action Purpose

    Step 1

    enable

    Example:

    
    Device> enable

    Enables privileged EXEC mode.

    • Enter your password if prompted.

    Step 2

    configure terminal

    Example:

    
    Device# configure terminal

    Enters global configuration mode.

    Step 3

    interface type number

    Example:

    
    Device(config)# interface GigabitEthernet 0/0/0
    

    Specifies an interface and enters interface configuration mode.

    Step 4

    {ip | ipv6 } flow monitor monitor-name {input | output }

    Example:

    
    Device(config-if)# ip flow monitor FLOW-MONITOR-1 input

    Activates a flow monitor that was created previously by assigning it to the interface to analyze traffic.

    Step 5

    Repeat Steps 3 and 4 to activate a flow monitor on any other interfaces in the device over which you want to monitor traffic.

    Step 6

    end

    Example:

    
    Device(config-if)# end

    Exits interface configuration mode and returns to privileged EXEC mode.

    Step 7

    show flow interface type number

    Example:

    
    Device# show flow interface GigabitEthernet 0/0/0
    

    Displays the status of Flexible NetFlow (enabled or disabled) on the specified interface.

    Step 8

    show flow monitor name monitor-name cache format record

    Example:

    
    Device# show flow monitor name FLOW_MONITOR-1 cache format record

    Displays the status, statistics, and flow data in the cache for the specified flow monitor.

    Verifying That Flexible NetFlow Is Enabled on an Interface

    Perform this optional task to verify that Flexible NetFlow is enabled on an interface.

    SUMMARY STEPS

    1. enable
    2. show flow interface type number

    DETAILED STEPS


    Step 1

    enable

    The enable command enters privileged EXEC mode (enter the password if prompted).

    Example:

    
    Device> enable
    Device#
    

    Step 2

    show flow interface type number

    The show flow interface command verifies that Flexible NetFlow is enabled on an interface.

    Example:

    
    Device# show flow interface GigabitEthernet 0/0/0
    
    Interface GigabitEthernet0/0/0
      FNF:  monitor:         FLOW-MONITOR-1
            direction:       Input
            traffic(ip):     on
      FNF:  monitor:         FLOW-MONITOR-2
            direction:       Input
            traffic(ipv6):   on
    Device# show flow interface GigabitEthernet 1/0/0
    Interface GigabitEthernet1/0/0
      FNF:  monitor:         FLOW-MONITOR-1
            direction:       Output
            traffic(ip):     on
      FNF:  monitor:         FLOW-MONITOR-2
            direction:       Input
            traffic(ipv6):   on
    

    Configuration Examples for Flexible Netflow

    Example: Configuring a Flexible NetFlow Predefined Record for IPv4 Traffic

    The following example shows how to configure a flow monitor using the Flexible NetFlow "BGP ToS next-hop" predefined record to monitor IPv4 traffic.

    This sample starts in global configuration mode:

    
    !
    flow monitor FLOW-MONITOR-1
     record netflow ipv4 bgp-nexthop-tos
     exit
    !
    ip cef
    !
    interface Ethernet 0/0
     ip address 172.16.6.2 255.255.255.0
     ip flow monitor FLOW-MONITOR-1 input
    !

    Example: Configuring a Flexible NetFlow Predefined Record for IPv6 Traffic

    The following example shows how to configure a flow monitor using the Flexible NetFlow "source prefix" predefined record to monitor IPv6 traffic.

    This sample starts in global configuration mode:

    
    !
    flow monitor FLOW-MONITOR-2
     record netflow ipv6 source-prefix
     exit
    ip cef
    ipv6 cef
    !
    interface GigabitEthernet 0/0/0
     ipv6 address 2001:DB8:2:ABCD::2/48
     ipv6 flow monitor FLOW-MONITOR-2 input
    !

    Example: Configuring a Normal Flow Record Cache with a Limited Number of Flows

    The following example is designed to monitor the type of service (ToS) field usage on all interfaces in the router. An exporter is not configured because this example is intended to be used to capture additional data for analysis on the router using the show flow monitor command.

    This example starts in global configuration mode.

    
    !
    flow record QOS_RECORD
     description UD: Flow Record to monitor the use of TOS within this router/network
     match interface input
     match interface output
     match ipv4 tos
     collect counter packets
     collect counter bytes
     exit
    !
    flow monitor QOS_MONITOR
     description UD: Flow Monitor which watches the limited combinations of interface and TOS
     record QOS_RECORD
     cache type normal
     cache entries 8192   ! 2^5 (combos of interfaces) * 256 (values of TOS)
     exit
    !
    interface GigabitEthernet0/0/0
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface GigabitEthernet0/1/0
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface GigabitEthernet0/2/0
     ip flow monitor QOS_MONITOR input
     exit
    !
    

    The display from the show flow monitor command shows the current status of the cache.

    
    Router# show flow monitor QOS_MONITOR cache
    
      Cache type: 										 Normal
      Cache size:                              8192
      Current entries:                            2
      High Watermark:                             2
      Flows added:                                2
      Updates sent         (  1800 secs)          0
    

    Example: Configuring a Customized Flow Record Cache for Monitoring IPv6 Traffic

    The following example creates a customized flow record cache for monitoring IPv6 traffic.

    This example starts in global configuration mode.

    Example: Configuring a Permanent Flow Record Cache with a Limited Number of Flows

    The following example is designed to monitor the type of service (ToS) field usage on all interfaces in the router. An exporter is not configured because this example is intended to be used to capture additional data for analysis on the router using the show flow monitor command.

    This example starts in global configuration mode.

    
    !
    ip cef
    !
    flow record QOS_RECORD
     description UD: Flow Record to monitor the use of TOS within this router/network
     match interface input
     match interface output
     match ipv4 tos
     collect counter packets
     collect counter bytes
     exit
    !
    flow monitor QOS_MONITOR
     description UD: Flow Monitor which watches the limited combinations of interface and TOS
     record QOS_RECORD
     cache type permanent
     cache entries 8192   ! 2^5 (combos of interfaces) * 256 (values of TOS)
     exit
    !
    interface ethernet0/0
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface ethernet0/1
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface ethernet0/2
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface serial2/0
     ip flow monitor QOS_MONITOR input
     exit
    !
    interface serial2/1
     ip flow monitor QOS_MONITOR input
    !

    The display from the show flow monitor command shows the current status of the cache.

    
    Router# show flow monitor QOS_MONITOR cache
      Cache type:                         Permanent
      Cache size:                              8192
      Current entries:                            2
      High Watermark:                             2
      Flows added:                                2
      Updates sent         (  1800 secs)          0
    

    Example: Configuring Flexible NetFlow Egress Accounting for IPv4 and IPv6 Traffic

    The following example shows how to configure Flexible NetFlow egress accounting for IPv4 and IPv6 traffic.

    This example starts in global configuration mode.

    
    !
    flow record v4_r1
    match ipv4 tos
    match ipv4 protocol
    match ipv4 source address
    match ipv4 destination address
    match transport source-port
    match transport destination-port
    collect counter bytes long
    collect counter packets long
    !
    flow record v6_r1
    match ipv6 traffic-class
    match ipv6 protocol
    match ipv6 source address
    match ipv6 destination address
    match transport source-port
    match transport destination-port
    collect counter bytes long
    collect counter packets long
    !
    flow monitor FLOW-MONITOR-1
     record v4_r1
     exit
    !
    !
    flow monitor FLOW-MONITOR-2
     record v6_r1
     exit
    !
    ip cef
    ipv6 cef
    !
    interface GigabitEthernet0/0/0
     ip address 172.16.6.2 255.255.255.0
     ipv6 address 2001:DB8:2:ABCD::2/48
     ip flow monitor FLOW-MONITOR-1 output
     ipv6 flow monitor FLOW-MONITOR-2 output
    !

    Example: Configuring Flexible NetFlow Subinterface Support

    The following example shows how to configure Flexible NetFlow subinterface support for IPv4 traffic.

    This example starts in global configuration mode.

    
    !
    flow record v4_r1
    match ipv4 tos
    match ipv4 protocol
    match ipv4 source address
    match ipv4 destination address
    match transport source-port
    match transport destination-port
    collect counter bytes long
    collect counter packets long
    !
    flow monitor FLOW-MONITOR-1
     record v4_r1
     exit
    !
    ip cef
    !
    interface Ethernet0/0.1
     ip address 172.16.6.2 255.255.255.0
     ip flow monitor FLOW-MONITOR-1 input
    !

    The following example shows how to configure Flexible NetFlow to emulate NetFlow subinterface support for IPv6 traffic.

    This sample starts in global configuration mode:

    
    !
    flow record v6_r1
    
    match ipv6 protocol
    match ipv6 source address
    match ipv6 destination address
    match transport source-port
    match transport destination-port
    collect counter bytes long
    collect counter packets long
    
    !
    flow monitor FLOW-MONITOR-2
     record v6_r1
     exit
    !
    ip cef
    ipv6 cef
    !
    interface Ethernet0/0.1
     ipv6 address 2001:DB8:2:ABCD::2/48
     ipv6 flow monitor FLOW-MONITOR-2 input
    !

    Example: Configuring Flexible NetFlow Multiple Export Destinations

    The following example shows how to configure Flexible NetFlow multiple export destinations.

    This example starts in global configuration mode.

    
    !
    flow exporter EXPORTER-1
     destination 172.16.10.2
     transport udp 90
     exit
    !
    flow exporter EXPORTER-2
     destination 172.16.10.3
     transport udp 90
     exit
    !
    flow monitor FLOW-MONITOR-1
     record netflow-original
     exporter EXPORTER-2
     exporter EXPORTER-1
     exit
    !
    ip cef
    !
    interface GigabitEthernet0/0/0
     ip address 172.16.6.2 255.255.255.0
     ip flow monitor FLOW-MONITOR-1 input
    !

    Additional References

    Related Documents

    Related Topic

    Document Title

    Cisco IOS commands

    Cisco IOS Master Command List, All Releases

    Flexible NetFlow conceptual information and configuration tasks

    Flexible NetFlow Configuration Guide

    Flexible NetFlow commands

    Cisco IOS Flexible NetFlow Command Reference

    Standards/RFCs

    Standard

    Title

    No new or modified standards/RFCs are supported by this feature.

    MIBs

    MIB

    MIBs Link

    None

    To locate and download MIBs for selected platforms, Cisco software releases, and feature sets, use Cisco MIB Locator found at the following URL:

    http://www.cisco.com/go/mibs

    Technical Assistance

    Description

    Link

    The Cisco Support and Documentation website provides online resources to download documentation, software, and tools. Use these resources to install and configure the software and to troubleshoot and resolve technical issues with Cisco products and technologies. Access to most tools on the Cisco Support and Documentation website requires a Cisco.com user ID and password.

    http://www.cisco.com/cisco/web/support/index.html

    Feature Information for Flexible NetFlow

    The following table provides release information about the feature or features described in this module. This table lists only the software release that introduced support for a given feature in a given software release train. Unless noted otherwise, subsequent releases of that software release train also support that feature.

    Use Cisco Feature Navigator to find information about platform support and Cisco software image support. To access Cisco Feature Navigator, go to www.cisco.com/go/cfn. An account on Cisco.com is not required.
    Table 19. Feature Information for Flexible NetFlow

    Feature Name

    Releases

    Feature Information

    Flexible NetFlow

    12.2(33)SRC

    12.2(50)SY

    12.4(9)T

    15.0(1)SY

    15.0(1)SY1

    Cisco IOS XE Release 3.1S

    Flexible NetFlow is introduced.

    Support for this feature was added for Cisco 7200 series routers in Cisco IOS Release 12.2(33)SRC.

    The following commands were introduced or modified: cache (Flexible NetFlow), clear flow exporter , clear flow monitor , clear sampler , collect counter , collect flow , collect interface , collect ipv4 , collect ipv4 destination , collect ipv4 fragmentation , collect ipv4 section , collect ipv4 source , collect ipv4 total-length , collect ipv4 ttl , collect routing , collect timestamp sys-uptime , collect transport , collect transport icmp ipv4 , collect transport tcp , collect transport udp , debug flow exporter , debug flow monitor , debug flow record , debug sampler , description (Flexible NetFlow), destination , dscp (Flexible NetFlow), exporter , flow exporter , flow monitor , flow platform , flow record , ip flow monitor , match flow , match interface (Flexible NetFlow), match ipv4 , match ipv4 destination , match ipv4 fragmentation , match ipv4 section , match ipv4 source , match ipv4 total-length , match ipv4 ttl , match routing , match transport , match transport icmp ipv4 , match transport tcp , match transport udp , mode (Flexible NetFlow), option (Flexible NetFlow), record , sampler , show flow exporter , show flow interface , show flow monitor , show flow record , show sampler , source (Flexible NetFlow), statistics packet , template data timeout , transport (Flexible NetFlow).