The observe-port command configures local observing ports.
The undo observe-port command deletes local observing ports.
By default, no local observing ports are configured.
Configure a single local observing port
observe-port [ observe-port-index ] interface interface-type interface-number [ untag-packet ]
Configure a local observing port group
observe-port [ observe-port-index ] interface-range { interface-type interface-number [ to interface-type interface-number ] } &<1-n> [ untag-packet ] (Only supported by S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S; n in &<1-n> is 4 on an S5720-EI, S6720-EI, and S6720S-EI and 8 on an S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S.)
observe-port observe-port-index interface-range { add | delete } interface-type interface-number ( Only S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this command.)
undo observe-port observe-port-index
Parameter | Description | Value |
---|---|---|
observe-port-index |
Specifies the index of an observing port. |
The value is an integer. The value ranges from 1 to 8 on the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S, ranges from 1 to 4 on the S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735-S-I, and S5735S-S, and ranges from 1 to 6 on other devices. |
interface-type interface-number |
Specifies the type and number of an interface. |
- |
add |
Adds observing ports to the observing port group. |
- |
delete |
Deletes observing ports from the observing port group. |
- |
untag-packet |
Removes VLAN tags of original traffic. NOTE:
Only the S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this parameter. Each original packet can have at most two VLAN tags removed. |
- |
Usage Scenario
When an observing port is directly connected to a monitoring host, you can run the observe-port command to configure a local observing port. There are two modes for configuring observing ports: configure a single observing port and configure an observing port group. Observing port group is often used in 1:N mirroring to simplify the configuration and save observing port indexes. This is because an observing port group occupies only one observing port index regardless of how many ports are configured in the group.
Precautions
The management interface cannot be configured as an observing port.
# Configure GigabitEthernet0/0/1 as a local observing port.
<HUAWEI> system-view [HUAWEI] observe-port 1 interface gigabitethernet 0/0/1
<HUAWEI> system-view [HUAWEI] observe-port 1 interface-range gigabitethernet 0/0/1 to gigabitethernet 0/0/3