32
Port Mirroring, together with a network traffic analyzer, helps to monitor network traffic. Users
can monitor the selected ports (
Source Ports
) for egress and/or ingress packets.
Source Mode:
Ingress : The received packets will be copied to the monitor port.
Egress : The transmitted packets will be copied to the monitor port.
Both
: The received and transmitted packets will be copied to the monitor port.
Note:
1.
The monitor port cannot be a trunk member port.
2.
The monitor port cannot be ingress or egress port.
3.
If the Port Mirror function is enabled, the Monitor-to Port can receive mirrored packets
only.
4.
If a port has been configured as a source port and then user configures the port as a
destination port, the port will be removed from the source ports automatically.
Default Settings
Mirror Configurations:
State : Disable
Monitor port : 1
Ingress port(s) : None
Egress port(s) : None
5.3.2.
CLI Configuration
Node
Command
Description
enable
show mirror
This command displays the current port mirroring
configurations.
configure mirror
(disable|enable)
This command disables / enables the port mirroring on
the switch.
configure mirror destination
port PORT_ID
This command specifies the
monitor port
for the port
mirroring.
configure mirror source ports
PORT_LIST mode
(both|ingress|egress)
This command
adds
a port or a range of ports as the
source ports of the port mirroring.
configure no mirror source ports
PORT_LIST
This command
removes
a port or a range of ports from
the source ports of the port mirroring.
Example:
L2SWITCH#
configure terminal
L2SWITCH(config)#mirror enable
L2SWITCH(config)#mirror destination port 2
L2SWITCH(config)#mirror source ports 3-11 mode both