Alerting Rule for Windows Storage Percent

Hi

I’ve tried to setup an alert for Windows devices that have storage space usage over the warning threshold.

I have the following alert but there are a range of servers which are being picked up by the rule which do not have a storage issue. For example I have one server that is only using 24% storage space but is alerting.

macros.device_up = 1 AND devices.os LIKE ‘%Windows%’ AND storage.storage_perc >= “storage.storage_perc_warn”

I have checked my instance is up to date and there are no errors when a validate is run.

Any help would be appreciated.

Kind regards

I am by no means an expert with LibreNMS or Linux…and nobody else replied to you for quite some time so I’ll give it a go.

macros.device_up = 1 AND devices.os LIKE ‘%Windows%’ AND storage.storage_perc >= “storage.storage_perc_warn”

This to me reads that you’re looking for devices are running windows first and then you’re trying to do an variable_x >= variable_y.

Have you tried putting in an actual value for variable_y instead of that reference? It’s sort of a work backwards situation, you’ve got a server that is alerting when it shouldn’t be, why? It’s hitting on an alert, but why?

Thanks. I have done this and it still doesn’t work. I believe it is a bug for that sensor.
Perhaps one for admin review :slightly_smiling_face:

Kind regards

Hi

I’ve done some more testing and with either storage.storage_perc_warn or storage_perc_warn the sensor fires incorrectly, e.g. false positive.
if you set the number manually the rule works ok but means that you can’t have different settings for different devices.

Kind regards