VRF 入力の IP 認識 NetFlow の設定

VRF 入力の IP 認識 NetFlow の制約事項

  • IP 認識 VRF 入力 NetFlow は、CE に面したインターフェイスとして IPv4、IPv6、および MVPNv4 でサポート

  • レイヤ 3 インターフェイスでのみサポート

  • VRF インターフェイスの入力トラフィックに対してのみサポート

  • MPLS L3 VPN VRF インターフェイスに対してのみサポート

  • MVPNv6 での IP 認識 VRF 入力 NetFlow(CE に面したインターフェイスがサポートされていないため)

  • ポートチャネルではサポートなし(SVI は CE に面したインターフェイス)

  • VRF インターフェイスの出力トラフィックではサポートなし

  • MPLS L2VPN 接続回線インターフェイスではサポートなし

VRF 入力の IP 認識 NetFlow に関する情報

この機能を使用すると、key フィールドまたは non-key フィールドとして Virtual Routing and Forwarding(VRF)ID を収集するフローレコードがある入力フローモニターを適用することで、ルータで着信パケットから VRF ID を収集できます。

表 1. スケール番号

プラットフォーム

SDM テンプレート

最大 IPv4 フロー

最大 IPv6 フロー

9300

アクセス

16 K

8K

9400

Distribution

32K

16 K

9500

アクセス

32K

16 K

9600

コア

32K

32K

VRF 入力の IP 認識 NetFlow の設定方法

ここでは、VRF 入力の IP 認識 NetFlow を設定するための設定手順について説明します。

フロー レコードの作成

フローレコードを作成するには、次の作業を実行します。

ステップ 1

手順

  コマンドまたはアクション 目的
ステップ 1

enable

例:

Device> enable

特権 EXEC モードを有効にします。

  • パスワードを入力します(要求された場合)。

ステップ 2

configure terminal

例:

Device(config)# configure terminal

グローバル コンフィギュレーション モードを開始します。

ステップ 3

flow record flow_record_name

例:

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

フロー レコード コンフィギュレーション モードを開始します。

ステップ 4

description description

例:

Device(config-flow-record)# description flow-record-1

(任意)フロー レコードの説明を作成します。

ステップ 5

match ipv4 version

例:

Device (config-flow-record)# match ipv4 version

IPv4 ヘッダーからの IP バージョンとの一致を指定します。

ステップ 6

match ipv4 {source | destination} address

送信元と宛先の IPv4 アドレスとの一致を指定します。

ステップ 7

match ipv4 protocol

例:

Device (config-flow-record)# match ipv4 protocol

IPv4 プロトコルとの一致を指定します。

ステップ 8

match transport {source-port | destination-port}

送信元ポートまたは宛先ポートをフローレコードの key フィールドとして設定します。

ステップ 9

match ipv4 tos

例:

Device (config-flow-record)# match ipv4 tos

IPv4 ToS をフローレコードの key フィールドとして設定します。

ステップ 10

match ipv4 ttl

例:

Device (config-flow-record)# match ipv4 ttl

IPv4 TTL をフローレコードの key フィールドとして設定します。

ステップ 11

match flow direction

例:

Device (config-flow-record)# match flow direction

フローを識別するフィールドとの一致を指定します。

ステップ 12

collect counter packets long

例:

Device (config-flow-record)# collect flow direction

フローで確認されるパケット数を非キーフィールドとして設定し、フローから合計パケット数を収集します。

ステップ 13

collect counter bytes long

例:

Device (config-flow-record)# collect counter bytes long

フローで確認されるバイト数を非キーフィールドとして設定し、フローから合計バイト数を収集します。

ステップ 14

end

例:


Device(config-flow-record)# end

特権 EXEC モードに戻ります。

ステップ 15

show flow record

例:

Device # show flow record

すべてのフロー レコードに関する情報を表示します。

フロー エクスポータの作成

フロー エクスポータを作成すると、フローのエクスポート パラメータを定義できます。

手順

  コマンドまたはアクション 目的
ステップ 1

enable

例:

Device> enable

特権 EXEC モードを有効にします。

  • パスワードを入力します(要求された場合)。

ステップ 2

configure terminal

例:

Device(config)# configure terminal

