Created 01-23-2017 04:42 PM
If I know the tag for a previous hive-site configuration how can instruct REST to restore to it? The only thing I've found is for restoring a level higher (HIVE), but I don't know that version. And is there a document that describes these types of task?
Created 01-23-2017 04:58 PM
Below example curl call should help you
curl -u admin:admin -H 'X-Requested-By:admin' -X PUT 'http://localhost:8080/api/v1/clusters/cc' -d '{ "Clusters": { "desired_service_config_versions": { "service_name" : "HDFS", "service_config_version" : 1, "service_config_version_note" : "Manual rollback to service config version 1 (HDFS)" } } }'
Please refer https://cwiki.apache.org/confluence/display/AMBARI/Service+Config+Versions+API+usage for more details.
Hope this helps.
Created 01-23-2017 05:12 PM
I tried that, but specifying a service_name of hive-site results in a 404.
Created 01-23-2017 06:04 PM
@Neil Watson
It is not good idea of restoring the specific sub config types. better you operate/modify at service level rather than at sub config types level.
Created 01-23-2017 06:17 PM
As per my understanding you will not be able to modify/update sub config types, you will have to do at service level.
If you don't know the service level version then first try to find out the version number.
You can run API to get all the version of HIVE
http://AMBARIHOST:8080/api/v1/clusters/test/configurations/service_config_versions?service_name=HIVE
From the output you can find your hive-site config version number and pick corresponding HIVE service version from the same block and then try to use curl -u admin:admin -H 'X-Requested-By:admin'-X PUT 'http://localhost:8080/api/v1/clusters/cc'-d