Error when using check_disk on local machine
Posted: Fri Mar 10, 2017 5:15 pm
I've configured Nagios to check the it's local disk space as follows:
define service{
host_name nagios
service_description disk available
check_command check_local_disk!'20%'!10%'!'/'
servicegroups nagiosservices
check_interval 10
check_period 24x7
retry_interval 3
max_check_attempts 3
notification_interval 30
notification_period 24x7
notification_options w,c,u,r
contact_groups admins
}
I receive the error (No output on stdout) stderr: /bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
I have debugging set to all and all that is logged is the same error.
If I run the check from the command line as check_disk -w '20%' -c '10' -p '/' I get the expected response of DISK OK - free space: / 30403 MB (79% inode=99%);| /=7941MB;30676;38335;0;38345
I've set SELinux to permissive, no change. I've created my own command definition to by-pass the default.cfg and got the same error.
Any ideas anyone?
define service{
host_name nagios
service_description disk available
check_command check_local_disk!'20%'!10%'!'/'
servicegroups nagiosservices
check_interval 10
check_period 24x7
retry_interval 3
max_check_attempts 3
notification_interval 30
notification_period 24x7
notification_options w,c,u,r
contact_groups admins
}
I receive the error (No output on stdout) stderr: /bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
I have debugging set to all and all that is logged is the same error.
If I run the check from the command line as check_disk -w '20%' -c '10' -p '/' I get the expected response of DISK OK - free space: / 30403 MB (79% inode=99%);| /=7941MB;30676;38335;0;38345
I've set SELinux to permissive, no change. I've created my own command definition to by-pass the default.cfg and got the same error.
Any ideas anyone?