< Home

snmp-agent trap enable feature-name mstp

Function

The snmp-agent trap enable feature-name mstp command enables the trap function for the MSTP module.

The undo snmp-agent trap enable feature-name mstp command disables the trap function for the MSTP module.

By default, the trap function is disabled for the MSTP module.

Format

snmp-agent trap enable feature-name mstp [ trap-name { hwmstpibridgelostrootprimary | hwmstpiedgeportchanged | hwmstpiportbpduguarded | hwmstpiportloopguarded | hwmstpiportrootguarded | hwmstpproloopbackdetected | hwmstpiportstatediscarding | hwmstpiportstateforwarding | hwmstpitcguarded | hwmstpportcountthreshold | hwmstpportcountthresholdresume | hwmstppronewbridgelostrootprimary | hwmstppronewedgeportchanged | hwmstppronewportbpduguarded | hwmstppronewportloopguarded | hwmstppronewportrootguarded | hwmstppronewportstatediscarding | hwmstppronewportstateforwarding | hwmstpprorootchanged | hwmstpprotcguarded | newroot | topologychange | hwmstpprorootlost | hwmstpprorootresume } ]

undo snmp-agent trap enable feature-name mstp [ trap-name { hwmstpibridgelostrootprimary | hwmstpiedgeportchanged | hwmstpiportbpduguarded | hwmstpiportloopguarded | hwmstpiportrootguarded | hwmstpproloopbackdetected | hwmstpiportstatediscarding | hwmstpiportstateforwarding | hwmstpitcguarded | hwmstpportcountthreshold | hwmstpportcountthresholdresume | hwmstppronewbridgelostrootprimary | hwmstppronewedgeportchanged | hwmstppronewportbpduguarded | hwmstppronewportloopguarded | hwmstppronewportrootguarded | hwmstppronewportstatediscarding | hwmstppronewportstateforwarding | hwmstpprorootchanged | hwmstpprotcguarded | newroot | topologychange | hwmstpprorootlost | hwmstpprorootresume } ]

Parameters

Parameter

Description

Value

trap-name

Enables the traps of MSTP events of specified types.

-

hwmstpibridgelostrootprimary

Enables the device to send trap when the current device is no longer the root bridge.

-

hwmstpiedgeportchanged

Enables the device to send trap when the edge port that is not enabled with the BPDU guard function is no longer the edge port after receiving BPDUs.

-

hwmstpiportbpduguarded

Enables the device to send trap when the edge port enabled with the BPDU guard function can receive BPDUs.

-

hwmstpiportloopguarded

Enables the device to send trap when the port enabled with the loop guard function does not receive any BPDU in a specified period.

-

hwmstpiportrootguarded

Enables the device to send trap when the port enabled with the root guard function receives BPDUs with higher priorities.

-

hwmstpiportstatediscarding

Enables the device to send trap when the port status changes to Discarding.

-

hwmstpproloopbackdetected

Enables the device to send trap when port detected loopback, block the port.

-

hwmstpiportstateforwarding

Enables the device to send trap when the port status changes to Forwarding.

-

hwmstpitcguarded

Enables the device to send trap when the number of TC packets received by the instance enabled with the TC guard function exceeds the upper limit.

-

hwmstpportcountthreshold

Enables the device to send trap when the number of STP interfaces that were Up on a device exceeded the upper threshold.

-

hwmstpportcountthresholdresume

Enables the device to send trap when the number of STP interfaces that were Up on a device fell below the lower threshold.

-

hwmstppronewbridgelostrootprimary

Enables the device to send trap when in the MSTP process the device is no longer the root bridge.

-

hwmstppronewedgeportchanged

Enables the device to send trap when in the MSTP process the edge port that is not enabled with the BPDU guard function is no longer the edge port after receiving BPDUs.

-

hwmstppronewportbpduguarded

Enables the device to send trap when in the MSTP process the port enabled with the BPDU guard function can receive BPDUs.

-

hwmstppronewportloopguarded

Enables the device to send trap when in the MSTP process the port enabled with the loop guard function does not receive any BPDU in a specified period.

-

hwmstppronewportrootguarded

Enables the device to send trap when in the MSTP process the port enabled with the root guard function receives BPDUs with higher priorities.

-

hwmstppronewportstatediscarding

Enables the device to send trap when in the MSTP process the port status changes to Discarding.

-

hwmstppronewportstateforwarding

Enables the device to send trap when in the MSTP process the port status changes to Forwarding.

-

hwmstpprorootchanged

Enables the device to send trap when the root bridge changes.

-

hwmstpprotcguarded

Enables the device to send trap when in the MSTP process the number of TC packets received by the instance enabled with the TC guard function exceeds the upper limit.

-

newroot

Enables the device to send trap when the current device is elected as the root bridge.

-

topologychange

Enables the device to send trap when the topology changes.

-

hwmstpprorootlost

Enables the device to send trap when it loses its root bridge role in an MSTP process.

-

hwmstpprorootresume

Enables the device to send trap when it has its root bridge role resumed in an MSTP process.

-

Views

System view

Default Level

2: Configuration level

Usage Guidelines

The MSTP module is not configured with the function of excessive traps. To enable the traps of one or more events, you can specify trap-name.

Example

# Enables the device to send trap when the current device is no longer the root bridge.

<HUAWEI> system-view
[HUAWEI] snmp-agent trap enable feature-name mstp trap-name hwmstpibridgelostrootprimary
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >