PDA

View Full Version : Execute Script


Walason
19-09-2005, 21:38
Hi people,
Somebody could me explain as functions scrip in zabbix? it sends email but not execute script.


Thanks
Walason

Nate Bell
20-09-2005, 16:29
I'm sorry, I'm not sure what you are trying so ask, but I think I have an idea. Are you trying to create a custom media script? One that will run when a trigger gets tripped?

If so, take a look here (http://www.zabbix.com/forum/showthread.php?t=580). That will get you set up with a custom media script. Of course, you want to make sure your script can be executed by Zabbix.

Now, to get a trigger to use the script, you have to add the script media to a user's account with the severity set to some level. Then set up a trigger's action to point at that user (or a group that contains that user). Now, when a trigger goes off, and it points at that user, and it is the same severity as the script, then the script will get run by Zabbix.

Note that the subject and body of the message you enter in the trigger's action are passed to the script as parameters. That can be useful for having the script take different actions depending on the message it gets passed.

Hope that helps.

Nate