Re: snmptrap on Nagios 5.7.3
Posted: Tue Sep 29, 2020 2:44 pm
Had a secondary ticket opened with support and we stepped through the following, which resolved the issue.
Remove the files from the /var/spool/snmptt
Then to be sure, run the following as root to make sure the permissions are all set correctly.
chown snmptt:nagios /etc/snmp/nagios-check-storage
chown root:nagios /etc/snmp/snmptt.conf /etc/snmp/snmptt.conf.nxti /etc/snmp /usr/local/bin/addmib
chown nagios:nagios /usr/local/nagiosxi/var/NXTI_Write_Test /etc/snmp/snmptt.ini
chown -R snmptt:snmptt /var/spool/snmptt /var/log/snmptt
chmod 0664 /etc/snmp/nagios-check-storage
chmod 664 /etc/snmp/snmptt_nxti.bak
chmod 664 /etc/snmp/snmptt.conf.nxti
chmod 666 /usr/local/nagiosxi/var/NXTI_Write_Test
chmod 664 /etc/snmp/snmptt.conf
chmod -R g+w /etc/snmp
chmod g+x /usr/local/bin/addmib
chmod -R ug+w /var/spool/snmptt /var/log/snmptt
chmod g-w /var/log/snmptt
chmod g+w /var/lib/net-snmp -R
Restart the snmptrapd and the snmptt daemons so they can access the files.
service snmptrapd restart
service snmptt restart
Remove the files from the /var/spool/snmptt
Then to be sure, run the following as root to make sure the permissions are all set correctly.
chown snmptt:nagios /etc/snmp/nagios-check-storage
chown root:nagios /etc/snmp/snmptt.conf /etc/snmp/snmptt.conf.nxti /etc/snmp /usr/local/bin/addmib
chown nagios:nagios /usr/local/nagiosxi/var/NXTI_Write_Test /etc/snmp/snmptt.ini
chown -R snmptt:snmptt /var/spool/snmptt /var/log/snmptt
chmod 0664 /etc/snmp/nagios-check-storage
chmod 664 /etc/snmp/snmptt_nxti.bak
chmod 664 /etc/snmp/snmptt.conf.nxti
chmod 666 /usr/local/nagiosxi/var/NXTI_Write_Test
chmod 664 /etc/snmp/snmptt.conf
chmod -R g+w /etc/snmp
chmod g+x /usr/local/bin/addmib
chmod -R ug+w /var/spool/snmptt /var/log/snmptt
chmod g-w /var/log/snmptt
chmod g+w /var/lib/net-snmp -R
Restart the snmptrapd and the snmptt daemons so they can access the files.
service snmptrapd restart
service snmptt restart