Netflow
Netflow configuration manages flow-based traffic monitoring on NX-OS devices. Settings include exporters (collector destinations), records (flow matching and collection parameters), monitors (binding records to exporters), hardware profiles (export tuning), and class maps (ACL-based flow classification).
Diagram
Section titled “Diagram”Classes
Section titled “Classes”configuration (nxos.devices)
Section titled “configuration (nxos.devices)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| netflow | Class | [netflow] | No |
netflow (nxos.devices.configuration)
Section titled “netflow (nxos.devices.configuration)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| exporters | List | [exporters] | No | |
| records | List | [records] | No | |
| monitors | List | [monitors] | No | |
| hardware_profiles | List | [hardware_profiles] | No | |
| class_maps | List | [class_maps] | No |
exporters (nxos.devices.configuration.netflow)
Section titled “exporters (nxos.devices.configuration.netflow)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| description | String | No | ||
| destination | IP | No | ||
| dscp | Integer | min: 0, max: 63 | No | |
| source_interface_type | Choice | ethernet, loopback, mgmt, port-channel, vlan, vni | No | |
| source_interface_id | Any | String or Integer[min: 0] | No | |
| transport_udp | Integer | min: 1, max: 65535 | No | |
| version | Choice | v5, v9 | No | |
| vrf | String | No |
records (nxos.devices.configuration.netflow)
Section titled “records (nxos.devices.configuration.netflow)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| description | String | No | ||
| collect_counter_bytes | Boolean | true, false | No | |
| collect_counter_packets | Boolean | true, false | No | |
| collect_timestamp_sys_uptime_first | Boolean | true, false | No | |
| collect_timestamp_sys_uptime_last | Boolean | true, false | No | |
| match_datalink_ethertype | Boolean | true, false | No | |
| match_datalink_mac_destination_address | Boolean | true, false | No | |
| match_datalink_mac_source_address | Boolean | true, false | No | |
| match_datalink_vlan | Boolean | true, false | No | |
| match_ip_protocol | Boolean | true, false | No | |
| match_ip_tos | Boolean | true, false | No | |
| match_ipv4_source_address | Boolean | true, false | No | |
| match_ipv4_destination_address | Boolean | true, false | No | |
| match_ipv6_source_address | Boolean | true, false | No | |
| match_ipv6_destination_address | Boolean | true, false | No | |
| match_transport_source_port | Boolean | true, false | No | |
| match_transport_destination_port | Boolean | true, false | No |
monitors (nxos.devices.configuration.netflow)
Section titled “monitors (nxos.devices.configuration.netflow)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| description | String | No | ||
| record | String | No | ||
| exporter_1 | String | No | ||
| exporter_2 | String | No |
hardware_profiles (nxos.devices.configuration.netflow)
Section titled “hardware_profiles (nxos.devices.configuration.netflow)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| burst_interval_shift | Integer | min: 0, max: 255 | No | |
| export_interval | Integer | min: 0, max: 4294967295 | No | |
| ip_packet_id_shift | Integer | min: 0, max: 255 | No | |
| mtu | Integer | min: 576, max: 9216 | No | |
| source_port | Integer | min: 1, max: 65535 | No |
class_maps (nxos.devices.configuration.netflow)
Section titled “class_maps (nxos.devices.configuration.netflow)”| Name | Type | Constraint | Mandatory | Default Value |
|---|---|---|---|---|
| name | String | Yes | ||
| match_acls | List | String | No |
Examples
Section titled “Examples”Example 1: Basic netflow with exporter, record, and monitor
nxos: devices: - name: LEAF1 configuration: feature: netflow: true netflow: exporters: - name: EXPORTER1 description: Primary collector destination: 10.92.198.100 transport_udp: 2055 source_interface_type: loopback source_interface_id: '0' version: v9 vrf: management records: - name: RECORD1 match_ipv4_source_address: true match_ipv4_destination_address: true collect_counter_bytes: true collect_counter_packets: true monitors: - name: MONITOR1 record: RECORD1 exporter_1: EXPORTER1Example 2: Netflow with dual exporters, hardware profile, and class map
nxos: devices: - name: SPINE1 configuration: feature: netflow: true netflow: exporters: - name: COLLECTOR1 destination: 10.10.10.1 transport_udp: 9995 dscp: 46 version: v9 - name: COLLECTOR2 destination: 10.10.10.2 transport_udp: 9995 version: v9 records: - name: CUSTOM_RECORD match_ipv4_destination_address: true collect_counter_packets: true monitors: - name: FLOW_MON1 description: Primary flow monitor record: CUSTOM_RECORD exporter_1: COLLECTOR1 exporter_2: COLLECTOR2 hardware_profiles: - name: PROFILE1 export_interval: 60 mtu: 1500 source_port: 9999 class_maps: - name: CLASSIFY1 match_acls: - ACL_NETFLOW