グローバル コンフィギュレーション モードを開始します。

ステップ 3

flow exporter flow_exporter_name

例:

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

フロー エクスポータ コンフィギュレーション モードを開始します。

ステップ 4

description description

例:

Device(config-flow-exporter)# description flow-exporter-1

(任意)フロー エクスポータの説明を作成します。

ステップ 5

destination { hostname | ipv4-address | ipv6-address }

例:

Device (config-flow-exporter)# destination 10.10.1.1

エクスポータでデータを送信する宛先システムのホスト名、IPv4 または IPv6 アドレスを指定します。

ステップ 6

source interface-type interface-name

例:

Device (config-flow-exporter)# destination 10.10.1.1

エクスポータで、エクスポートされたデータグラムの送信元 IP アドレスとして IP アドレスを使用するローカルインターフェイスを指定します。

ステップ 7

end

例:


Device(config-flow-record)# end

特権 EXEC モードに戻ります。

ステップ 8

show flow exporter

例:

Device # show flow exporter

すべてのフロー エクスポータに関する情報を表示します。

フロー モニターの作成

フロー モニターを作成して、フロー レコードに関連付けることができます。

手順

  コマンドまたはアクション 目的
ステップ 1

enable

例:

Device> enable

特権 EXEC モードを有効にします。

  • パスワードを入力します(要求された場合)。

ステップ 2

configure terminal

例:

Device(config)# configure terminal

グローバル コンフィギュレーション モードを開始します。

ステップ 3

flow monitor monitor-name

例:

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

フロー モニターを作成し、フロー モニター コンフィギュレーション モードを開始します。

ステップ 4

description description

例:

Device (config-flow-monitor)# description flow-monitor-1

(任意)フロー モニターの説明を作成します。

ステップ 5

record record-name

例:

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

事前に作成されたレコードの名前を指定します。

ステップ 6

exporter exporter-name

例:

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

事前に作成されたエクスポータの名前を指定します。

ステップ 7

cache type normal {timeout | active | inactive} | type normal

(任意)フロー キャッシュ パラメータを設定するように指定します。

ステップ 8

end

例:


Device(config-flow-record)# end

特権 EXEC モードに戻ります。

ステップ 9

show flow monitor

例:

Device # show flow monitor

すべてのフロー モニターに関する情報を表示します。

インターフェイスへのフローモニターの適用

手順

  コマンドまたはアクション 目的
ステップ 1

enable

例:

Device> enable

特権 EXEC モードを有効にします。

  • パスワードを入力します(要求された場合)。

ステップ 2

configure terminal

例:

Device(config)# configure terminal

グローバル コンフィギュレーション モードを開始します。

ステップ 3

interface interface-type interface-name

インターフェイスを指定し、インターフェイス コンフィギュレーション モードを開始します。

ステップ 4

no switchport

例:

Device(config-if)# description no switchport

物理ポートに限り、レイヤ 3 モードを開始します。

ステップ 5

vrf forwarding vrf-name

VRF をレイヤ 3 インターフェイスに対応付けます。

ステップ 6

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

入力パケット用のインターフェイスにフローモニターを関連付けます。

ステップ 7

end

例:


Device(config-flow-record)# end

特権 EXEC モードに戻ります。

ステップ 8

show flow interface

例:

Device# show flow interface

指定されたインターフェイスの NetFlow のステータス(有効または無効)を表示します。

VRF 入力の IP 認識 NetFlow の設定例

show flow interface コマンドは、指定されたインターフェイスの NetFlow に関する情報を表示します。:
Interface TenGigabitEthernet1/0/36 
FNF: 	monitor: v4vrfingress 
	direction: Input 
	traffic(ip): on 
FNF: monitor: v6vrfingress 
	direction: Input 
	traffic(ipv6): on
show flow monitor flow-monitor-name cache コマンドは、フローモニターのキャッシュの内容を表示します。
  Cache type:                               Normal (Platform cache)
  Cache size:                                10000
  Current entries:                             100

  Flows added:                                 100
  Flows aged:                                    0

