|
|
This chapter describes how to configure the Switched Port Analyzer (SPAN) on the Catalyst enterprise LAN switches.
This chapter consists of these sections:
SPAN selects network traffic for analysis by a Catalyst 5000 family Network Analysis Module, a SwitchProbe device, or other RMON probe. SPAN mirrors traffic from one or more source ports (Ethernet, Fast Ethernet, Token Ring, or FDDI) on any VLAN to a destination port for analysis (see Figure 27-1).

In Figure 27-1, all traffic on Ethernet port 5 (the source port) is mirrored to Ethernet port 10. A network analyzer on Ethernet port 10 receives all network traffic from Ethernet port 5 without being physically attached to it.
Follow these guidelines when configuring SPAN:
To configure SPAN, perform this task in privileged mode:
| Task | Command |
|---|---|
Step 1 Configure a SPAN source and a SPAN destination port. | set span {src_mod/src_ports | src_vlan | sc0} dest_mod/dest_port [rx | tx | both] [inpkts {enable | disable}] [learning {enable | disable}] [multicast {enable | disable}] [create] |
Step 2 Verify the SPAN configuration. | show span |
![]() | Caution If the SPAN destination port is connected to another device and reception of incoming packets is enabled (using the inpkts enable keywords), the SPAN destination port receives traffic for whatever VLAN the SPAN destination port belongs to. However, the SPAN destination port does not participate in spanning tree for that VLAN. Therefore, take care to avoid creating network loops with the SPAN destination port. The inpkts keyword is available in supervisor engine software release 4.2 and later. In earlier releases, incoming packets are always received on the SPAN destination port. To avoid creating spanning-tree loops, assign the SPAN destination port to an unused VLAN. |
This example shows how to configure SPAN so that both transmit and receive traffic from port 1/1 (the SPAN source) is mirrored on port 2/1 (the SPAN destination):
Console> (enable) set span 1/1 2/1 Enabled monitoring of Port 1/1 transmit/receive traffic by Port 2/1 Console> (enable) show span Destination : Port 2/1 Admin Source : Port 1/1 Oper Source : Port 1/1 Direction : transmit/receive Incoming Packets: disabled
This example shows how to set VLAN 522 as the SPAN source and port 2/1 as the SPAN destination:
Console> (enable) set span 522 2/1 Enabled monitoring of VLAN 522 transmit/receive traffic by Port 2/1 Console> (enable) show span Destination : Port 2/1 Admin Source : VLAN 522 Oper Source : Port 3/1-2 Direction : transmit/receive Incoming Packets: disabled Console> (enable)
This example shows how to set VLAN 522 as the SPAN source and port 2/12 as the SPAN destination. Only transmit traffic is monitored. Normal incoming packets on the SPAN destination port are allowed.
Console> (enable) set span 522 2/12 tx inpkts enable SPAN destination port incoming packets enabled. Enabled monitoring of VLAN 522 transmit traffic by Port 2/12 Console> (enable) show span Destination : Port 2/12 Admin Source : VLAN 522 Oper Source : Port 2/1-2 Direction : transmit Incoming Packets: enabled Console> (enable)
This example shows how to set multiple SPAN sessions using the following:
Console> (enable) set span 3/1 2/1 Enabled monitoring of port 3/1 transmit/receive traffic by Port 2/1 Console> (enable) set span 3/2 2/2 tx create Enabled monitoring of port 3/2 transmit traffic by Port 2/1 Console> (enable) show span Destination : Port 2/1 Admin Source : port 3/1 Oper Source : Port 3/1 Direction : transmit/receive Incoming Packets: disabled Destination : Port 2/2 Admin Source : port 3/2 Oper Source : Port 3/2 Direction : transmit Incoming Packets: disabled Console> (enable)
To disable SPAN, perform this task in privileged mode:
| Task | Command |
|---|---|
Disable SPAN on the switch. | set span disable [dest_mod/dest_port | all] |
This example shows how to disable SPAN on the switch:
Console> (enable) set span disable 2/1 Disabled monitoring of VLAN 522 transmit traffic by Port 2/1 Console> (enable)
![]()
![]()
![]()
![]()
![]()
![]()
![]()
Posted: Fri Oct 1 13:20:31 PDT 1999
Copyright 1989-1999©Cisco Systems Inc.