Snmp-Agent Group - H3C S5830V2 Series Command Reference Manual

Network management and monitoring
Hide thumbs Also See for S5830V2 Series:
Table of Contents

Advertisement

mib-view view-name: Specifies the MIB view available for the community. The view-name argument
represents a MIB view name, a string of 1 to 32 characters. A MIB view represents a set of accessible
MIB objects. If no MIB view is specified, the specified community can access the MIB objects in the
default MIB view ViewDefault.
Usage guidelines
This command is for SNMPv1 and SNMPv2c.
You can create up to 10 SNMP communities by using the snmp-agent community command. To create
more SNMP communities, use the snmp-agent usm-user { v1 | v2c } command.
An SNMPv1 or SNMPv2c community comprises a set of NMSs and SNMP agents, and is identified by
a community name. An NMS and an SNMP agent must use the same community name to authenticate
to each other.
Typically, public is used as the read-only community name and private is used as the read and write
community name. To improve security, assign your SNMP communities a name other than public and
private.
Examples
# Create the read-only community readaccess so an NMS can use the protocol SNMPv1 or SNMPv2c
and community name readaccess to read the MIB objects in the default view ViewDefault.
<Sysname> system-view
[Sysname] snmp-agent sys-info version v1 v2c
[Sysname] snmp-agent community read readaccess
# Create the read and write community writeaccess so only the NMS at 1.1.1.1 can use the protocol
SNMPv2c and community name writeaccess to read or set the MIB objects in the default view
ViewDefault.
<Sysname> system-view
[Sysname] acl number 2001
[Sysname-acl-basic-2001] rule permit source 1.1.1.1 0.0.0.0
[Sysname-acl-basic-2001] rule deny source any
[Sysname-acl-basic-2001] quit
[Sysname] snmp-agent sys-info version v2c
[Sysname] snmp-agent community write writeaccess acl 2001
# Create the read and write community wr-sys-acc so an NMS can use the protocol SNMPv1 or
SNMPv2c, community name wr-sys-acc to read or set the MIB objects in the system subtree (OID
1.3.6.1.2.1.1).
<Sysname> system-view
[Sysname] snmp-agent sys-info version v1 v2c
[Sysname] undo snmp-agent mib-view ViewDefault
[Sysname] snmp-agent mib-view included test system
[Sysname] snmp-agent community write wr-sys-acc mib-view test
Related commands
display snmp-agent community
snmp-agent mib-view

snmp-agent group

Use the snmp-agent group command to create an SNMP group and specify its access right.
101

Advertisement

Table of Contents
loading

This manual is also suitable for:

S5820v2 series

Table of Contents