[Nagiosplug-devel] [ nagiosplug-Bugs-1660953 ] check_disk.t - test 36 exiting non ok but should be ok

SourceForge.net noreply at sourceforge.net
Thu Feb 15 22:50:14 CET 2007


Bugs item #1660953, was opened at 2007-02-15 22:50
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1660953&group_id=29880

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: CVS
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Matthias Eble (psychotrahe)
Assigned to: Nobody/Anonymous (nobody)
Summary: check_disk.t - test 36 exiting non ok but should be ok

Initial Comment:
hi all,

I was just setting up a testing environment for the nagios plugins when I noticed a false positive.

check_disk claims / 4641 MB (75% inode=97%); /var 2369 MB (57% inode=93%) which is right.

but test case #36 exits non ok executing

./check_disk -e -W 95% -K 0% -p /var -W 95% -K 95% -p /

not ok 36 - Has ignored / as not a problem
#   Failed test 'Has ignored / as not a problem'
#   at t/check_disk.t line 201.
#                   'DISK WARNING - free space: /var 2485 MB (60% inode=93%);'
#           matches '(?-xism:/)'

imo because /var matches /. Finding / means there's a problem with the test. Everything works fine if / has less free inodes than /var.

changing
unlike( $result->only_output, qr/$more_inode_free/, "Has ignored $more_inode_free as not a problem");
to
unlike( $result->only_output, qr/$more_inode_free\s/, "Has ignored $more_inode_free as not a problem");
 
helps. Maybe there are more expressions like this in check_disk.t. I did no further examinations.

matthias

P.S. The test can't be executed using Reiser filesystems since check_disk can't determine inode usage on reiserfs (at least on my notebook) and exits.

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

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




More information about the Devel mailing list