Created 09-04-2017 02:37 PM
Ambari services can be configured to start automatically on system boot. Each service can be configured to start all components, masters and workers, or selectively.
so how to enable all services in ambari cluster to start automatically on system boot by API ?
Created 09-04-2017 04:23 PM
Because there is & symbol in the API call to Shell is taking it differently. So to avoid that please put the whole URL inside Quotation mark as following:
# curl -H "X-Requested-By: ambari" -u admin:admin -X GET "http://localhost:8080/api/v1/clusters/Sandbox/components?fields=ServiceComponentInfo/component_name,ServiceComponentInfo/service_name,ServiceComponentInfo/categoy,ServiceComponentInfo/recovery_enabled,ServiceComponentInfo/total_count&minimal_response=true"
.
Created 09-04-2017 04:19 PM
now the API runs but not return prompt ( only after ENTER we get prompt )
Created 09-04-2017 04:22 PM
capture.png see the PIC above , why after API the Auto-Start Services still disable from the GUI ?
Created 09-04-2017 04:23 PM
Because there is & symbol in the API call to Shell is taking it differently. So to avoid that please put the whole URL inside Quotation mark as following:
# curl -H "X-Requested-By: ambari" -u admin:admin -X GET "http://localhost:8080/api/v1/clusters/Sandbox/components?fields=ServiceComponentInfo/component_name,ServiceComponentInfo/service_name,ServiceComponentInfo/categoy,ServiceComponentInfo/recovery_enabled,ServiceComponentInfo/total_count&minimal_response=true"
.
Created 09-04-2017 04:48 PM
another note the components - JournalNode,ZKFailoverController are still disable