IPV4 SOURCE ADDRESS:       108.3.20.100
IPV4 DESTINATION ADDRESS:  108.2.20.100
TRNS SOURCE PORT:          0
TRNS DESTINATION PORT:     0
FLOW DIRECTION:            Input
IP VERSION:                4
IP TOS:                    0x20
IP PROTOCOL:               255
IP TTL:                    64
counter bytes long:        2956000
counter packets long:      2000
show flow exporter コマンドは、すべてのフローエクスポータに関する情報を表示します。:
Flow Exporter v4vrfingress:
  Description:              User defined
  Export protocol:          NetFlow Version 9
  Transport Configuration:
    Destination type:       IP
    Destination IP address: 15.15.15.16
    Source IP address:      15.15.15.15
    Source Interface:       TenGigabitEthernet1/0/1
    Transport Protocol:     UDP
    Destination Port:       9995
    Source Port:            52319
    DSCP:                   0x0
    TTL:                    255
    Output Features:        Used
Flow Exporter v6vrfingress:
  Description:              User defined
  Export protocol:          NetFlow Version 9
  Transport Configuration:
    Destination type:       IP
    Destination IP address: 15.15.15.16
    Source IP address:      15.15.15.15
    Source Interface:       TenGigabitEthernet1/0/1
    Transport Protocol:     UDP
    Destination Port:       9995
    Source Port:            50881
    DSCP:                   0x0
    TTL:                    255
    Output Features:        Used
show platform software fed switch active fnf monitors-dump コマンドは、NetFlow モニターダンプを表示します。
FNF Monitors
============
Monitor (0x7f4afc031748):
    profile_id(c461d4fe) ref_ct(1) wdavc_monitor(0) wdavc_monitor_create_requested(False) wdavc_remote_monitoring_remote_caching(0) flags(0x0000) is_wireless(No) is_etta_over_fnf No ettaOrBaseProfile(00000000) etta_refcnt(0)
field(113) size(16) param(0) flags(1) offset(0)
field(114) size(16) param(0) flags(1) offset(16)
field(118) size(2) param(0) flags(1) offset(32)
field(119) size(2) param(0) flags(1) offset(34)
field(156) size(1) param(0) flags(1) offset(36)
field(181) size(8) param(0) flags(0) offset(37)
field(42) size(1) param(0) flags(1) offset(45)
field(46) size(1) param(0) flags(1) offset(46)
field(43) size(1) param(0) flags(1) offset(47)
field(47) size(1) param(0) flags(1) offset(48)
Monitor (0x7f4afc029338):
    profile_id(74c02ab0) ref_ct(1) wdavc_monitor(0) wdavc_monitor_create_requested(False) wdavc_remote_monitoring_remote_caching(0) flags(0x0000) is_wireless(No) is_etta_over_fnf No ettaOrBaseProfile(00000000) etta_refcnt(0)
field(93) size(4) param(0) flags(1) offset(0)
field(94) size(4) param(0) flags(1) offset(4)
field(118) size(2) param(0) flags(1) offset(8)
field(119) size(2) param(0) flags(1) offset(10)
field(156) size(1) param(0) flags(1) offset(12)
field(177) size(8) param(0) flags(0) offset(13)
field(181) size(8) param(0) flags(0) offset(21)
field(42) size(1) param(0) flags(1) offset(29)
field(43) size(1) param(0) flags(1) offset(30)
field(46) size(1) param(0) flags(1) offset(31)
field(47) size(1) param(0) flags(1) offset(32)

VRF 入力の IP 認識 NetFlow の機能履歴

次の表に、このモジュールで説明する機能のリリースおよび関連情報を示します。

これらの機能は、特に明記されていない限り、導入されたリリース以降のすべてのリリースで使用できます。

リリース

機能

機能情報

Cisco IOS XE Gibraltar 16.11.1

VRF 入力の IP 認識 NetFlow

この機能を使用すると、key フィールドまたは non-key フィールドとして Virtual Routing and Forwarding(VRF)ID を収集するフローレコードがある入力フローモニターを適用することで、ルータで着信パケットから VRF ID を収集できます。

Cisco Feature Navigator を使用すると、プラットフォームおよびソフトウェアイメージのサポート情報を検索できます。Cisco Feature Navigator にアクセスするには、https://cfnng.cisco.com/ に進みます。