Programmable Internetworking & Communication Operating System Docs ... Click Spaces -> Space Directory to see docs for all releases ...
Page tree
Skip to end of metadata
Go to start of metadata

 


Configuring SNMPv2 Parameters

By default, SNMP is disabled. You can enable SNMP and configure its parameters (e.g. community, contact, location).

admin@XorPlus# set protocols snmp community Pica8-data-center
admin@XorPlus# set protocols snmp community Pica8-data-center authorization read-only
admin@XorPlus# set protocols snmp contact support@pica8.com
admin@XorPlus# set protocols snmp location Beijing
admin@XorPlus# set protocols snmp trap-group targets 10.10.1.1 security-name Pica8-data-center
admin@XorPlus# set protocols snmp trap-group version v2
admin@XorPlus# commit 
Waiting for merging configuration.
Commit OK.
Save done.
admin@XorPlus#

In version 2.8.1,security-name has to be configured for trap-group targets whichever the version is .

Configuring an SNMP ACL

By default, all hosts can snmpwalk the information of the switch. Configure an SNMP ACL to control which hosts within the subnetwork can snmpwalk the switch.

admin@XorPlus# set system snmp-acl network 1.1.1.0/24
admin@XorPlus# set system snmp-acl network 2.2.2.0/24
admin@XorPlus# commit 
Waiting for merging configuration.
Commit OK.
Save done.
admin@XorPlus#

Configuring SNMPset

User can use "snmpset" (OID1.3.6.1.4.1.35098.2.0.0) to load a configuration and can use "snmpset" (OID 1.3.6.1.4.1.35098.2.1.0) to delete or load a configuration. However, only set and delete commands can be included in the command batch (which is OID 1.3.6.1.4.1.35098.2.1.0). Other commands are invalid and ignored. Note that clearing a dependent configuration is not allowed.

admin@XorPlus# set protocols snmp community private authorization read-write
admin@XorPlus# commit 
Waiting for merging configuration.
Commit OK.
Save done.

Using snmpset to load a filter configuration:

root@dev:~# snmpset -v 2c -c private IP .1.3.6.1.4.1.35098.2.0.0 s "tftp:1.1.5.1:/pica8/acl.conf"
iso.3.6.1.4.1.35098.2.0.0 = STRING: "tftp:1.1.5.1:/pica8/acl.conf"

Using snmpset to delete a filter configuration:

root@dev:~# snmpset -v 2c -c private IP .1.3.6.1.4.1.35098.2.1.0 s "tftp:1.1.5.1:/pica8/delete-acl.conf"
iso.3.6.1.4.1.35098.2.0.0 = STRING: "tftp:1.1.5.1:/pica8/delete-acl.conf"

Enable or Disable LLDP SNMP Trap

The LLDP SNMP trap is enabled by default. You can use the following command to disable LLDP SNMP trap, then there will be no more LLDP trap message sends to snmp.

admin@Xorplus# set protocols lldp snmp-trap false
admin@Xorplus# commit
Waiting for merging configuration.
Commit OK.
Save done.
  • No labels