I am trying to exec command to perform checks through snmp.
I am on Debian 6.0
Here is my snmpd.conf file
rwcommunity public 172.23.129.0/29 syslocation "Blah syscontact firstname.lastname@example.org sysname belleville.domain.net sysdescr "Syslog Domain Server" disk / load 5 10 10 #exec 184.108.40.206.4.1.2021.8 /usr/bin/python /usr/local/domain/tools/check-syslog.py exec 220.127.116.11.4.1.2021.8 /usr/bin/python /tmp/check-syslog.py
Here is the output of snmpget:
snmpget -Of -cpublic -v1 belleville 18.104.22.168.4.1.2021.8.1.101.1 .iso.22.214.171.124.1.2021.8.1.101.1 = STRING: "/usr/bin/python: can't open file '/tmp/check-syslog.py': [Errno 13] Permission denied"
I don't understand the permission issue, as the rights on the file are 711 and owner root:root, located in /tmp folder. Anyway, this script is executed by root user, isn't it? So 700 should be enough anyway? This makes me think that this does not look like a permission trouble, even with this error message.
I hope someone has ever met this issue, and would be able to give me some advice :/
Thanks a lot for any piece of advice :)