monitoring-plugins icon indicating copy to clipboard operation
monitoring-plugins copied to clipboard

check_disk: Add more filesystems to ignore by default

Open RincewindsHat opened this issue 2 years ago • 6 comments

Replaces #1749 Fixes #1748

RincewindsHat avatar Feb 03 '23 19:02 RincewindsHat

good catch by the CI pipeline :)

waja avatar Feb 03 '23 20:02 waja

Anyone got an idea why that fails?

RincewindsHat avatar Feb 06 '23 12:02 RincewindsHat

Anyone got an idea why that fails?

Tests and the test setup are absolutely not my expertise, so please excuse if this is completely stupid, but isn't it failing because, by your code change you exclude tmpfs filesystems, but the test pipeline adds tmpfs filesystems to the docker container which is running the tests? At least I think that this could explain, why the test expects two filesystems, but found 0 filesystems in the output:

#   Failed test 'Got two mountpoints in output'
#   at ./t/check_disk.t line 36.
#          got: 0
#     expected: 2

The other check is about the exit code being 3 (Unknown), while 0 (OK) is expected. If both filesystems are excluded, that there is no filesystem to check and the plugin prints: DISK UNKNOWN - No disks were found for provided parameters;|

I believe the test setup could explain these failed tests and that it can be solved by either changing to a different fs type or by modifying the tests.

KriSchu avatar Feb 24 '23 14:02 KriSchu

That sounds like a likely explanation. At this point I see a general problem with those changes here. I am not able to remove stuff from the exclusion list during runtime, so this is equivalent to saying "this plugin ignores those filesystem types ALWAYS" which is going to far IMHO.

RincewindsHat avatar Feb 25 '23 11:02 RincewindsHat

@RincewindsHat so same counts for #1749?

waja avatar Apr 12 '23 07:04 waja

@waja sorry, this went under. Yes, same problem. Question is whether we want to ignore those filesystems ALL THE TIME.

RincewindsHat avatar Feb 23 '24 14:02 RincewindsHat

Hard coding the ignored filesystems is probably a bad idea in general. There I am closing this again until I find a better solution.

RincewindsHat avatar Oct 31 '24 00:10 RincewindsHat