< Home

snmp-agent target-host inform

Function

The snmp-agent target-host inform command sets the destination IP address of an Inform message.

The undo snmp-agent target-host command deletes the current setting.

Format

snmp-agent target-host inform address udp-domain ip-address [ udp-port port-number | source interface-type interface-number | [ public-net | vpn-instance vpn-instance-name ] ] * params securityname { security-string | cipher security-string } v2c [ notify-filter-profile profile-name | ext-vb ] *

snmp-agent target-host inform address udp-domain ip-address [ udp-port port-number | source interface-type interface-number | [ public-net | vpn-instance vpn-instance-name ] ] * params securityname security-string v3 [ authentication | privacy ] [ notify-filter-profile profile-name | ext-vb ] *

undo snmp-agent target-host inform address udp-domain ip-address [ udp-port port-number | source interface-type interface-number | [ public-net | vpn-instance vpn-instance-name ] ] * params securityname { security-string | cipher security-string }

Parameters

Parameter Description Value
address

Specifies the IP address of the destination host to which SNMP messages are sent. address in conjunction with securityname identifies a host.

-

udp-domain ip-address

Specifies the IP address of the target host with the transmission domain being UDP.

-

udp-port port-number

Specifies the port number for receiving an Inform message.

It is an integer ranging from 0 to 65535. The default value is 162.

source interface-type interface-number

Specifies the source interface for sending an Inform message.

-

vpn-instance vpn-instance-name

Specifies the VPN instance name.

The vpn-instance parameter is optional. If vpn-instance is configured, the VPN instance specified by vpn-instance vpn-instance-name, IP address, and security name specified by securityname security-string form a 3-tuple to identify a host on a VPN.

public-net

Specifies that the host generating a trap message is connected to a public network.

-

params

Specifies the host that generates SNMP messages.

-

securityname security-string

Specifies the user security name displayed on the NMS.

For SNMPv3, securityname must be configured as the user name. securityname configured on the host needs to be the same as that configured on the NMS, or the NMS cannot receive the trap messages sent from the host.

For SNMPv2c, the NMS can receive trap messages from all hosts without having securityname configured. securityname is used to distinguish multiple hosts that generate trap messages.

The value is a string of 1 to 32 simple text characters or 48 or 68 ciphertext characters, spaces not supported. A string of 32 or 56 ciphertext characters are also supported.

NOTE:

The security names must be unique on a device for differentiation.

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

v2c

Specifies the SNMP versions.

They indicate SNMPv2c respectively.

notify-filter-profile profile-name

Specifies the filter profile name.

The name is a string of 1 to 32 characters without spaces.

ext-vb

Indicates that trap messages sent to a target host carry extended bound variables.

If alarm objects defined in public MIBs are extended on a Huawei data communication device, you can use ext-vb to determine whether the corresponding trap messages sent from the device to an NMS carry extended bound variables.
  • If ext-vb is not specified, the trap message does not carry extended bound variables.

    This parameter is not recommended when the NMS is a third-party NMS. This ensures that the third-party NMS can receive trap messages from Huawei data communication devices.

    By default, a trap message sent from a Huawei data communication device does not carry extended bound variables.

  • If ext-vb is specified, the trap message carries extended bound variables.

    This parameter is recommended when the NMS is a Huawei NMS. This allows more abundant information in trap messages.

-

cipher

Specifies the password in ciphertext. The simple password or the ciphertext password can be entered. The password in the configuration file is displayed in ciphertext.

NOTE:
If not specify the keyword, enter the simple password only.

-

v3

Specifies SNMPv3.

-

authentication

Authenticates SNMP packets without encryption.

-

privacy

Authenticates and encrypts SNMP packets.

-

Views

System view

Default Level

3: Management level

Usage Guidelines

Usage Scenario

To help the NMS manage devices efficiently, run the snmp-agent target-host inform command to set the destination IP address of an Inform message and to filter Inform trap messages. SNMPv2c does not authenticate or encrypt packets, but SNMPv3 authenticates and encrypts packets.

Prerequisites

Before filtering Inform traps using the snmp-agent target-host inform command, run the snmp-agent notify-filter-profile command to define notify-filter-profile. The snmp-agent notify-filter-profile command is used to create or update the trap filtering information. The NMS filters trap messages according to the profile and sends only the eligible trap messages to the target host.
If notify-filter-profile is not configured, all trap messages are sent to the target host.

Precautions

To enable the trap function for a device, you need to use the snmp-agent target-host inform command together with the snmp-agent trap enable command.

When setting a target host for traps, its VPN instances must be matched to the VPN instances bound to source interfaces of the host; otherwise, traps may fail to be sent.

The securityname configuration of an SNMPv2c alarm host is displayed in ciphertext, while the securityname configuration of an SNMPv3 alarm host is displayed in simple text.

When SNMPv3 is used to send Inform messages, run the snmp-agent remote-engineidusm-user v3 command to configure a remote SNMPv3 user whose remote engine ID must be the same as the engine ID of the destination host.

For SNMPv2c, when a user with a level lower than the level configured using this command queries the securityname configured using the display this or display current-configuration command, the securityname is displayed as asterisks (******).

Example

# Configure the Inform mode for trap propagation, set the security name of the host to 123 and the SNMP version to v2c, and propagate the traps generated by the BGP module to the destination host 192.168.0.1.
<sysname> system-view
[sysname] snmp-agent trap enable feature-name bgp
[sysname] snmp-agent target-host inform address udp-domain 192.168.0.1 params securityname 123 v2c 
# Configure the filter profile name as abc for filtering the trap messages that are allowed to reach the target host 1.1.1.1.
<sysname> system-view
[sysname] snmp-agent trap enable feature-name bgp
[sysname] snmp-agent target-host inform address udp-domain 1.1.1.1 params securityname 123 v2c notify-filter-profile abc
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >