1-3Configuring Basic SNMP FunctionsSNMPv3 configuration is quite different from that of SNMPv1 and SNMPv2c. Therefore, theconfiguration of basic SNMP functions is described by SNMP versions, as listed in Table 1-2 and Table1-3.Table 1-2 Configure basic SNMP functions (SNMPv1 and SNMPv2c)Operation Command DescriptionEnter system view system-view —Enable SNMP agent snmp-agentOptionalDisabled by default.You can enable SNMPagent by executing thiscommand or any of thecommands used toconfigure SNMP agent.Set system information, and specifyto enable SNMPv1 or SNMPv2c onthe switchsnmp-agent sys-info{ contact sys-contact |location sys-location |version { { v1 | v2c | v3 }* |all } }RequiredBy default, the contactinformation for systemmaintenance is "R&DHangzhou, H3CTechnology Co., Ltd.", thesystem location is"Hangzhou China", and theSNMP version is SNMPv3.DirectconfigurationSet acommunitynamesnmp-agent community{ read | write }community-name [ aclacl-number | mib-viewview-name ]*Set anSNMPgroupsnmp-agent group { v1 |v2c } group-name [ read-viewread-view ] [ write-viewwrite-view ] [ notify-viewnotify-view ] [ acl acl-number ]Set acommunityname andaccesspermission Indirectconfiguration Add a userto anSNMPgroupsnmp-agent usm-user { v1 |v2c } user-name group-name[ acl acl-number ]Requiredz You can set anSNMPv1/SNMPv2ccommunity namethrough directconfiguration.z Indirect configuration iscompatible withSNMPv3. The addeduser is equal to thecommunity name forSNMPv1 andSNMPv2c.z You can choose eitherof them as needed.Set the maximum size of an SNMPpacket for SNMP agent to receive orsendsnmp-agent packetmax-size byte-countOptional1,500 bytes by default.Set the device engine ID snmp-agent local-engineidengineidOptionalBy default, the deviceengine ID is “enterprisenumber + deviceinformation”.Create/Update the view informationsnmp-agent mib-view{ included | excluded }view-name oid-tree [ maskmask-value ]OptionalBy default, the view nameis “ViewDefault” and OID is1.