端口鏡像
端口鏡像
通過(guò)配置鏡像功能,可以將報文復制到特定的目的地進(jìn)行分析,以進(jìn)行網(wǎng)絡(luò )監控和故障定位。
鏡像是指將經(jīng)過(guò)指定端口(源端口或者鏡像端口)的報文復制一份到另一個(gè)指定端口(目的端口或者觀(guān)察端口)。
配置舉例
1、 一對一本地端口鏡像(一個(gè)監控設備監控一個(gè)端口)
observe-port 1 interface GigabitEthernet1/0/2 // 觀(guān)察口#interface GigabitEthernet1/0/1或者GigabitEthernet1/0/10 (上聯(lián)口) //鏡像口 port-mirroring to observe-port 1 inbound/outbound/both
2、多對一端口本地端口鏡像(多個(gè)監控設備同時(shí)監控一個(gè)端口)
方法一:(單個(gè)配置觀(guān)察端口)
observe-port 1 interface GigabitEthernet1/0/2 //觀(guān)察口1
observe-port 2 interface GigabitEthernet1/0/3 //觀(guān)察口2
observe-port 3 interface GigabitEthernet1/0/4 //觀(guān)察口3
#
interface GigabitEthernet1/0/1 或者 GigabitEthernet1/0/10 (上聯(lián)口 ) //鏡像口
port-mirroring to observe-port 1 inbound/outbound/both
port-mirroring to observe-port 2 inbound/outbound/both
port-mirroring to observe-port 3 inbound/outbound/both
方法二:(批量配置觀(guān)察端口)
observe-port 1 interface-range GigabitEthernet1/0/2 to GigabitEthernet1/0/4 //端口2到4為觀(guān)察口
#
interface GigabitEthernet1/0/1或者 GigabitEthernet1/0/10 (上聯(lián)口) //鏡像口
port-mirroring to observe-port 1 inbound/outbound/both
3、一對多端口鏡像配置(一個(gè)監控設備監控多個(gè)端口)
observe-port 1 interface GigabitEthernet1/0/4 //觀(guān)察口
#
interface GigabitEthernet1/0/1 //鏡像口1
port-mirroring to observe-port 1 inbound/outbound/both
#
interface GigabitEthernet1/0/2 //鏡像口2
port-mirroring to observe-port 1 inbound/outbound/both
#
interface GigabitEthernet1/0/3 //鏡像口3
port-mirroring to observe-port 1 inbound/outbound/both
#
注:inbound、outbound可綁定的端口數量要根據設備、或者板卡的型號而定
鏈接:http://blog.sina.com.cn/s/blog_6c11e33f0102vx2j.html