1-24
Operation
Command
Description
destination port
interface-number
Define the current port as the
destination port
monitor-port
Required
Exit current view
quit
—
Reference ACLs for identifying traffic
flows and perform traffic mirroring for
packets that match.
mirrored-to
vlan
vlan-id
inbound
acl-rule
{
cpu
|
monitor-interface
}
Required
Table 1-29
Configure traffic mirroring for a port
Operation
Command
Description
Enter system view
system-view
—
Enter Ethernet port view of the
destination port
interface
interface-type
interface-number
—
Define the current port as the
destination port
monitor-port
Required
Exit current view
quit
—
Enter Ethernet port view of traffic
mirroring configuration
interface
interface-type
interface-number
—
Reference ACLs for identifying
traffic flows and perform traffic
mirroring for packets that match.
mirrored-to
inbound
acl-rule
{
cpu
|
monitor-interface
}
Required
The traffic mirroring function configured on a VLAN is only applicable to packets tagged with 802.1Q
header.
Configuration example
Network requirements:
z
Ethernet 1/0/1 is connected to the 10.1.1.0/24 network segment.
z
Duplicate the packets from network segment 10.1.1.0/24 to the destination mirroring port Ethernet
1/0/4.
1) Method I: configure traffic mirroring for port Ethernet 1/0/1
<Sysname> system-view
[Sysname] acl number 2000
[Sysname-acl-basic-2000] rule permit source 10.1.1.0 0.0.0.255
[Sysname-acl-basic-2000] quit
[Sysname] interface Ethernet 1/0/4
[Sysname-Ethernet1/0/4] monitor-port
[Sysname-Ethernet1/0/4] quit
[Sysname] interface Ethernet 1/0/1