例1:针对vlan流量进行监控
sw-1#show monitor 检查是否已存在镜像的配置
sw-1#conf t 进入全局模式
sw-1<config>#monitor session1sourcevlan 3 - 10rx    -----------监控vlan 3 -10
sw-1<config>#monitor session1destinationint f0/24    -----------把信息复制到f0/24       
sw-1<config>#end 返回
sw-1#show monitor
注意: 如果F0/24所接电脑属VLAN 3且需要远程,可以用monitor session1destinationint f0/24 ingress vlan 3
 
 
例2 :监控某一指定的端口
sw-1#show monitor 检查是否已存在镜像的配置
sw-1#conf t 进入全局模式
sw-1<config>#monitor session2sourceint f0/12rx 监控端口f0/12
sw-1<config>#monitor session2destinationint f0/24把信息复制到f0/24
sw-1<config>#end 返回
sw-1#show monitor session2
经过以上配置后,就可以用sinffer进行抓包了!