Discussion:
[Nagios-users] nrpe check_disk
joe ritter
2005-02-14 14:26:04 UTC
Permalink
Hello,
I am usig nagios with check_nrpe to monitor remote
hosts running the nrpe daemon. I anm having difficulty
with the plugin check_disk. If I run the the command
by hand on the nagios hosts all is well:

/usr/lib/nagios/plugins/check_nrpe -H 192.168.120.11
-c check_disk -a 20% 10% /dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]

If run the command on the remote hosts all look fine
as well:

/usr/lib/nagios/plugins/check_disk -w 20% -c 10%
/dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]


However when the command is run by the nagios daemon
on the moniting host the I recieve the follwoing error
in the web interface:

Warning threshold must be integer or percentage!

Here are the relevant defines I have set up for this
plugin:

nrpe.cfg on remote host:

command[check_disk]=/usr/lib/nagios/plugins/check_disk
-w $ARG1$ -c $ARG2$ -
p $ARG3$

service.cfg on nagios host:

define service{
use generic-service
check_period 24x7
max_check_attempts 15
normal_check_interval 5
retry_check_interval 1
hostgroup_name web_servers
contact_groups devs
service_description partition_usage2
check_command
check_nrpe!check_disk!20%!10%!/

If someone could shed some light on where I am going
wrong I would greatly appreciate. Thanks in advance.

j.









__________________________________
Do you Yahoo!?
The all-new My Yahoo! - What will yours do?
http://my.yahoo.com
Yatindra Ranpura
2005-02-14 15:54:18 UTC
Permalink
Im not sure if I am doing this the correct way, I have pasted the
services.cfg portion below that isnt correct,

# Service definition
define service{
use generic-service
; Name of service template to use
host_name fileServer
service_description DISK
is_volatile 0
check_period 24x7
max_check_attempts 3
normal_check_interval 1
retry_check_interval 1
contact_groups admins
notification_interval 1
notification_period 24x7
notification_options w,u,c,r
check_command check_disk 85%, 95%
}

I would like to monitor all hard drives on a machine called fileServer and
set warning and critical alarms at 85% and 95%,

Thanks in advance,

Yatindra
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 10/02/2005
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 10/02/2005
Gage, Ron
2005-02-14 16:18:20 UTC
Permalink
Yatrindra:

Not sure what version you are running, but this advice is specific for
1.3

The default command name (unless you changed the command name in
checkcommands.cfg) is check_local_disk. The default setup has this
command with 3 parameters, -w, -c and -p. -w is the warning value, -c
is the critical value and -p is path. Thus, to make your command work,
try the following:

check_command check_local_disk!85!95!/usr/disk1

This, of course, presumes that the volume you want to check space on is
mounted as /usr/disk1. Adjust this accordingly...

Ron Gage - IT Support Team (IBM)
Handleman Corp.
Troy, Michigan
(248) 362-4400 x4626
***@handleman.com


-----Original Message-----
From: nagios-users-***@lists.sourceforge.net
[mailto:nagios-users-***@lists.sourceforge.net] On Behalf Of Yatindra
Ranpura
Sent: Monday, February 14, 2005 12:53 PM
To: nagios-***@lists.sourceforge.net
Subject: [Nagios-users] check_disk plugin problem

Im not sure if I am doing this the correct way, I have pasted the
services.cfg portion below that isnt correct,

# Service definition
define service{
use generic-service
; Name of service template to use
host_name fileServer
service_description DISK
is_volatile 0
check_period 24x7
max_check_attempts 3
normal_check_interval 1
retry_check_interval 1
contact_groups admins
notification_interval 1
notification_period 24x7
notification_options w,u,c,r
check_command check_disk 85%, 95%
}

I would like to monitor all hard drives on a machine called fileServer
and
set warning and critical alarms at 85% and 95%,

Thanks in advance,

Yatindra
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 10/02/2005
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 10/02/2005



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Nagios-users mailing list
Nagios-***@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when
reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
Martijn Lievaart
2005-02-14 20:34:11 UTC
Permalink
Post by joe ritter
Hello,
I am usig nagios with check_nrpe to monitor remote
hosts running the nrpe daemon. I anm having difficulty
with the plugin check_disk. If I run the the command
/usr/lib/nagios/plugins/check_nrpe -H 192.168.120.11
-c check_disk -a 20% 10% /dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]
If run the command on the remote hosts all look fine
/usr/lib/nagios/plugins/check_disk -w 20% -c 10%
/dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]
However when the command is run by the nagios daemon
on the moniting host the I recieve the follwoing error
Warning threshold must be integer or percentage!
Here are the relevant defines I have set up for this
command[check_disk]=/usr/lib/nagios/plugins/check_disk
-w $ARG1$ -c $ARG2$ -
p $ARG3$
You do have nrpe compiled with remote args? Otherwise it will not see
the arguments.

M4
joe ritter
2005-02-18 15:07:29 UTC
Permalink
Yes nrpe does have remote argument functionality
compiled in. The reason I know this and that I beleive
it is built correctly is that on these hosts where the
check_disk plugin does not work, the check_swap plugin
does and displays correctly in the web interface. Does
anyone have any other things that I might check?

Thanks
J.
Post by joe ritter
Post by joe ritter
Hello,
I am usig nagios with check_nrpe to monitor remote
hosts running the nrpe daemon. I anm having
difficulty
Post by joe ritter
with the plugin check_disk. If I run the the
command
Post by joe ritter
/usr/lib/nagios/plugins/check_nrpe -H
192.168.120.11
Post by joe ritter
-c check_disk -a 20% 10% /dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]
If run the command on the remote hosts all look
fine
Post by joe ritter
/usr/lib/nagios/plugins/check_disk -w 20% -c 10%
/dev/cciss/c0d0p1
DISK OK [67334 kB (71%) free on /dev/cciss/c0d0p1]
However when the command is run by the nagios
daemon
Post by joe ritter
on the moniting host the I recieve the follwoing
error
Post by joe ritter
Warning threshold must be integer or percentage!
Here are the relevant defines I have set up for
this
command[check_disk]=/usr/lib/nagios/plugins/check_disk
Post by joe ritter
-w $ARG1$ -c $ARG2$ -
p $ARG3$
You do have nrpe compiled with remote args?
Otherwise it will not see
the arguments.
M4
-------------------------------------------------------
Post by joe ritter
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT
Products from real users.
Discover which products truly live up to the hype.
Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
Post by joe ritter
_______________________________________________
Nagios-users mailing list
https://lists.sourceforge.net/lists/listinfo/nagios-users
Post by joe ritter
::: Please include Nagios version, plugin version
(-v) and OS when reporting any issue.
::: Messages without supporting info will risk being
sent to /dev/null
__________________________________
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail SpamGuard.
http://promotions.yahoo.com/new_mail

Loading...