[Nagiosplug-devel] [ nagiosplug-Patches-995761 ] check_disk to include inode percentage.

SourceForge.net noreply at sourceforge.net
Sun Dec 5 16:24:02 CET 2004


Patches item #995761, was opened at 2004-07-22 10:21
Message generated for change (Settings changed) made by opensides
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397599&aid=995761&group_id=29880

Category: Enhancement
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Jorgen Lundman (lundman)
>Assigned to: Benoit Mortier (opensides)
Summary: check_disk to include inode percentage.

Initial Comment:

Since the 1.4.0alpha1 plugins code in check_disk, which
calls fsusage.c, already retrieves the inode values I
thought to patch it to also print inode percentage free.

Additionally, I changed the static "0" in perfdata to
be inode percent free.

I added -W and -K (sorry, -C was taken) for inode
percent warning and critical levels. Alas, only
percentage implemented as of now. (No integer value
support).

Current output looks like:
# ./check_disk -l -w 10% -c 2% -X tmpfs -W 10% -K 2%
DISK OK - free space: / 31266 MB (93% inode=98%);|
/=31266MB;30168;32850;97;33521

And indeed, brining up the -W warning value triggers a
warning:

# ./check_disk -l -w 10% -c 2% -X tmpfs -W 98% -K 2%
DISK WARNING - free space: / 31266 MB (93% inode=98%);|
/=31266MB;30168;32850;97;33521

Hope it helps more than it annoys. I could also have
patched contrib/check_inodes for Solaris's "df -o i"
call, but since nearly all the work was already done in
check_disk I opted for that approach.

Sincerely,

Lundy



----------------------------------------------------------------------

Comment By: Jorgen Lundman (lundman)
Date: 2004-07-23 05:45

Message:
Logged In: YES 
user_id=286650


Additionally, there is a bug when you use -p, or -x, to list
paths to
include or exclude. The nodes allocated do not get w_df etc
variables
cleared, so when you walk the list, they get assigned to
global w_df
variables, and all tests are out the window. This is a side
effect of
an OS where malloc() returned memory is not zero'd.



----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397599&aid=995761&group_id=29880




More information about the Devel mailing list