beautypg.com

Remote traffic mirroring configuration example, Network requirements, Configuration procedure – H3C Technologies H3C S7500E Series Switches User Manual

Page 175

background image

10-6

[Sysname] traffic behavior 1

[Sysname-behavior-1] mirror-to interface GigabitEthernet 2/0/2

[Sysname-behavior-1] quit

# Create QoS policy 1 and associate traffic behavior 1 with class 1 in the QoS policy.

[Sysname] qos policy 1

[Sysname-policy-1] classifier 1 behavior 1

[Sysname-policy-1] quit

# Apply QoS policy 1 to the inbound direction of GigabitEthernet 2/0/1.

[Sysname] interface GigabitEthernet 2/0/1

[Sysname-GigabitEthernet2/0/1] qos apply policy 1 inbound

After the configurations, you can monitor all packets from Host A on the data monitoring device.

Remote Traffic Mirroring Configuration Example

Network requirements

As shown in

Figure 10-2

, the customer network is as described below:

z

GigabitEthernet 2/0/2 of Switch A is connected to the 10.1.1.1/24 network segment.

z

GigabitEthernet 2/0/2 of Switch C is connected to the data monitoring device.

z

Switch B connects Switch A and Switch C, as shown in

Figure 10-2

.

Configure remote traffic mirroring to mirror the packets which are from the 10.1.1.1/24 network

segment and received on GigabitEthernet 2/0/2 of Switch A to the data monitoring device.

Figure 10-2 Network diagram for remote traffic mirroring configuration

Configuration procedure

z

Configuration on Switch A

# Configure basic IPv4 ACL 2000 to match packets from the 10.1.1.1/24 network segment.

system-view

[SwitchA] acl number 2000

[SwitchA-acl-basic-2000] rule permit source 10.1.1.1 255.255.255.0

[SwitchA-acl-basic-2000] quit

# Create class 1 and use basic IPv4 ACL 2000 as the match criteria.

[SwitchA] traffic classfier 1

[SwitchA-classifier-1] if-match acl 2000

[SwitchA-classifier-1] quit

# Create behavior 1 and configure the action of mirroring traffic to GigabitEthernet 2/0/1 for the

behavior.

[SwitchA] traffic behavior 1