Community Articles
Find and share helpful community-sourced technical articles
Labels (1)

1. Get the output from Ambari server

http://AMBARI-HOST:8080/api/v1/stacks/HDP/versions?fields=repository_versions/operating_systems/repo...


2. Copy the json of "operating_systems" outer block of step1 output and create repo.json file -

it would looks like repo.json


3. update repo.json file to reflect your changes/modifications.


4. now run below API call to update.


curl -insecure  -H "X-Requested-By:ambari" --user admin:admin --data @repo.json  -X PUT  http://AMBARI-HOST:8080/api/v1/stacks/HDP/versions/3.1/repository_versions/1

Note: please make sure you include correct repo version id at the end. in this case it is 1


5. Now go and check in UI to see if those changes reflects.


Note: This tried and tested in Ambari2.7.x

893 Views
0 Kudos
Comments

Helpfull Article to update Repo URLS incase manage version UI is not loading.