Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Unable to delete alert from ambari

Highlighted

Unable to delete alert from ambari

Explorer

I was trying to add custom alert in ambari but was getting 500 response code but when I check ambari the alerts are there and running. Now when I try to delete those alerts using

curl -u admin:admin -i -H 'X-Requested-By:ambari' -X DELETE http://test-cluster:8080/api/v1/clusters/Analytics_CP1_Dev_Test/alert_definitions/1233

Response I get is the following:

HTTP/1.1 301 Moved Permanently Location: https://test-cluster:8080/api/v1/clusters/Analytics_CP1_Dev_Test/alert_definitions/1233
Content-Length: 0
Content-Type: text/html; charset=UTF-8

But when I check ambari the alerts are still running. I tried restarting ambari-server but the alerts are still there.

3 REPLIES 3
Highlighted

Re: Unable to delete alert from ambari

Expert Contributor

Can you look at the /var/log/ambari-server/ambari-server.log?

You can search for this in the log:

Deleting alert definition

You can also disable alerts from the UI which is not the same as delete but will achieve the same purpose.

Highlighted

Re: Unable to delete alert from ambari

Expert Contributor

Disable the alert before deleting it.

Re: Unable to delete alert from ambari

Super Collaborator

You're making a requests against a plaintext (http) endpoint and Ambari (or whatever is sitting in front of Ambari) is redirecting you to an SSL endpoint (https). You need to make the request against the correct endpoint, namely:

https://test-cluster:8080/api/v1/clusters/Analytics_CP1_Dev_Test/alert_definitions/1233

Don't have an account?
Coming from Hortonworks? Activate your account here