source interface

Syntax

source interface {<PORT-NUM> | <LAG-NAME>} {<Direction>}

no source interface {<PORT-NUM> | <LAG-NAME>} [<Direction>]

Description

Configures the specified interface (either an Ethernet port or a LAG) as a source of traffic to be mirrored.

The no form of this command ceases mirroring traffic from the specified source interface and removes the source interface from the mirroring session configuration.

Command context

config-mirror-n

(n is the mirroring session ID.)

Parameters

<PORT-NUM>

Specifies a physical port on the switch. Some switches (such as the Aruba 8400 Switch Series) use the format member/slot/port (for example, 1/1/1). Other switches use slot/port (for example, 1/1).

<LAG-NAME>

Specifies the identifier for the LAG (link aggregation group).

<Direction>

Selects the direction of traffic to be mirrored from this source interface. There is no default for this parameter. Valid values are the following:

both

Mirror both transmitted and received packets.

rx

Mirror only received packets.

tx

Mirror only transmitted packets.

Authority

Administrators

Usage

This command adds, modifies, or removes the specified interface (either an Ethernet port or a LAG) as a source of traffic to be mirrored.

More than one source interface can be configured in a mirroring session. The direction of traffic must be specified for each interface.

There is no configuration limit on the number of source interfaces in a given mirroring session. However, there is a practical limit to the amount of traffic that a mirror destination can transmit. For example, mirroring session with multiple 10G sources can overwhelm a single 10G destination.

You can configure the same source interface in multiple mirroring sessions, if required.

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.

The no form of this command ceases mirroring traffic from the specified source interface and removes the source interface from the mirroring session configuration.

Examples

Configuring a source interface:

switch(config-mirror-1)# source interface
  LAG-NAME      Enter a LAG name. For example, lag10
  PORT-NUM      Enter a port number

Creating a mirroring session and configuring a source interface to mirror both transmitted and received packets:

switch(config)# mirror session 1
switch(config-mirror-1)# source interface 1/1/1 both

Creating a second mirroring session and configuring two source interfaces. One port mirroring only transmitted packets and the other mirroring both transmitted and received packets:

switch(config)# mirror session 2
switch(config-mirror-2)# source interface 1/1/3 tx
switch(config-mirror-2)# source interface 1/2/1 both

Removing the first source interface:

switch(config-mirror-2)# no source interface 1/2/3

Configuring a source interface to mirror received packets only:

switch(config-mirror-3)# source interface 1/1/2 rx

Configuring a source interface to mirror both transmitted and received packets:

switch(config-mirror-1)# source interface 1/1/1 both

Configuring a LAG as source interface to mirror both transmitted and received packets:

switch(config-mirror-4)# source interface lag1 both

Stopping the mirroring of received packets from a configured source interface:

switch(config-mirror-4)# no source interface lag1 rx