Comment 23 for bug 1322431

Revision history for this message
Cyrille Bollu (cyrille-bollu) wrote :

Bug still occur here; The createUser line disapear on snmpd restart,a nd isn't replaced with any other usmUser line or alike.

Here's a log of what happens when using the script given in #12

root@otrs-prod:/etc# dpkg -l snmp
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-=====================================================-===============================-===============================-===============================================================================================================
ii snmp 5.7.2~dfsg-8.1ubuntu3.2 amd64 SNMP (Simple Network Management Protocol) applications
root@otrs-prod:/etc# /root/net-snmp-create-v3-user -a xxxxxxxxxx -x xxxxxxxxx -X AES -A SHA opennms
adding the following line to /var/lib/snmp/snmpd.conf:
   createUser opennms SHA "xxxxxxxxxxxx" AES xxxxxxxxxxxxxxx
adding the following line to /etc/snmp/snmpd.conf:
   rwuser opennms
root@otrs-prod:/etc# cat /var/lib/snmp/snmpd.conf
#
# net-snmp (or ucd-snmp) persistent data file.
#
############################################################################
# STOP STOP STOP STOP STOP STOP STOP STOP STOP
#
# **** DO NOT EDIT THIS FILE ****
#
# STOP STOP STOP STOP STOP STOP STOP STOP STOP
############################################################################
#
# DO NOT STORE CONFIGURATION ENTRIES HERE.
# Please save normal configuration tokens for snmpd in SNMPCONFPATH/snmpd.conf.
# Only "createUser" tokens should be placed here by snmpd administrators.
# (Did I mention: do not edit this file?)
#

engineBoots 59
oldEngineID 0x80001f8880f2e5475a8222115100000000
createUser opennms SHA "xxxxxxxxxxxxxxx" AES xxxxxxxxxxxxxxx
root@otrs-prod:/etc# service snmpd start
 * Starting network management services: root@otrs-prod:/etc# cat /var/lib/snmp/snmpd.conf
#
# net-snmp (or ucd-snmp) persistent data file.
#
############################################################################
# STOP STOP STOP STOP STOP STOP STOP STOP STOP
#
# **** DO NOT EDIT THIS FILE ****
#
# STOP STOP STOP STOP STOP STOP STOP STOP STOP
############################################################################
#
# DO NOT STORE CONFIGURATION ENTRIES HERE.
# Please save normal configuration tokens for snmpd in SNMPCONFPATH/snmpd.conf.
# Only "createUser" tokens should be placed here by snmpd administrators.
# (Did I mention: do not edit this file?)
#

engineBoots 60
oldEngineID 0x80001f8880f2e5475a8222115100000000
root@otrs-prod:/etc#