Académique Documents
Professionnel Documents
Culture Documents
Testing Alerts
Published: 01/03/2017
2. Once the software is installed you can then modify the configuration files and configure
this to be enabled during server reboot. Also all traps will be logged to the
/var/log/snmptrap.log for this purpose.
18. Edit the /etc/snmp/snmpd.conf file and make sure the master agentx
19. and trap2sink lines are added:
20.
21. master agentx agentXSocket tcp:localhost:705 udp:161
22. trap2sink localhost:162 public
23. rwuser snmpagent
24.
25. Edit the /etc/snmp/snmptrapd.conf file and make sure the following
26. lines are set
27.
28. authCommunity log,execute,net public
29. logOption f /var/log/snmptrap.log
30. Edit the /etc/init.d/snmpd start file
31.
32. In this file you will need to change the OPTIONS section and update
33. it to look as follows ( should all be on one line):
34.
35. OPTIONS="-LS0-6d -Lf /dev/null -p /var/run/snmpd.pid
--master=agentx --agentXSocket=tcp:localhost:705 udp:161"
1. Enable the Data Store’s SNMP plug-in using the dsconfig tool. Make sure to specify the
address and port of the SNMP master agent. On each Data Store instance, enable the
SNMP subagent. Note that the SNMPv3 context name is limited to 30 bytes maximum. If
the default dynamically-constructed instance name is greater than 30 bytes, there will be
an error when attempting to enable the plugin.
2. $ bin/dsconfig set-plugin-prop --plugin-name "SNMP Subagent" \
3. --set enabled:true --set agentx-address:localhost \
4. --set agentx-port:705 --set session-timeout:5s \
--set connect-retry-max-wait:10s
5. Enable the SNMP Subagent Alert Handler so that the sub-agent will send traps for
administrative alerts generated by the server.
6. $ bin/dsconfig set-alert-handler-prop \
--handler-name "SNMP Subagent Alert Handler" --set enabled:true
7. Install the MIB definitions for the Net-SNMP client tools, usually located in the
/usr/share/snmp/mibs directory.
$ cp resource/mib/* /usr/share/snmp/mibs
8. You should now see a line in the error log of the data store similar to the following:
12. Now you can do some tests to ensure that you can query the Data Store via SNMP
21. You can use the 'snmp walk' command to get the status of the server.
12. You should then see something similar in the /var/log/snmptrap.log file