{"id":4911,"date":"2015-09-02T08:09:59","date_gmt":"2015-09-02T13:09:59","guid":{"rendered":"http:\/\/appcrawler.com\/wordpress\/?p=4911"},"modified":"2015-09-02T08:09:59","modified_gmt":"2015-09-02T13:09:59","slug":"deleting-a-service-in-ambari","status":"publish","type":"post","link":"http:\/\/appcrawler.com\/wordpress\/2015\/09\/02\/deleting-a-service-in-ambari\/","title":{"rendered":"Deleting a service in ambari"},"content":{"rendered":"<p>Just a simple method to delete a service in Ambari using the REST API&#8230;<\/p>\n<pre>\r\n[root@ambari2012 ~]# curl -u admin:admin -H \"X-Requested-By: ambari\" -X DELETE http:\/\/192.168.56.121:8080\/api\/v1\/clusters\/ambari2012\/services\/RANGER\r\n[root@ambari2012 ~]# curl -u admin:admin -H \"X-Requested-By: ambari\" -X DELETE http:\/\/192.168.56.121:8080\/api\/v1\/clusters\/ambari2012\/services\/RANGER\r\n{\r\n\u00a0 \"status\" : 404,\r\n\u00a0 \"message\" : \"org.apache.ambari.server.controller.spi.NoSuchResourceException: The specified resource doesn't exist: Service not found, clusterName=ambari2012, serviceName=RANGER\"\r\n}[root@ambari2012 ~]#\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Just a simple method to delete a service in Ambari using the REST API&#8230; [root@ambari2012 ~]# curl -u admin:admin -H &#8220;X-Requested-By: ambari&#8221; -X DELETE http:\/\/192.168.56.121:8080\/api\/v1\/clusters\/ambari2012\/services\/RANGER [root@ambari2012 ~]# curl -u admin:admin -H &#8220;X-Requested-By: ambari&#8221; -X DELETE http:\/\/192.168.56.121:8080\/api\/v1\/clusters\/ambari2012\/services\/RANGER { \u00a0 &#8220;status&#8221; :&hellip;<\/p>\n<p class=\"more-link-p\"><a class=\"more-link\" href=\"http:\/\/appcrawler.com\/wordpress\/2015\/09\/02\/deleting-a-service-in-ambari\/\">Read more &rarr;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"footnotes":""},"categories":[61,17],"tags":[],"_links":{"self":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/4911"}],"collection":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/comments?post=4911"}],"version-history":[{"count":4,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/4911\/revisions"}],"predecessor-version":[{"id":5095,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/4911\/revisions\/5095"}],"wp:attachment":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/media?parent=4911"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/categories?post=4911"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/tags?post=4911"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}