Page 2 of 3

Re: MIBs and Plugins for Hard drive health

Posted: Fri Mar 29, 2013 9:41 am
by lmiltchev
Are you running nagios on CentOS? What is the output of the following command?

Code: Select all

yum reposlist

Re: MIBs and Plugins for Hard drive health

Posted: Mon Apr 01, 2013 8:31 am
by MPIvan
no im running nagios on ubuntu server 12.04 LTS
and for the command is missing option command ... the output was help for yum ...

Re: MIBs and Plugins for Hard drive health

Posted: Mon Apr 01, 2013 11:35 am
by abrist
Try:

Code: Select all

apt-get install libnet-snmp-perl

Re: MIBs and Plugins for Hard drive health

Posted: Wed Apr 03, 2013 2:22 am
by MPIvan
this is the output ...
root@nagios:/usr/local/nagios/etc/objects# apt-get install libnet-snmp-perl
Reading package lists... Done
Building dependency tree
Reading state information... Done
libnet-snmp-perl is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
it is relay annoying showing this errors :)

Re: MIBs and Plugins for Hard drive health

Posted: Wed Apr 03, 2013 11:05 am
by abrist
Well you have the packages, lets check their location so you can add it to your path:

Code: Select all

ls -la /usr/share/perl5/Net/SNMP/*
If those directories are empty, lets find out where it is:

Code: Select all

find / -name SNMP
Once found, add the directory to your path:

Code: Select all

PATH=$PATH:/usr/share/perl5/Net/
export PATH
Now try running the check "check_cpqdisks" from the cli.

Re: MIBs and Plugins for Hard drive health

Posted: Thu Apr 04, 2013 1:18 am
by MPIvan
well this is the output from the ls -la /usr/share/perl5/Net/SNMP*

Code: Select all

root@nagios:~# ls -la /usr/share/perl5/Net/SNMP/*
-rw-r--r-- 1 root root 18397 Sep 10  2010 /usr/share/perl5/Net/SNMP/Dispatcher.pm
-rw-r--r-- 1 root root 51840 Sep 10  2010 /usr/share/perl5/Net/SNMP/Message.pm
-rw-r--r-- 1 root root 13514 Sep 10  2010 /usr/share/perl5/Net/SNMP/MessageProcessing.pm
-rw-r--r-- 1 root root 26880 Sep 10  2010 /usr/share/perl5/Net/SNMP/PDU.pm
-rw-r--r-- 1 root root  5651 Sep 10  2010 /usr/share/perl5/Net/SNMP/Security.pm
-rw-r--r-- 1 root root 22787 Sep 10  2010 /usr/share/perl5/Net/SNMP/Transport.pm

/usr/share/perl5/Net/SNMP/Security:
total 68
drwxr-xr-x 2 root root  4096 Feb 21 12:43 .
drwxr-xr-x 4 root root  4096 Feb 21 12:43 ..
-rw-r--r-- 1 root root  4439 Sep 10  2010 Community.pm
-rw-r--r-- 1 root root 52004 Oct 17  2011 USM.pm

/usr/share/perl5/Net/SNMP/Transport:
total 28
drwxr-xr-x 4 root root 4096 Feb 21 12:43 .
drwxr-xr-x 4 root root 4096 Feb 21 12:43 ..
drwxr-xr-x 2 root root 4096 Feb 21 12:43 IPv4
-rw-r--r-- 1 root root 2315 Sep 10  2010 IPv4.pm
drwxr-xr-x 2 root root 4096 Feb 21 12:43 IPv6
-rw-r--r-- 1 root root 4273 Sep 10  2010 IPv6.pm
root@nagios:~#
here is the other output

Code: Select all

root@nagios:~# find / -name SNMP
/usr/share/perl5/Net/SNMP
/usr/local/share/perl/5.14.2/Net/SNMP
/usr/local/lib/perl/5.14.2/auto/Net/SNMP
/root/.cpan/build/Net-SNMP-v6.0.1-ciBWc0/blib/lib/Net/SNMP
/root/.cpan/build/Net-SNMP-v6.0.1-ciBWc0/lib/Net/SNMP
root@nagios:~#


and when you saying to add the directory in my path

Code: Select all

PATH=$PATH:/usr/share/perl5/Net/
export PATH
where exactly this should i add ?

Re: MIBs and Plugins for Hard drive health

Posted: Thu Apr 04, 2013 10:38 am
by abrist
MPIvan wrote: where exactly this should i add ?
From the cli, as I want to test to see if you are having path problems to the net-snmp files.

Re: MIBs and Plugins for Hard drive health

Posted: Fri Apr 05, 2013 4:31 am
by MPIvan
bead english i have but never mind ... here is the output
root@nagios:~# PATH=$PATH:/usr/share/perl5/Net
root@nagios:~# export PATH
root@nagios:~#
... nothing :)

Re: MIBs and Plugins for Hard drive health

Posted: Fri Apr 05, 2013 9:50 am
by abrist
MPIvan wrote:... nothing

Code: Select all

PATH=$PATH:/usr/share/perl5/Net/
export PATH
echo $PATH
It should get added to your shell $PATH (and does so quietly). Once you run the path commands, try to run the plugin again in the same terminal session as changing $PATH this way is not persistent. I just want to check if you are having path issues.

Re: MIBs and Plugins for Hard drive health

Posted: Mon Apr 08, 2013 8:02 am
by MPIvan
here it is....
root@nagios:~# echo $PATH
/root/perl5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
root@nagios:~# PATH=$PATH:/usr/share/perl5/Net/
root@nagios:~# export PATH
root@nagios:~# echo $PATH
/root/perl5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/share/perl5/Net/
root@nagios:~#