Page 5 of 6
Re: i cant make non-official plugins to work
Posted: Wed Oct 16, 2013 6:41 am
by Sander5
I remember i also tried another check_printer script. exactly the same problem.
I have just used the check_snmp plugin and it works. (sort off)
Re: i cant make non-official plugins to work
Posted: Wed Oct 16, 2013 2:02 pm
by slansing
What are your permissions on check_snmp?
Re: i cant make non-official plugins to work
Posted: Thu Oct 17, 2013 4:56 am
by Sander5
-rwxr-xr-x 1 root wheel 138700 Jun 25 13:06 check_snmp
-rwxr-xr-x 1 root wheel 32647 Sep 26 09:58 check_snmp_printer
I hope i am not asking a very stupid question but i can't edit check_snmp it's unreadable, is this supposed to be like this?
check_snmp_printer is readable in clean text
Re: i cant make non-official plugins to work
Posted: Thu Oct 17, 2013 11:59 am
by sreinhardt
check_snmp is a binary file, and would not be readable via a normal editor. You would actually want to look at the source code it was compiled from. The other is likely a perl or some other script. As for your permissions, they normally should be owned by both the nagios user and group. Do you know if there is a reason this is not the case? You can try:
Code: Select all
chmod nagios:nagios /path/to/plugin
To try and get them running properly. I realize they have everyone read and execute, but that is less than ideal.
Re: i cant make non-official plugins to work
Posted: Thu Oct 31, 2013 2:57 am
by Sander5
Sorry for this late reaction.
Before i did anything (chmod) it reads: -rwxr-xr-x 1 root wheel 32647 Sep 26 09:58 check_snmp_printer
root wheel should be nagios nagios right?
Re: i cant make non-official plugins to work
Posted: Thu Oct 31, 2013 3:35 pm
by lmiltchev
root wheel should be nagios nagios right?
Correct.
Re: i cant make non-official plugins to work
Posted: Wed Nov 06, 2013 8:29 am
by Sander5
I changed it to nagios nagios
Still the plugin may be missing 127 error.
Re: i cant make non-official plugins to work
Posted: Wed Nov 06, 2013 12:15 pm
by abrist
What is the output of:
Code: Select all
grep USER1 /usr/local/nagios/etc/resource.cfg
Re: i cant make non-official plugins to work
Posted: Thu Nov 14, 2013 7:10 am
by Sander5
Code: Select all
# Nagios supports up to 32 $USERx$ macros ($USER1$ through $USER32$)
# Sets $USER1$ to be the path to the plugins
$USER1$=/usr/local/libexec
my resource.cfg is located at
/usr/local/etc/nagios and not
/usr/local/nagios/etc
Is this normal? i have the feeling i did something wrong or i forgot something
Re: i cant make non-official plugins to work
Posted: Thu Nov 14, 2013 11:06 am
by abrist
What is the listing of:
Sander5 wrote:
Is this normal? i have the feeling i did something wrong or i forgot something
How did you install nagios? (source, repo, etc)