Content

| 9.1 |  | Monitoring Switched Network Performance with SPAN and VSPAN |
| 9.1.5 |  | Configuring SPAN sessions |

The procedure to create a SPAN session and specify the source, or monitored, port and the destination, or monitoring port is relatively simple.

Initially, clear any previous SPAN session from the active configuration by using the no monitor session session_number command.

Next, define the source port being monitored using the command monitor session session_number source interface interface-id module/interface.

Finally, specify the destination port for the mirrored traffic with the command monitor session session_number destination interface interface-id module/interface [encapsulation {dot1q | isl}].

> Note: ISL cannot be specified on 2950 switches.

This example shows how to set up a SPAN session, session 1, for monitoring source port traffic to a destination port. First, any existing SPAN configuration for session 1 is cleared, and then bi-directional traffic is mirrored from source port 1 to destination port 10.

> Switch(config)#no monitor session 1
> Switch(config)#monitor session 1 source interface fastEthernet0/1
> Switch(config)#monitor session 1 destination interface fastethernet 0/10 encapsulation dot1q
> Switch(config)#end

To remove a source port from a SPAN session:

> no monitor session session_number source interface interface-id global

For example, to remove source port FastEthernet0/1 from SPAN session 1, use the following commands:

> Switch(config)#no monitor session 1 source interface fastethernet 0/1
> Switch(config)#end

To remove a destination port from a SPAN session:

> Switch(config)#no monitor session session_number destination interface interface-id global

For example, the following command removes destination port fastethernet 0/10 from SPAN session 1:

> Switch(config)#no monitor session 1 destination interface fastethernet 0/10
> Switch(config)#end