9-3Displaying and Maintaining Traffic MirroringTo do… Use the command… RemarksDisplay traffic behaviorconfiguration informationdisplay traffic behavioruser-defined[ behavior-name ]Available in any viewDisplay QoS policyconfiguration informationdisplay qos policyuser-defined [ policy-name[ classifier tcl-name ] ]Available in any viewTraffic Mirroring Configuration ExamplesExample for Mirroring Traffic to an InterfaceNetwork requirementsOn the network as shown in Figure 9-1, Host A (with the IP address 192.168.0.1) and Host B areconnected to GigabitEthernet1/0/1 of the switch; a data monitoring device is connected toGigabitEthernet1/0/2 of the switch.Monitor and analyze packets sent by Host A on the data monitoring device.Figure 9-1 Network diagram for configuring traffic mirroring to a portConfiguration ProcedureConfigure Switch:# Enter system view. system-view# Configure basic IPv4 ACL 2000 to match packets with the source IP address 192.168.0.1.[Sysname] acl number 2000[Sysname-acl-basic-2000] rule permit source 192.168.0.1 0[Sysname-acl-basic-2000] quit# Create class 1 and configure the class to use ACL 2000 for traffic classification.[Sysname] traffic classifier 1[Sysname-classifier-1] if-match acl 2000[Sysname-classifier-1] quit# Create behavior 1 and configure the action of mirroring traffic to GigabitEthernet1/0/2 in the trafficbehavior.