Monitor QNAP disk space in Nagios
-
- Posts: 196
- Joined: Mon May 27, 2013 3:16 pm
Monitor QNAP disk space in Nagios
Hello,
I have gone through below link to monitor QNAP disk space in Nagios.
http://exchange.nagios.org/directory/Pl ... mp/details
I want to know that, how to find out “Index for OID (dskPercent)”?
Thanks,
Imran Khan.
I have gone through below link to monitor QNAP disk space in Nagios.
http://exchange.nagios.org/directory/Pl ... mp/details
I want to know that, how to find out “Index for OID (dskPercent)”?
Thanks,
Imran Khan.
-
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Monitor QNAP disk space in Nagios
Have you tried just specifying an int there? Like the example shows you? Such as:
Code: Select all
-i 1
-
- Posts: 196
- Joined: Mon May 27, 2013 3:16 pm
Re: Monitor QNAP disk space in Nagios
Hello,
Tried 1,2,3 etc and getting same error.
[root@localhost libexec]# ./check_disk.sh -H qnap_ip -C community_name -i 1 -w 0:90 -c 0:95 -l "/dev/md0"
Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskUsed.1
Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskTotal.1
(standard_in) 2: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
DISK UNKNOWN - External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskPercent.1
Thanks,
Imran Khan
Tried 1,2,3 etc and getting same error.
[root@localhost libexec]# ./check_disk.sh -H qnap_ip -C community_name -i 1 -w 0:90 -c 0:95 -l "/dev/md0"
Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskUsed.1
Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskTotal.1
(standard_in) 2: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
./check_disk.sh: line 50: [: -lt: unary operator expected
(standard_in) 1: syntax error
DISK UNKNOWN - External command error: Error in packet
Reason: (noSuchName) There is no such variable name in this MIB.
Failed object: UCD-SNMP-MIB::dskPercent.1
Thanks,
Imran Khan
-
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: Monitor QNAP disk space in Nagios
You may want to take a look at trying something similar to this:
http://www.linuxforums.org/forum/gentoo ... -snmp.html
You could also run a check_snmp against that OID, on the remote system and get the int's returned, If you're still having issues with that plugin I'd recommend trying to contact the plugin developer who's information is in the plugin script.
http://www.linuxforums.org/forum/gentoo ... -snmp.html
You could also run a check_snmp against that OID, on the remote system and get the int's returned, If you're still having issues with that plugin I'd recommend trying to contact the plugin developer who's information is in the plugin script.
-
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Monitor QNAP disk space in Nagios
Considering it is looking for an snmp oid offset, let's do an snmpwalk and see what you have available.
Code: Select all
snmpwalk -v 2c -c community_name qnap_ip UCD-SNMP-MIB::dskTotal
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
-
- Posts: 196
- Joined: Mon May 27, 2013 3:16 pm
Re: Monitor QNAP disk space in Nagios
Hello,
Ran the mentioned command, getting below error.
[root@localhost libexec]# snmpwalk -v 2c -c community qnap_ip UCD-SNMP-MIB::dskTotal
UCD-SNMP-MIB::dskTotal = No Such Object available on this agent at this OID
Thanks,
Imran Khan.
Ran the mentioned command, getting below error.
[root@localhost libexec]# snmpwalk -v 2c -c community qnap_ip UCD-SNMP-MIB::dskTotal
UCD-SNMP-MIB::dskTotal = No Such Object available on this agent at this OID
Thanks,
Imran Khan.
-
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Monitor QNAP disk space in Nagios
Looks like your device does not support this oid. You could either remove this section of the code from the plugin, if you do not need it, such as if the output you referenced earlier was all you were looking for, or you could find a different plugin that does not use that particular oid and not have to modify the plugin.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
-
- Posts: 196
- Joined: Mon May 27, 2013 3:16 pm
Re: Monitor QNAP disk space in Nagios
Hello,
Thanks for the reply.
Is there any best plugin to monitor QNAP space in nagios? I tried 2-3 plugins and did not work.
Thanks,
Imran Khan.
Thanks for the reply.
Is there any best plugin to monitor QNAP space in nagios? I tried 2-3 plugins and did not work.
Thanks,
Imran Khan.
-
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Monitor QNAP disk space in Nagios
We do not have a suggested plugin, this is not a device we see too often. What have you tried for plugins, and what responses did the give? Have you checked with qnap about specific oids you might monitor for best results?
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
-
- Posts: 196
- Joined: Mon May 27, 2013 3:16 pm
Re: Monitor QNAP disk space in Nagios
Hello,
I am trying check_qnap_volumes but getting below error.
http://exchange.nagios.org/directory/Pl ... us/details
[root@localhost libexec]# ./check_qnap_volumes --help
Can't locate SNMP.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at ./check_qnap_volumes line 29.
BEGIN failed--compilation aborted at ./check_qnap_volumes line 29.
SNMP perl mouldue is already installed in the system. Please suggest me on the same.
Hello,
Trying to install perl-Net-SNMP RPM but this is not available.
[root@localhost ~]# yum install perl-Net-SNMP
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.solarvps.com
* extras: centos.mirror.nac.net
* updates: mirror.metrocast.net
Setting up Install Process
No package perl-Net-SNMP available.
Error: Nothing to do
Thanks,
Imran Khan.
I am trying check_qnap_volumes but getting below error.
http://exchange.nagios.org/directory/Pl ... us/details
[root@localhost libexec]# ./check_qnap_volumes --help
Can't locate SNMP.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at ./check_qnap_volumes line 29.
BEGIN failed--compilation aborted at ./check_qnap_volumes line 29.
SNMP perl mouldue is already installed in the system. Please suggest me on the same.
Hello,
Trying to install perl-Net-SNMP RPM but this is not available.
[root@localhost ~]# yum install perl-Net-SNMP
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.solarvps.com
* extras: centos.mirror.nac.net
* updates: mirror.metrocast.net
Setting up Install Process
No package perl-Net-SNMP available.
Error: Nothing to do
Thanks,
Imran Khan.
Last edited by imran_khan on Wed Oct 01, 2014 6:00 pm, edited 1 time in total.