Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
I want to know how to exclude a particular drive from the 'CheckDriveSize' command, in this case the Page File drive. The documentation doesn't seem very complete and doesn't have very detailed examples, http://nsclient.org/nscp/wiki/CheckDisk/check_drivesize. While looking around it seems I should either be able to do this using 'filter' or 'matching' flags but I'm not sure exactly how.
Using the command below I can get the it to show only C and D drives but it doesn't seem to work for drive names, and I'm not sure how to turn it around so it excludes a drive.
According to another post, http://www.nsclient.org/nscp/ticket/651, the command below should work. Although it includes a '!', but even when I create an alias it fails.
check_nrpe -H 192.168.1.1 -c alias_test -a ShowAll=long CheckAll MinWarn=20G MinCrit=10G
CRITICAL: Could not get free space for: filter filter reason: 3: The system cannot find the path specified.
The command you show as working correctly, and the nsclient config\nrpe command that are not working, are quite different. You will need to set the filter, filtertype, match, etc to the same values as your working command to get the same results. Try the following instead: Alias
check_nrpe -H 192.168.1.1 -c alias_test -a MinWarn=20G MinCrit=10G
Be sure to restart nsclient windows service after modifying the configs and before running the nrpe command.
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.
check_nrpe -H 192.168.1.1 -c alias_test -a MinWarn=20G MinCrit=10G
CRITICAL: Could not get free space for: $ARG3$ $ARG3$ reason: 3: The system cannot find the path specified.
OH I see, it may take putting it right in front of me some times though. I will have to check into exclusions, I honestly have never done that and do not know if that is a valid option.
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.
Ah, I missed that argument. The problem is that the same drive letter is not used for the 'Page File' drive on every server, hence I would like to do it by name. Say, if it contains 'page' or such.
Is it possible to do this with RegEx somehow as per the link on my first page, using 'matching' or 'filter'?
Yeah I'm not really sure about that. If you knew that the combination of drive letters was always Q: P: and X: then you could do Drive=Q: Drive=P: Drive=X: however you run the chance of one of these drive letters being a data drive.
I did some more reading and it looks like NSClient++ 0.4.2 might be able to do it HOWEVER I would steel clear of 0.4.2 as it has lots of weird things going wrong with it. 0.4.1 works OK but it doesn't include the newer options that 0.4.2 has. I would wait for 0.4.3.
It sounds like you need to sit down and set some standards for the drive letter used for page drives.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Alright, looks like I might have to live with a CRITICAL error on the console for a while, unless I separate this server out of the host group (which I rather not do).
Do you have any documentation showing how this would work in 0.4.2 (or 0.4.3)?
Not really, unless nsclient provides it on their site. We don't actually develop that agent. Box might chime back in with some useful stuff though!
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.