Community Articles
Find and share helpful community-sourced technical articles
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.
Labels (1)
Explorer

This article focuses on setting up a custom ambari alert which monitors Yarn memory utilization by fetching from yarn JMX.

Prerequisites - JSON file,access to node CLI, cluster credentials.

Steps1: Create a alert.json file and save it on any location on node. There are two files attached (with comments and a template).

39439-screen-shot-2017-09-20-at-50510-pm.png

Note: In the line ""Hadoop:service=ResourceManager,name=QueueMetrics,q0=root/AllocatedMB"" I am fetching the AllocatedMB from root queue. Thats visible in RM JMX.

39441-screen-shot-2017-09-20-at-50640-pm.png

Step2: From the same node run this below command.It will create a new alert in ambari.

curl -u user:password -i -H 'X-Requested-By:ambari' -X POST -d @alert.json http://<ambari-server>:8080/api/v1/clusters/<cluster-name>/alert_definitions

39442-screen-shot-2017-09-20-at-50723-pm.png

Step3: Login to ambari and check alert. It will start showing the alert.

Attachments:alertjson.txt alertjson-with-comments.txt

1,183 Views
Don't have an account?
Coming from Hortonworks? Activate your account here
Version history
Revision #:
2 of 2
Last update:
‎08-17-2019 11:06 AM
Updated by:
 
Contributors
Top Kudoed Authors