Execute Command on Alarm?
Jeremy Kister
argus-02 at jeremykister.com
Sat Apr 26 17:50:58 EDT 2008
On 4/26/2008 5:23 PM, Percy Kwong wrote:
> I'm interested in executing a shell script (of my choosing) when a
> server goes down (via ping testing). Is there a way for me to do this?
i think the easiest is to set up a notify method:
Method "MyMethod" {
command: /home/me/serverdown.sh
qtime: 0
}
and then in your notify: add MyScript
notify: mail:2135552323 at example.com MyMethod:foo
or, if you just want to execute the script for certain objects:
Group "somegroup" {
Group "special stuff" {
notifyalso: MyMethod:foo
}
}
* where foo is some optional parameter you might want your script to get
--
Jeremy Kister
http://jeremy.kister.net./
More information about the Arguslist
mailing list