このドキュメントでは、IP ネットワーク上にミラーリングされたトラフィックを伝送する Nexus 5000 シリーズ スイッチでカプセル化リモート スイッチド ポート アナライザ(ERSPAN)セッションを設定する方法について説明します。これにより、ネットワーク全体にリモート モニタリングが提供されます。
この設定を行う前に、次の要件が満たされていることを確認します。
Nexus 5000 シリーズ スイッチの設定に関する基本的な知識がある。
Nexus 7000 シリーズ スイッチの設定に関する基本的な知識がある
ERSPAN の基本的な知識がある
このドキュメントの情報は、次のソフトウェアとハードウェアのバージョンに基づくものです。
Nexus 5000 スイッチ: Cisco NX-OS ソフトウェア リリース 5.1(3)N1(1) 以降の Cisco Nexus 5010 シリーズ スイッチ
Nexus 7000 スイッチ: Cisco NX-OS ソフトウェア リリース 5.1(3) 以降上での Cisco Nexus 7018 シリーズ スイッチ
本書の情報は、特定のラボ環境にあるデバイスに基づいて作成されたものです。 このドキュメントで使用するすべてのデバイスは、初期(デフォルト)設定の状態から起動しています。 稼働中のネットワークで作業を行う場合、コマンドの影響について十分に理解したうえで作業してください。
ドキュメント表記の詳細は、『シスコ テクニカル ティップスの表記法』を参照してください。
ERSPAN は、ネットワークにおける複数のスイッチのリモート モニタリングを有効にします。
Cisco Nexus 5000 シリーズ スイッチは、ERSPAN 送信元セッションのみをサポートします。 宛先セッションは Nexus 5000 スイッチではサポートされません。 そのためこのドキュメントでは、Nexus 7000スイッチは ERSPAN 宛先セッションとして使用され、Nexus 5000 スイッチからのミラーリングされたトラフィックをモニタします。
ERSPAN は、ERSPAN 送信元セッション、ルーティング可能な ERSPAN 総称ルーティング カプセル化(GRE)カプセル化トラフィック、および ERSPAN 宛先セッションで構成されています。
ERSPAN は、複数のスイッチの送信元ポートからミラーリングされたトラフィックを宛先ポートへ送信します。ここにネットワーク アナライザが接続されています。 トラフィックは送信元のスイッチでカプセル化され、宛先のスイッチに転送されます。ここでパケットがカプセル化解除され、宛先ポートへ送信されます。
複数のスイッチ上で、ERSPAN の送信元セッションと宛先セッションを個別に設定することができます。
ERSPAN 送信元
トラフィックをモニタできるモニタ元インターフェイスのことを ERSPAN ソースと呼びます。
送信元ポートのすべてのパケット、すなわち受信(入力)、送信(出力)、または双方向(両方)を監視できます。
ERSPAN 送信元には、送信元ポート、送信元 VLAN、または送信元 VSAN が含まれています。 VLAN が ERSPAN 送信元として指定されている場合は、VLAN 内でサポートされているすべてのインターフェイスが ERSPAN 送信元になります。
ERSPAN 宛先
宛先ポートは ERSPAN 送信元からコピーされたトラフィックを受信します。
宛先ポートは、SwitchProbe デバイスやその他のリモート モニタリング(RMON)プローブなどのデバイス、あるいはコピーされたパケットを 1 つまたは複数の送信元ポートから受信したり、解析することができるセキュリティ デバイスに接続されたポートです。
宛先ポートはスパニングツリー インスタンスまたはレイヤ 3 プロトコルに参加しません。
この項では、このドキュメントで説明する機能の設定に必要な情報を提供します。
注: このセクションで使用されているコマンドの詳細を調べるには、Command Lookup Tool(登録ユーザ専用)を使用してください。
このドキュメントでは、次のネットワーク構成を使用しています。
このドキュメントでは、次の設定を使用します。
Nexus 5000 スイッチ |
---|
Nexus 5000#configure terminal !--- Configures an ERSPAN source session Nexus 5000(config)#monitor session 3 type erspan-source !--- Configure the sources and traffic direction Nexus 5000(config-erspan-src)#source interface Ethernet1/10 both !--- Configure the destination IP address in the ERSPAN session Nexus 5000(config-erspan-src)#destination ip 10.23.21.8 !--- Configure the ERSPAN ID Nexus 5000(config-erspan-src)#erspan-id 903 !--- Configure the VRF Nexus 5000(config-erspan-src)#vrf default !--- Enable the ERSPAN source session (by default the session is in shutdown state) Nexus 5000(config-erspan-src)#no shut Nexus 5000(config-erspan-src)#exit !--- Configure the ERSPAN global origin IP address Nexus 5000(config)#monitor erspan origin ip-address 10.254.254.30 global !--- Configure the IP address for loopback interface, which is used as source of the ERSPAN traffic Nexus 5000(config)#interface loopback1 Nexus 5000(config-if)#ip address 10.254.254.30/32 Nexus 5000(config-if)#exit Nexus 5000(config)#interface Ethernet1/1 Nexus 5000(config-if)#switchport Nexus 5000(config-if)#switchport mode trunk Nexus 5000(config-if)#no shutdown Nexus 5000(config)#feature interface-vlan Nexus 5000(config)#interface Vlan 12 Nexus 5000(config-if)#ip address 10.23.21.7/29 Nexus 5000(config-if)#no ip redirects Nexus 5000(config-if)#no shutdown Nexus 5000(config-if)#exit !--- Save the configurations in the device. switch(config)#copy running-config startup-config Switch(config)#exit |
Nexus 7000 スイッチ |
---|
Nexus 7000#configure terminal !--- Configures an ERSPAN destination session Nexus 7000(config)#monitor session 4 type erspan-destination !--- Configures the source IP address Nexus 7000(config-erspan-src)#source ip 10.23.21.8 !--- Configures a destination for copied source packets Nexus 7000(config-erspan-src)#destination interface Ethernet1/24 !--- Configure the ERSPAN ID Nexus 7000(config-erspan-src)#erspan-id 903 !--- Configure the VRF Nexus 7000(config-erspan-src)#vrf default !--- Enable the ERSPAN destination session (by default the session is in shutdown state) Nexus 7000(config-erspan-src)#no shutdown Nexus 7000(config-erspan-src)#exit Nexus 7000(config)#interface Ethernet1/24 Nexus 7000(config-if)#switchport monitor Nexus 7000(config-if)#exit Nexus 7000(config)#feature interface-vlan Nexus 7000(config)#interface Vlan 12 Nexus 7000(config-if)#ip address 10.23.21.8/29 Nexus 7000(config-if)#no ip redirects Nexus 7000(config-if)#no shutdown Nexus 7000(config-if)#exit Nexus 7000(config)#interface Ethernet1/1 Nexus 7000(config-if)#switchport Nexus 7000(config-if)#switchport mode trunk Nexus 7000(config-if)#no shutdown Nexus 7000(config-if)#exit !--- Save the configurations in the device. Nexus 7000(config)#copy running-config startup-config Nexus 7000(config)#exit |
ここでは、設定が正常に動作していることを確認します。
Output Interpreter Tool(OIT)(登録ユーザ専用)では、特定の show コマンドがサポートされています。 OIT を使用して、show コマンド出力の解析を表示できます。
Nexus 5000 シリーズ スイッチ:
ERSPAN のセッションの状態を表示するには、show monitor コマンドを使用します。
Nexus 5000# show monitor Session State Reason Description ------- ----------- ---------------------- -------------------------------- 3 up The session is up
ERSPAN セッションの設定を表示するには、show monitor session [session session_number] コマンドを使用します。
Nexus 5000# show monitor session 3 session 3 --------------- type : erspan-source state : up erspan-id : 903 vrf-name : default destination-ip : 10.23.21.8 ip-ttl : 255 ip-dscp : 0 origin-ip : 10.254.254.30 (global) source intf : rx : Eth1/10 tx : Eth1/10 both : Eth1/10 source VLANs : rx :
実行中の ERSPAN 設定を表示するには、show running-config monitor コマンドを使用します。
Nexus 5000# show running-config monitor !Command: show running-config monitor !Time: Thu Apr 19 09:32:27 2012 version 5.1(3)N1(1) monitor session 3 type erspan-source erspan-id 903 vrf default destination ip 10.23.21.8 source interface Ethernet1/10 both no shut monitor erspan origin ip-address 10.254.254.30 global
Nexus 7000 シリーズ スイッチ:
ERSPAN のセッションの状態を表示するには、show monitor コマンドを使用します。
Nexus 7000# show monitor Session State Reason Description ------- ----------- ---------------------- -------------------------------- 4 up The session is up
ERSPAN セッションの設定を表示するには、show monitor session [session session_number] コマンドを使用します。
Nexus 7000# show monitor session 4 session 4 --------------- type : erspan-destination state : up erspan-id : 903 vrf-name : default source-ip : 10.23.21.8 destination ports : Eth1/24 Legend: f = forwarding enabled, l = learning enabled
実行中の ERSPAN 設定を表示するには、show running-config monitor コマンドを使用します。
Nexus 7000# show running-config monitor !Command: show running-config monitor !Time: Thu Apr 19 11:13:28 2012 version 5.1(3) monitor session 4 type erspan-destination erspan-id 903 vrf default source ip 10.23.21.8 destination interface Ethernet1/24 no shut
現在のところ、この設定に関する特定のトラブルシューティング情報はありません。