<?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 Knox Plugin is failing in test connection while creating service -&amp;gt; Unable to retrieve any topologies/services using given parameters. in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231173#M193017</link>
    <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;
&lt;/P&gt;&lt;P&gt; &lt;A rel="user" href="https://community.cloudera.com/users/598/vsuvagia.html" nodeid="598"&gt;@vsuvagia&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If you look at the gateway.log I attached in my previous post, the main error is -&amp;gt; ERROR knox.RangerPDPKnoxFilter (RangerPDPKnoxFilter.java:init(73)) - Error while setting UGI for Knox Plugin...&lt;/P&gt;&lt;P&gt;I tried to look for this error and I found this post -&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/questions/97518/help-ad-integration-with-knox.html" target="_blank"&gt;https://community.hortonworks.com/questions/97518/help-ad-integration-with-knox.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;In this post, the resolution is to change Authorization provider in admin topology from XAsecurePDPKnox to AclsAuthz.&lt;/P&gt;&lt;P&gt;I tried that too and I am getting a successfull connection by changing this but I read somewhere that to enable Ranger plugin, authorization provider has to be XAsecurePDPKnox.&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;</description>
    <pubDate>Wed, 14 Mar 2018 02:12:53 GMT</pubDate>
    <dc:creator>nhgodwal</dc:creator>
    <dc:date>2018-03-14T02:12:53Z</dc:date>
    <item>
      <title>Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231162#M193006</link>
      <description>&lt;P&gt;This is the knoxurl I am giving while creating service in knox plugin:  &lt;A href="https://localhost:8443/gateway/admin/api/v1/topologies" target="_blank"&gt;https://localhost:8443/gateway/admin/api/v1/topologies&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I have also added group info in topologies/admin.xml as per suggestion here (https://community.hortonworks.com/articles/38348/ranger-is-not-allowing-access-to-knox-resources-wh.html)&lt;/P&gt;&lt;PRE&gt;	    &amp;lt;param&amp;gt;
                &amp;lt;name&amp;gt;main.ldapRealm.authorizationEnabled&amp;lt;/name&amp;gt;
                &amp;lt;value&amp;gt;true&amp;lt;/value&amp;gt;
            &amp;lt;/param&amp;gt;
            &amp;lt;param&amp;gt;
                &amp;lt;name&amp;gt;main.ldapRealm.groupSearchBase&amp;lt;/name&amp;gt;
                &amp;lt;value&amp;gt;ou=groups,dc=hadoop,dc=apache,dc=org&amp;lt;/value&amp;gt;
            &amp;lt;/param&amp;gt;
            &amp;lt;param&amp;gt;
                &amp;lt;name&amp;gt;main.ldapRealm.groupObjectClass&amp;lt;/name&amp;gt;
                &amp;lt;value&amp;gt;group&amp;lt;/value&amp;gt;
            &amp;lt;/param&amp;gt;
            &amp;lt;param&amp;gt;
                &amp;lt;name&amp;gt;main.ldapRealm.groupIdAttribute&amp;lt;/name&amp;gt;
                &amp;lt;value&amp;gt;cn&amp;lt;/value&amp;gt;
            &amp;lt;/param&lt;/PRE&gt;&lt;P&gt;Below are the log details:&lt;/P&gt;&lt;P&gt;ranger-admin.log&lt;/P&gt;&lt;PRE&gt;2018-02-26 00:34:47,535 [timed-executor-pool-0] INFO  apache.ranger.services.knox.client.KnoxClient (KnoxClient.java:81)
 - Password decryption failed; trying knox connection with received password string
2018-02-26 00:34:47,632 [timed-executor-pool-0] ERROR apache.ranger.services.knox.client.KnoxClient (KnoxClient.java:131) - Got invalid REST response from: &lt;A href="https://localhost:8443/gateway/admin/api/v1/topologies" target="_blank"&gt;https://localhost:8443/gateway/admin/api/v1/topologies&lt;/A&gt;, responseStatus: 403&lt;/PRE&gt;&lt;P&gt;gateway.log&lt;/P&gt;&lt;PRE&gt;2018-02-26 00:34:47,614 INFO  hadoop.gateway (KnoxLdapRealm.java:getUserDn(691)) - Computed userDn: uid=admin,ou=people,dc=hadoop,dc=apache,dc=org using dnTemplate for principal: admin
2018-02-26 00:34:47,630 ERROR hadoop.gateway (KnoxLdapRealm.java:getRoles(246)) - Failed to get system ldap connection: javax.naming.AuthenticationException: [LDAP: error code 49 - INVALID_CREDENTIALS: Bind failed: ERR_229 Cannot authenticate user ]&lt;/PRE&gt;&lt;P&gt;gateway-audit.log&lt;/P&gt;&lt;PRE&gt;18/02/26 00:24:44 ||65cc6da4-9fa6-4e6d-8b69-b99f5d9acacb|audit|127.0.0.1|KNOX|admin|||authentication|uri|/gateway/admin/api/v1/topologies|success|Groups: [] 18/02/26 00:24:44 ||65cc6da4-9fa6-4e6d-8b69-b99f5d9acacb|audit|127.0.0.1|KNOX|admin|||access|uri|/gateway/admin/api/v1/topologies|success|Response status: 403&lt;/PRE&gt;</description>
      <pubDate>Mon, 26 Feb 2018 08:47:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231162#M193006</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-02-26T08:47:40Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231163#M193007</link>
      <description>&lt;P&gt;@&lt;A href="https://community.hortonworks.com/users/45324/nhgodwal.html"&gt;GN_Exp&lt;/A&gt; is this cluster an unsecure cluster ? if so the can you please validate the username and password given in the knox repo ?&lt;/P&gt;</description>
      <pubDate>Wed, 28 Feb 2018 04:25:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231163#M193007</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2018-02-28T04:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231164#M193008</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;&lt;P&gt;Yes, the cluster is not Kerberos secured. I have validated the username and corrected the password I was giving while creating service. Now, I am not able to see any error in gateway.log. But gateway-audit.log and ranger-admin.log still showing same error. &lt;/P&gt;&lt;P&gt;Can you suggest?&lt;/P&gt;</description>
      <pubDate>Thu, 08 Mar 2018 03:10:14 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231164#M193008</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-08T03:10:14Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231165#M193009</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt; &lt;/P&gt;&lt;P&gt;i am using same username and password as I am using for HDFS service.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Mar 2018 07:52:39 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231165#M193009</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-09T07:52:39Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231166#M193010</link>
      <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/users/45324/nhgodwal.html"&gt;GN_Exp&lt;/A&gt; is there ranger knox policy present to allow access to admin user the access of  ?&lt;/P&gt;</description>
      <pubDate>Mon, 12 Mar 2018 01:57:34 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231166#M193010</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2018-03-12T01:57:34Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231167#M193011</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt; Thanks for replying.&lt;/P&gt;&lt;P&gt;Yes, when I create knox service, it automatically creates a policy to allow access to admin. But it didn't show in Audit tab. I am attaching screen shots too.&lt;/P&gt;&lt;P&gt;Also, this time I did the fresh intsallation of ranger, hdfs-plugin and then knox plugin. I find logs little different then previous.&lt;/P&gt;&lt;P&gt;gateway-audit.log&lt;/P&gt;&lt;PRE&gt;18/03/11 22:57:46 ||bf9148a8-fe74-4a1a-b18f-9a300f0a062c|audit|127.0.0.1|KNOX||||access|uri|/gateway/admin/api/v1/topologies|unavailable|Request method: GET&lt;BR /&gt;18/03/11 22:57:46 ||bf9148a8-fe74-4a1a-b18f-9a300f0a062c|audit|127.0.0.1|KNOX||||authentication|principal|admin|failure|LDAP authentication failed.&lt;BR /&gt;18/03/11 22:57:46 ||bf9148a8-fe74-4a1a-b18f-9a300f0a062c|audit|127.0.0.1|KNOX||||access|uri|/gateway/admin/api/v1/topologies|success|Response status: 401&lt;/PRE&gt;&lt;P&gt;gateway.log&lt;/P&gt;&lt;PRE&gt;2018-03-11 22:57:46,092 INFO  hadoop.gateway (KnoxLdapRealm.java:getUserDn(691)) - Computed userDn: uid=admin,ou=people,dc=hadoop,dc=apache,dc=org using dnTemplate for principal: admin&lt;BR /&gt;2018-03-11 22:57:46,118 INFO  hadoop.gateway (KnoxLdapRealm.java:doGetAuthenticationInfo(203)) - Could not login: org.apache.shiro.authc.UsernamePasswordToken - admin, rememberMe=false (127.0.0.1)&lt;BR /&gt;2018-03-11 22:57:46,121 ERROR hadoop.gateway (KnoxLdapRealm.java:doGetAuthenticationInfo(205)) - Shiro unable to login: javax.naming.AuthenticationException: [LDAP: error code 49 - INVALID_CREDENTIALS: Bind failed: ERR_229 Cannot authenticate user uid=admin,ou=people,dc=hadoop,dc=apache,dc=org]&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;ranger_admin.log&lt;/P&gt;&lt;PRE&gt;2018-03-11 22:57:45,291 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/ranger-knox-plugin-0.7.0.2.6.4.0-91.jar&lt;BR /&gt;2018-03-11 22:57:45,291 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/jackson-core-asl-1.9.13.jar&lt;BR /&gt;2018-03-11 22:57:45,292 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/commons-collections-3.2.2.jar&lt;BR /&gt;2018-03-11 22:57:45,293 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/jackson-mapper-asl-1.9.13.jar&lt;BR /&gt;2018-03-11 22:57:45,293 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/commons-lang-2.6.jar&lt;BR /&gt;2018-03-11 22:57:46,142 [timed-executor-pool-0] ERROR apache.ranger.services.knox.client.KnoxClient (KnoxClient.java:131) - Got invalid REST response from: &lt;A href="https://localhost:8443/gateway/admin/api/v1/topologies" target="_blank"&gt;https://localhost:8443/gateway/admin/api/v1/topologies&lt;/A&gt;, responseStatus: 401&lt;/PRE&gt;&lt;P&gt;&lt;BR /&gt;I installed the ranger and plugins referring this link -&amp;gt; &lt;A href="https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.6.4/bk_command-line-installation/content/ch_installing_ranger_chapter.html" target="_blank"&gt;https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.6.4/bk_command-line-installation/content/ch_installing_ranger_chapter.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Please let me know if you need me to post any config files.&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://community.cloudera.com/t5/image/serverpage/image-id/7668i5F1A088470049047/image-size/large?v=1.0&amp;amp;px=999" border="0" alt="audit-tab.png" title="audit-tab.png" /&gt;&lt;IMG src="https://community.cloudera.com/t5/image/serverpage/image-id/7669iB97C3AE8652DC66E/image-size/large?v=1.0&amp;amp;px=999" border="0" alt="policy-knox.png" title="policy-knox.png" /&gt;</description>
      <pubDate>Mon, 12 Mar 2018 05:51:34 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231167#M193011</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-12T05:51:34Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231168#M193012</link>
      <description>&lt;P&gt;I think you are using LDAP that comes with knox , can you please check if it is up and running ? and if yes then check for that admin user password in users.ldif file in /etc/knox/conf. by defaut it is admin-password &lt;/P&gt;</description>
      <pubDate>Mon, 12 Mar 2018 13:05:53 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231168#M193012</guid>
      <dc:creator>dsharma</dc:creator>
      <dc:date>2018-03-12T13:05:53Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231169#M193013</link>
      <description>&lt;P&gt;@GN_Exp, looks like the url for Knox present with Ranger is pointing to &lt;EM&gt;localhost&lt;/EM&gt;&lt;EM&gt;, &lt;/EM&gt;can you try using the actual f.q.d.n of the Knox host, even if both Ranger and Knox services are on the same host.&lt;BR /&gt;Also as &lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt; suggested, can you check if the LDAP server being used by Knox service is started and working.&lt;/P&gt;</description>
      <pubDate>Mon, 12 Mar 2018 13:11:28 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231169#M193013</guid>
      <dc:creator>vsuvagia</dc:creator>
      <dc:date>2018-03-12T13:11:28Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231170#M193014</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;     &lt;A rel="user" href="https://community.cloudera.com/users/598/vsuvagia.html" nodeid="598"&gt;@vsuvagia&lt;/A&gt;&lt;/P&gt;&lt;P&gt;yes, I am using demo LDAP comes with knox. &lt;/P&gt;&lt;P&gt;I changed the password from admin to admin-password. Now I am getting different error logs:&lt;/P&gt;&lt;P&gt;Even changing the localhost to fqdn giving me same error logs.&lt;/P&gt;&lt;P&gt;ranger-admin.log&lt;/P&gt;&lt;PRE&gt;2018-03-12 14:34:55,969 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/ranger-knox-plugin-0.7.0.2.6.4.0-91.jar
2018-03-12 14:34:55,970 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/jackson-core-asl-1.9.13.jar
2018-03-12 14:34:55,970 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/commons-collections-3.2.2.jar
2018-03-12 14:34:55,970 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/jackson-mapper-asl-1.9.13.jar
2018-03-12 14:34:55,970 [http-bio-6080-exec-9] WARN  org.apache.ranger.biz.ServiceMgr (ServiceMgr.java:355) - getFilesInDirectory('ranger-plugins/knox'): adding /usr/hdp/2.6.4.0-91/ranger-admin/ews/webapp/WEB-INF/classes/ranger-plugins/knox/commons-lang-2.6.jar
2018-03-12 14:34:56,013 [timed-executor-pool-0] ERROR org.apache.ranger.plugin.util.PasswordUtils (PasswordUtils.java:130) - Unable to decrypt password due to error
javax.crypto.IllegalBlockSizeException: Input length must be multiple of 8 when decrypting with padded cipher
        at com.sun.crypto.provider.CipherCore.doFinal(CipherCore.java:936)
        at com.sun.crypto.provider.CipherCore.doFinal(CipherCore.java:847)
        at com.sun.crypto.provider.PBES1Core.doFinal(PBES1Core.java:416)
        at com.sun.crypto.provider.PBEWithMD5AndDESCipher.engineDoFinal(PBEWithMD5AndDESCipher.java:316)
        at javax.crypto.Cipher.doFinal(Cipher.java:2165)
        at org.apache.ranger.plugin.util.PasswordUtils.decryptPassword(PasswordUtils.java:115)
        at org.apache.ranger.services.knox.client.KnoxClient.getTopologyList(KnoxClient.java:79)
        at org.apache.ranger.services.knox.client.KnoxClient$2.call(KnoxClient.java:406)
        at org.apache.ranger.services.knox.client.KnoxClient$2.call(KnoxClient.java:402)
        at org.apache.ranger.services.knox.client.KnoxClient.timedTask(KnoxClient.java:431)
        at org.apache.ranger.services.knox.client.KnoxClient.getKnoxResources(KnoxClient.java:410)
        at org.apache.ranger.services.knox.client.KnoxClient.connectionTest(KnoxClient.java:315)
        at org.apache.ranger.services.knox.client.KnoxResourceMgr.validateConfig(KnoxResourceMgr.java:43)
        at org.apache.ranger.services.knox.RangerServiceKnox.validateConfig(RangerServiceKnox.java:56)
        at org.apache.ranger.biz.ServiceMgr$ValidateCallable.actualCall(ServiceMgr.java:560)
        at org.apache.ranger.biz.ServiceMgr$ValidateCallable.actualCall(ServiceMgr.java:547)
        at org.apache.ranger.biz.ServiceMgr$TimedCallable.call(ServiceMgr.java:508)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
        at java.lang.Thread.run(Thread.java:748)
2018-03-12 14:34:56,015 [timed-executor-pool-0] INFO  apache.ranger.services.knox.client.KnoxClient (KnoxClient.java:81) - Password decryption failed; trying knox connection with received password string
2018-03-12 14:34:57,918 [timed-executor-pool-0] ERROR apache.ranger.services.knox.client.KnoxClient (KnoxClient.java:131) - Got invalid REST response from: &lt;A href="https://localhost:8443/gateway/admin/api/v1/topologies" target="_blank"&gt;https://localhost:8443/gateway/admin/api/v1/topologies&lt;/A&gt;, responseStatus: 500&lt;/PRE&gt;&lt;P&gt;gateway-audit.log&lt;/P&gt;&lt;PRE&gt;18/03/12 14:34:56 ||3e3df102-de59-4c19-9779-cdd4522181bb|audit|127.0.0.1|KNOX||||access|uri|/gateway/admin/api/v1/topologies|unavailable|Request method: GET
18/03/12 14:34:56 ||3e3df102-de59-4c19-9779-cdd4522181bb|audit|127.0.0.1|KNOX|admin|||authentication|uri|/gateway/admin/api/v1/topologies|success|
18/03/12 14:34:56 ||3e3df102-de59-4c19-9779-cdd4522181bb|audit|127.0.0.1|KNOX|admin|||authentication|uri|/gateway/admin/api/v1/topologies|success|Groups: []
18/03/12 14:34:57 ||3e3df102-de59-4c19-9779-cdd4522181bb|audit|127.0.0.1|KNOX|admin|||access|uri|/gateway/admin/api/v1/topologies|failure|&lt;/PRE&gt;&lt;P&gt;gateway.log&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.cloudera.com/legacyfs/online/attachments/62856-gateway-log.txt"&gt;gateway-log.txt&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Mar 2018 21:45:48 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231170#M193014</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-12T21:45:48Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231171#M193015</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/45324/nhgodwal.html" nodeid="45324"&gt;@GN_Exp&lt;/A&gt;, has the Knox certificate been imported in Ranger truststore ?&lt;BR /&gt;If not here are some links you can follow:&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.6.4/bk_command-line-installation/content/installing_ranger_plugins.html#installing_ranger_knox_plugin"&gt;installing ranger-knox plugin.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/questions/156848/ranger-knox-repo-test-connection-failure.html"&gt;ranger-knox-repo-test-connection-failure.&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/questions/2923/do-we-need-to-add-knox-self-signed-cert-into-range.html"&gt;do-we-need-to-add-knox-self-signed-cert-into-range.&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Mar 2018 17:07:06 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231171#M193015</guid>
      <dc:creator>vsuvagia</dc:creator>
      <dc:date>2018-03-13T17:07:06Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231172#M193016</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/598/vsuvagia.html" nodeid="598"&gt;@vsuvagia&lt;/A&gt; &lt;/P&gt;&lt;P&gt;Yes, I did import the knox cert to Ranger truststore. I am not getting any SSL error.&lt;/P&gt;</description>
      <pubDate>Tue, 13 Mar 2018 21:46:23 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231172#M193016</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-13T21:46:23Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231173#M193017</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/505/dsharma.html" nodeid="505"&gt;@Deepak Sharma&lt;/A&gt;
