Take a look at https://github.com/apache/ambari/blob/trunk/ambari-server/src/main/resources/alerts.json, specifically the ambari_agent_disk_usage definition. It defines 3 custom parameters.
On Sep 16, 2015, at 9:30 AM, Arun Patel <arunp.bigd...@gmail.com<mailto:arunp.bigd...@gmail.com>> wrote: Thanks Jon. Can you please provide an example that creates the definition in alerts.json with the parameter? On Wed, Sep 16, 2015 at 9:00 AM, Jonathan Hurley <jhur...@hortonworks.com<mailto:jhur...@hortonworks.com>> wrote: Hi Arun, The script is still distributed to run on all of the ZK hosts. However, when the data is aggregated from the hosts, new alert instances will not be created per-host. Instead, they will be used to update a single alert instance. The Ambari Web Client does not expose the ability to view or edit custom parameters of alert definitions. For this, you’d need to either create the definition in alerts.json with the parameter or use the alert definition API endpoint to create/update the definition with the custom parameter using a POST or PUT respectively. On Sep 14, 2015, at 4:27 PM, Arun Patel <arunp.bigd...@gmail.com<mailto:arunp.bigd...@gmail.com>> wrote: Have couple of questions on Ambari custom alerts. 1) I developed a python script to check the znodes of zookeeper. I used the option "ignore_host": true and its working fine. Now, in this case, the script will run on which host? any one of the 3 zookeeper hosts? 2) I would like to pass a custom parameter to the script from Ambari Alert page. The user should click edit to change the parameter as needed. How do I provide this option in alerts.json? Regards, Arun