Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Support Questions

Find answers, ask questions, and share your expertise
Announcements
Share your experience with Cloudera on G2 and get a $25 Amazon Gift card.
Hi, I'm CLEO! Something exciting is coming to the Community. Stay Tuned!

Is there an API to set Cloudera Manager monitoring thresholds?

avatar
Explorer

I'd like to use API to set CM monitoring thresholds so I can deploy the modified ones on other CMs.  For example, to set 'Cloudera Manager Agent Log Directory Free Space Monitoring Absolute Thresholds' Warning at 5GB and Critical to 2GB instead of using the default values.

 

I am not sure with  API to use by looking at  this webpage: https://archive.cloudera.com/cm6/6.0.0/generic/jar/cm_api/apidocs/index.html

 

Would anyone provide some help?

 

Thanks,


Kevin

1 ACCEPTED SOLUTION

avatar
Super Guru
@Kevin_Z

Try this one:
https://archive.cloudera.com/cm6/6.0.0/generic/jar/cm_api/apidocs/resource_AllHostsResource.html

And the config name is "host_agent_log_directory_free_space_absolute_thresholds", set the value and update it via PUT.

Sample payload like below:

"items" : [ {
"name" : "host_agent_log_directory_free_space_absolute_thresholds",
"value" : "{\"warning\":3221225472,\"critical\":1073741824}",
"sensitive" : false
}]

Hope this can help.

Cheers
Eric

View solution in original post

2 REPLIES 2

avatar
Super Guru
@Kevin_Z

Try this one:
https://archive.cloudera.com/cm6/6.0.0/generic/jar/cm_api/apidocs/resource_AllHostsResource.html

And the config name is "host_agent_log_directory_free_space_absolute_thresholds", set the value and update it via PUT.

Sample payload like below:

"items" : [ {
"name" : "host_agent_log_directory_free_space_absolute_thresholds",
"value" : "{\"warning\":3221225472,\"critical\":1073741824}",
"sensitive" : false
}]

Hope this can help.

Cheers
Eric

avatar
Explorer

 

 

Exactly I wanted!

 

Thank you @EricL