Checking Xenserver Disks and Mount Points

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.
Locked
joe1871
Posts: 28
Joined: Tue Feb 01, 2011 3:36 pm

Checking Xenserver Disks and Mount Points

Post by joe1871 »

Hi,
I recently moved over to a different plugin to check available disk space on Linux boxes via check_by_ssh. I have the check.disk.pl plugin installed on Xenserver machines. They would no longer allow me to run the standard Nagios check_disk plugin. I changed to the perl variant, which works fine with one exception. BTW - these are Citrix Xenserver hypervisor hosts, running v. 6.5 of Xenserevr (current version). I have over 200 servers running some version of Xenserver. As I said I just started to have this issue with the canned "check_disk" plugn when moving to Xenserver 6.5.

Regardless - the issue is the check_disk.pl plugin does not seem to discriminate between the local disks on the server and mount points. We use a lot of different mounts, often to filers or NFS ISO shares in the Xenserver network. Unfortunately the plugin is reporting/alerting on the mounts. This cannot be. The perl plugin does allow me to specifically exclude drives by name, but it would mean some significant scripting to grab mounted drives and differentiate.

Anyone either seen this or have an alternative? There is nothing wrong with the plugin - it is operating correctly. I am just fielding a lot of reports of mount points being too full, when they aren't at all.

Really appreciate the help!

JB
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Checking Xenserver Disks and Mount Points

Post by Box293 »

I assume you are referencing this plugin:
https://exchange.nagios.org/directory/P ... sk/details

The plugin notes are in French however from what I can tell, this is the command that determines the disks in your system:

Line 137:

Code: Select all

my $cmd = "/bin/df -k";
From looking at the help for df:
-l, --local limit listing to local file systems
You should be able to add -l to the command to resolve your issue:

Code: Select all

my $cmd = "/bin/df -k -l";
Let us know if this works for you.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
joe1871
Posts: 28
Joined: Tue Feb 01, 2011 3:36 pm

Re: Checking Xenserver Disks and Mount Points

Post by joe1871 »

Hey Box293,

That is an outstanding idea. I will try this today or tomorrow - first opportunity I get. I very much appreciate the help. I would not have been able to parse that out myself. Nice bi-lingual help! :-)

Thanks - I will let you know if successful soon!

Joe
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Checking Xenserver Disks and Mount Points

Post by hsmith »

joe1871 wrote:Hey Box293,

That is an outstanding idea. I will try this today or tomorrow - first opportunity I get. I very much appreciate the help. I would not have been able to parse that out myself. Nice bi-lingual help! :-)

Thanks - I will let you know if successful soon!

Joe
Thank you. Keep us posted.
Former Nagios Employee.
me.
joe1871
Posts: 28
Joined: Tue Feb 01, 2011 3:36 pm

Re: Checking Xenserver Disks and Mount Points

Post by joe1871 »

Box293

This fix worked like a dream - it is obvious that it would. I am embarrassed that I didn't see this myself, it is so obvious. You are sharp!

Thanks again - I very much appreciate this fix - it has calmed down a significant issue for me - I have hundreds of these host servers, and our system is set up so that most have off server mounts that were choking the plugin. This solved the problem.

Very much appreciated.

Joe
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Checking Xenserver Disks and Mount Points

Post by hsmith »

joe1871 wrote:Box293

This fix worked like a dream - it is obvious that it would. I am embarrassed that I didn't see this myself, it is so obvious. You are sharp!

Thanks again - I very much appreciate this fix - it has calmed down a significant issue for me - I have hundreds of these host servers, and our system is set up so that most have off server mounts that were choking the plugin. This solved the problem.

Very much appreciated.

Joe
I am glad to hear this one is resolved! I am going to go ahead and mark the topic as resolved and close it. Let us know if you need anything else!
Former Nagios Employee.
me.
Locked