snmp-agent notify-filter-profile

Function

The snmp-agent notify-filter-profile command creates or updates the trap filtering information, supports configuration up to 20.

The undo snmp-agent notify-filter-profile command deletes the created or updated trap filtering information.

By default, no trap messages are filtered.

Format

snmp-agent notify-filter-profile type profile-name oid-tree

undo snmp-agent notify-filter-profile [ type ] profile-name [ oid-tree ]

Parameters

Parameter Description Value
type

Specifies the filter type.

  • excluded: Excludes the MIB subtree.
  • included: Includes the MIB subtree.
profile-name

Specifies a profile name.

The value is a string of 1 to 32 characters, spaces not supported.

When quotation marks are used around the string, spaces are allowed in the string.

oid-tree

Specifies the object subtree name, that is, the OID value of a MIB object.

The value is a string of 1 to 255 numeric characters, in dotted decimal notation.

Views

System view

Default Level

3: Management level

Task Name and Operations

Task Name Operations
snmp write

Usage Guidelines

Usage Scenario

To filter trap messages sent to a target host, run the snmp-agent notify-filter-profile command to add the MIB objects to be filtered to a filter profile to limit the number of MIB objects that can send trap messages to the NMS. After the filter profile is configured using the snmp-agent notify-filter-profile command, only the trap messages generated by eligible MIB objects are sent to the NMS.

Precautions

If notify-filter-profile is not configured, all trap messages are sent to the target host.

The

snmp-agent notify-filter-profile command supports either the variable OID of a character string or an object name. For a character string, an asterisk (*) can be used as the mask.

The asterisk (*) symbol can be placed only in the middle, not at the beginning or end of the string.

In Include filtering mode of an alarm, OIDs of all bound variables in the alarm must be specified in this command. Otherwise, the filtering fails.

In Exclude filtering mode of an alarm, only the OID of the alarm or that of any bound variable needs to be specified in this command.

Example

# Configure a filter profile named tmp.
<HUAWEI> system-view
[~HUAWEI] snmp-agent notify-filter-profile included tmp 1.3.6.1.*.4
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >