<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Ranger &amp;quot;Test Connection&amp;quot; button REST API? in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238235#M85386</link>
    <description>&lt;P&gt;Perfect!. Thank you so much &lt;A rel="user" href="https://community.cloudera.com/users/14200/asirna.html" nodeid="14200"&gt;@Aditya Sirna&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 07 Dec 2018 15:42:03 GMT</pubDate>
    <dc:creator>kholis</dc:creator>
    <dc:date>2018-12-07T15:42:03Z</dc:date>
    <item>
      <title>Ranger "Test Connection" button REST API?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238233#M85384</link>
      <description>&lt;P&gt;
 What is REST API similar to click on "Test Connection" button in Ranger? I want to make script to check plugin connections is OK.&lt;/P&gt;&lt;P&gt;
 &lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="94451-screenshot-at-dec-06-17-24-30.png" style="width: 913px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/14135iEDDDD2C80A56B84D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="94451-screenshot-at-dec-06-17-24-30.png" alt="94451-screenshot-at-dec-06-17-24-30.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;
 Thank you.&lt;/P&gt;</description>
      <pubDate>Sat, 17 Aug 2019 23:02:50 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238233#M85384</guid>
      <dc:creator>kholis</dc:creator>
      <dc:date>2019-08-17T23:02:50Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger "Test Connection" button REST API?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238234#M85385</link>
      <description>&lt;P&gt; &lt;A rel="user" href="https://community.cloudera.com/users/43312/nurkholismajid.html" nodeid="43312"&gt;@nur majid&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;You can use the below API to validate the config&lt;/P&gt;&lt;PRE&gt;curl -u username:password -X POST -d '{post-body-json-mentioned-below}' -H "Content-Type:application/json" &lt;A href="http://{ranger-host}:{port}/service/plugins/services/validateConfig" target="_blank"&gt;http://{ranger-host}:{port}/service/plugins/services/validateConfig&lt;/A&gt;&lt;/PRE&gt;&lt;P&gt;Sample post body looks like below&lt;/P&gt;&lt;PRE&gt;{
  "id": 1,
  "guid": "fd82acf1-d3e9-4707-9a75-a839a9802cd9",
  "isEnabled": true,
  "createdBy": "hdfs",
  "updatedBy": "hdfs",
  "createTime": 1544045853000,
  "updateTime": 1544045853000,
  "version": 1,
  "type": "hdfs",
  "name": "cl1_hadoop",
  "description": "hdfs repo",
  "configs": {
    "username": "hadoop",
    "password": "*****",
    "fs.default.name": "hdfs://mycluster",
    "hadoop.security.authorization": true,
    "hadoop.security.authentication": "kerberos",
    "hadoop.security.auth_to_local": "RULE:[1:$1@$0](ambari-qa@EXAMPLE.COM)s/.*/ambari-qa/RULE:[1:$1@$0](hbase@EXAMPLE.COM)s/.*/hbase/RULE:[1:$1@$0](hdfs@EXAMPLE.COM)s/.*/hdfs/RULE:[1:$1@$0](yarn-ats@EXAMPLE.COM)s/.*/yarn-ats/RULE:[1:$1@$0](.*@EXAMPLE.COM)s/@.*//RULE:[2:$1@$0](amshbase@EXAMPLE.COM)s/.*/ams/RULE:[2:$1@$0](amsmon@EXAMPLE.COM)s/.*/ams/RULE:[2:$1@$0](amszk@EXAMPLE.COM)s/.*/ams/RULE:[2:$1@$0](atlas@EXAMPLE.COM)s/.*/atlas/RULE:[2:$1@$0](dn@EXAMPLE.COM)s/.*/hdfs/RULE:[2:$1@$0](hbase@EXAMPLE.COM)s/.*/hbase/RULE:[2:$1@$0](hive@EXAMPLE.COM)s/.*/hive/RULE:[2:$1@$0](jhs@EXAMPLE.COM)s/.*/mapred/RULE:[2:$1@$0](jn@EXAMPLE.COM)s/.*/hdfs/RULE:[2:$1@$0](knox@EXAMPLE.COM)s/.*/knox/RULE:[2:$1@$0](nfs@EXAMPLE.COM)s/.*/hdfs/RULE:[2:$1@$0](nm@EXAMPLE.COM)s/.*/yarn/RULE:[2:$1@$0](nn@EXAMPLE.COM)s/.*/hdfs/RULE:[2:$1@$0](rangeradmin@EXAMPLE.COM)s/.*/ranger/RULE:[2:$1@$0](rangerkms@EXAMPLE.COM)s/.*/keyadmin/RULE:[2:$1@$0](rangertagsync@EXAMPLE.COM)s/.*/rangertagsync/RULE:[2:$1@$0](rangerusersync@EXAMPLE.COM)s/.*/rangerusersync/RULE:[2:$1@$0](rm@EXAMPLE.COM)s/.*/yarn/RULE:[2:$1@$0](yarn@EXAMPLE.COM)s/.*/yarn/RULE:[2:$1@$0](yarn-ats-hbase@EXAMPLE.COM)s/.*/yarn-ats/DEFAULT",
    "dfs.datanode.kerberos.principal": "dn/test-node-4.openstacklocal@EXAMPLE.COM",
    "dfs.namenode.kerberos.principal": "nn/test-node-4.openstacklocal@EXAMPLE.COM",
    "dfs.secondary.namenode.kerberos.principal": "nn/test-node-4.openstacklocal@EXAMPLE.COM",
    "hadoop.rpc.protection": "privacy",
    "commonNameForCertificate": "-",
    "tag.download.auth.users": "hdfs",
    "policy.download.auth.users": "hdfs"
  },
  "policyVersion": 3,
  "policyUpdateTime": 1544045856000,
  "tagVersion": 1,
  "tagUpdateTime": 1544045853000,
  "tagService": ""
}&lt;/PRE&gt;&lt;P&gt;You can get the exact json for your cluster from the browser's developer tools&lt;/P&gt;&lt;P&gt;Right Click -&amp;gt; Inspect -&amp;gt; Network -&amp;gt; Click on the request -&amp;gt; Request payload&lt;/P&gt;&lt;P&gt;.&lt;/P&gt;&lt;P&gt;If this helped you , please take a moment to login and "Accept" the answer &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 20:25:50 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238234#M85385</guid>
      <dc:creator>asirna</dc:creator>
      <dc:date>2018-12-06T20:25:50Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger "Test Connection" button REST API?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238235#M85386</link>
      <description>&lt;P&gt;Perfect!. Thank you so much &lt;A rel="user" href="https://community.cloudera.com/users/14200/asirna.html" nodeid="14200"&gt;@Aditya Sirna&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 15:42:03 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Ranger-quot-Test-Connection-quot-button-REST-API/m-p/238235#M85386</guid>
      <dc:creator>kholis</dc:creator>
      <dc:date>2018-12-07T15:42:03Z</dc:date>
    </item>
  </channel>
</rss>

