I'm trying to display the list of Yarn group in curl command with grep.
current_group=$(curl -u "${ranger_admin}:${ranger_password}" \ "${ranger_host}/service/public/v2/api/service/${ranger_cluster}_${policyService}/policy/YARN%20${policyName}" | grep -Poz '(?:\G(?!^)",|"${groups}":\s*\[)\s*"\K[^"]+') echo "${current_group}"
the result is :
curl: (22) The requested URL returned error: 404 Not Found curl: (1) Protocol http not supported or disabled in libcurl curl: (22) The requested URL returned error: 400 Bad Request
How can I resolve it ?