[smokeping-users] Alerts: Edgetrigger not sending a "0" as argument when lowering alert

Stian Øvrevåge sovrevage at gmail.com
Mon May 31 12:27:44 CEST 2010


I have a script that is called by smokeping in the event of an alert.

The script sends an SMS including the details of the alert.

I use both normal persistent alerts and edgetrigger alerts.

When using edgetrigger alerts the value of the 6. argument calling the
script is a "1" indicating a raising of the alarm. In the
documentation it says that when lowering the alert the value is a 0.
This is not the behaviour I'm observing; I'm observing the script
being called with only 5 arguments, and thus causing my script to
treat the alarm as a normal persistent alarm, and not a lowering of an
incident that has been in progress.

The script is now ~15 lines of code and I would really appreciate if I
did not have to add extensive code for detecting whether or not the
alert is an persistent active alert or a lowering of an existing alert

(In the beginning i suspected it was PHP's handling of the arguments
being at fault, but I can call the script from the commandline and it
behaves as intended.)

Cheers & TIA,
Stian Øvrevåge

More information about the smokeping-users mailing list