&lt;/P&gt;&lt;P&gt; &lt;A rel="user" href="https://community.cloudera.com/users/598/vsuvagia.html" nodeid="598"&gt;@vsuvagia&lt;/A&gt;&lt;/P&gt;&lt;P&gt;If you look at the gateway.log I attached in my previous post, the main error is -&amp;gt; ERROR knox.RangerPDPKnoxFilter (RangerPDPKnoxFilter.java:init(73)) - Error while setting UGI for Knox Plugin...&lt;/P&gt;&lt;P&gt;I tried to look for this error and I found this post -&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.hortonworks.com/questions/97518/help-ad-integration-with-knox.html" target="_blank"&gt;https://community.hortonworks.com/questions/97518/help-ad-integration-with-knox.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;In this post, the resolution is to change Authorization provider in admin topology from XAsecurePDPKnox to AclsAuthz.&lt;/P&gt;&lt;P&gt;I tried that too and I am getting a successfull connection by changing this but I read somewhere that to enable Ranger plugin, authorization provider has to be XAsecurePDPKnox.&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;</description>
      <pubDate>Wed, 14 Mar 2018 02:12:53 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231173#M193017</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-14T02:12:53Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231174#M193018</link>
      <description>&lt;P&gt;Hello &lt;A rel="user" href="https://community.cloudera.com/users/45324/nhgodwal.html" nodeid="45324"&gt;@GN_Exp&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;There are couple of things here:&lt;/P&gt;&lt;P&gt;1. From your gateway.log (dt:03/12), it looks like the Knox Gateway is trying to initialize RangerPDPKnoxFilter in the Gateway request filter and failing while doing so. This RangerPDPKnoxFilter is used when Kerberos is configured. Since you don't have Kerberos configured, you should not be using this.&lt;/P&gt;&lt;P&gt;2. To enable the Ranger plugin in Knox gateway service, you do not always need XAsecurePDPKnox as authorization provider. "AclsAuthz" would do just fine. This is usually used for &lt;A href="https://knox.apache.org/books/knox-1-0-0/user-guide.html#Service+Level+Authorization" target="_blank"&gt;Service Level Authorization&lt;/A&gt; in Knox topology, which you don't need for Ranger plugin test connection.&lt;/P&gt;&lt;P&gt;Therefore, please stick to "AclsAuthz" unless you have any other use-case. If you still have problem with Knox service repo in Ranger, please attach the screenshot of Knox repo configuration from Ranger UI and screenshot of the error (if any).&lt;/P&gt;&lt;P&gt;Hope this helps !&lt;/P&gt;</description>
      <pubDate>Thu, 15 Mar 2018 09:28:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231174#M193018</guid>
      <dc:creator>VR46</dc:creator>
      <dc:date>2018-03-15T09:28:46Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231175#M193019</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/740/vrathor.html" nodeid="740"&gt;@Vipin Rathor&lt;/A&gt; Thank you so much for the explanation! &lt;/P&gt;&lt;P&gt;I have a follow up question too. &lt;/P&gt;&lt;P&gt;If I use 'AclsAuthz' provider then I won't be able to do service level authorization in Ranger by creating policies..is this correct? &lt;/P&gt;&lt;P&gt;I think because in that case service level authorization will be enforced what I define in knox topology like below under 'AclsAuthz' provider.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&amp;lt;param&amp;gt;
    &amp;lt;name&amp;gt;{serviceName}.acl&amp;lt;/name&amp;gt;
    &amp;lt;value&amp;gt;username[,*|username...];group[,*|group...];ipaddr[,*|ipaddr...]&amp;lt;/value&amp;gt;
&amp;lt;/param&amp;gt;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 15 Mar 2018 22:08:59 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231175#M193019</guid>
      <dc:creator>nhgodwal</dc:creator>
      <dc:date>2018-03-15T22:08:59Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Knox Plugin is failing in test connection while creating service -&gt; Unable to retrieve any topologies/services using given parameters.</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231176#M193020</link>
      <description>&lt;P&gt;That's correct &lt;A rel="user" href="https://community.cloudera.com/users/45324/nhgodwal.html" nodeid="45324"&gt;@GN_Exp&lt;/A&gt;. If you want to do SLA in Knox via Ranger plugin then you'd need kerberos too.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Mar 2018 04:45:32 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Knox-Plugin-is-failing-in-test-connection-while/m-p/231176#M193020</guid>
      <dc:creator>VR46</dc:creator>
      <dc:date>2018-03-16T04:45:32Z</dc:date>
    </item>
  </channel>
</rss>

