Configuring First Plugin - New to Nagios
Configuring First Plugin - New to Nagios
I am looking to setup monitoring on my Netapp appliances. I would like to try Check_netapp3.pl located @ https://exchange.nagios.org/directory/P ... p3/details
I have installed the plugin via the web gui and I see the plugin via a SSH connection to the nagios host. I am trying to test the commands but I have no idea how to go about this. Attached is a screen shot of my test. Please help walk me through this.
Thanks.
I have installed the plugin via the web gui and I see the plugin via a SSH connection to the nagios host. I am trying to test the commands but I have no idea how to go about this. Attached is a screen shot of my test. Please help walk me through this.
Thanks.
You do not have the required permissions to view the files attached to this post.
Re: Configuring First Plugin - New to Nagios
To test the command, the first thing you'll need to do is enter the directory of the plugins.
Next, run the appropriate plugin with the '-h' flag - this will typically display a help menu. Please post the output of that help menu here.
If the above command doesn't run properly, you may need to give the file 'execute permissions.'
Once you have returned us the help menu, we'll move forward. Thanks!
Code: Select all
cd /usr/local/nagios/libexecCode: Select all
./check_netapp3.pl -hCode: Select all
chmod +x check_netapp3.pl
./check_netapp3.pl -hRe: Configuring First Plugin - New to Nagios
I ran each line in the order your posted them and I received the error below. The plugin is in libexec, I ran an ls Check_Netapp3.pl is listed.
[@ ~]# cd /usr/local/nagios/libexec
[@libexec]# ./check_netapp3.pl -h
-bash: ./check_netapp3.pl: /usr/local/bin/perl: bad interpreter: No such file or directory
[@libexec]# chmod +x check_netapp3.pl
[@libexec]# ./check_netapp3.pl -h
-bash: ./check_netapp3.pl: /usr/local/bin/perl: bad interpreter: No such file or directory
[@ ~]# cd /usr/local/nagios/libexec
[@libexec]# ./check_netapp3.pl -h
-bash: ./check_netapp3.pl: /usr/local/bin/perl: bad interpreter: No such file or directory
[@libexec]# chmod +x check_netapp3.pl
[@libexec]# ./check_netapp3.pl -h
-bash: ./check_netapp3.pl: /usr/local/bin/perl: bad interpreter: No such file or directory
Re: Configuring First Plugin - New to Nagios
Edit the check_netapp3.pl file and at the top change:
To:
Then it should work.
Code: Select all
#!/usr/local/bin/perlCode: Select all
#!/usr/bin/perlRe: Configuring First Plugin - New to Nagios
Let's give the following a shot.
The script is likely trying to call perl incorrectly, we can call it manually to reprimand that situation. Let me know if the above works for you.
EDIT: ssax's fix should work as well.
Code: Select all
cd /usr/local/nagios/libexec
perl check_netapp3.pl -hEDIT: ssax's fix should work as well.
Re: Configuring First Plugin - New to Nagios
@ ssax - that change did not help, thanks though
@Jolson - "perl check_netapp3.pl -h" successfully brought up the help file. What is the issue?
@Jolson - "perl check_netapp3.pl -h" successfully brought up the help file. What is the issue?
Re: Configuring First Plugin - New to Nagios
What is the output of this command:
Code: Select all
which perlRe: Configuring First Plugin - New to Nagios
Below are the results of "Which Perl"
/usr/bin/perl
Thanks!
/usr/bin/perl
Thanks!
Re: Configuring First Plugin - New to Nagios
Code: Select all
yum install dos2unix -y
dos2unix /usr/local/nagios/libexec/check_netapp3.pl
Former Nagios employee
Re: Configuring First Plugin - New to Nagios
After running that I can successfully execute ./check_netapp3.pl -h