enable

Syntax

enable

Description

Enables the mirroring session specified by the current command context.

By default, mirroring sessions are disabled.

Command context

config-mirror-n

(n is the mirroring session ID.)

Authority

Administrators

Usage

Enables the mirroring session specified by the current command context.

By default, mirroring sessions are disabled.

When a mirroring session is enabled, the show mirror command for that session ID shows an Admin Status of enable and an Operation Status of enabled.

If sFlow is enabled on a port and a mirroring session specifies the same port as a source of received traffic (the source is configured with a direction of rx or both):

  • The attempt to enable the mirroring session fails and an error is returned.

  • To enable the mirroring session, first you must disable sFlow on that port.

NOTE:

When adding, removing, or changing the configuration of a source port in an enabled mirroring session, packets from other mirror sources using the same destination port might be interrupted.

Example

Configuring and enabling a mirroring session:

switch(config)# mirror session 3
switch(config-mirror-3)# source interface 1/1/2 rx
switch(config-mirror-3)# destination interface 1/1/3
switch(config-mirror-3)# comment Monitor router port ingress-only traffic
switch(config-mirror-3)# enable