check_disk and autofs
Alan McKay
alan.mckay at gmail.com
Wed Nov 12 21:26:57 CET 2008
OK, I checked the perms and they seem fine.
[nagios at host nagios]$ ls -ald /opt/corp/projects/BCM_CC
drwxrwxrwx 8 otheruser othergroup 1024 2008-10-31 13:52
/opt/corp/projects/BCM_CC
Note that "otheruser" is not nagios. othergroup is one that nagios is
not a member of.
[nagios at host nagios]$ ls -ald /opt/corp/projects
drwxr-xr-x 3 root root 0 2008-11-12 15:22 /opt/corp/projects
Aha, but maybe this is it! Above was with the automounter running. I
turned it off and checked again :
[root at bcmdhcp148 linux]# ls -ald /opt/corp/projects/
drwxr-x--- 2 root root 4096 2008-07-14 04:28 /opt/corp/projects/
So I chmodded it 0755 then turned it back on.
[nagios at bcmdhcp148 nagios]$ ls -ald /opt/corp
drwxr-xr-x 4 root root 4096 2008-07-14 04:28 /opt/corp
[nagios at bcmdhcp148 nagios]$ ls -ald /opt
drwxr-xr-x 4 root root 4096 2008-07-14 04:28 /opt
Here is what I am doing on the Nagios server itself. Note that
"check_nfs_disk" is the same as "check_local_disk" in the default
config. I just copied it in case I needed to change anything.
define service{
use local-service ; Name
of service template to use
host_name localhost
service_description BCM CC Disk
service_groups Disks
contact_groups admins,LoadBuildAdmins
check_command
check_nfs_disk!20%!10%!/opt/corp/projects/BCM_CC/
}
define command{
command_name check_nfs_disk
command_line $USER1$/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
}
--
"I destroy my enemies when I make them my friends"
- Abraham Lincoln
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Nagios-users mailing list
Nagios-users at 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
More information about the Users
mailing list