<?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 Group permissions from LDAP - not working in Hive in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/316947#M226956</link>
    <description>&lt;P&gt;I have the same problem using the latest hdp sandbox.&lt;/P&gt;&lt;P&gt;The GROUP in Ranger is not working, only the users, even if in Ranger it is clearly shown the users/groups relationship, and turn the group/user mapping on for AD authentication/authorization.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The sandbox is configured in convoluted way, I couldn't figure out where the hive server 2 is running, in the virtual machine, or in some docker container? Could someone help?&lt;/P&gt;</description>
    <pubDate>Fri, 21 May 2021 21:46:32 GMT</pubDate>
    <dc:creator>snowman</dc:creator>
    <dc:date>2021-05-21T21:46:32Z</dc:date>
    <item>
      <title>Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171518#M133815</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;We use HDP 2.3 with Ranger 0.5 for managing HIVE permissions. (not for HDFS. Just hive).
Ranger (usersync) is configured to use Active Directory and it syncs the users &amp;amp; groups from AD without any issues.
In Ranger &amp;gt;&amp;gt;&amp;gt; Settings &amp;gt;&amp;gt;&amp;gt; Users/Groups we see each user and it's &lt;STRONG&gt;corresponding Active Directory groups.&lt;/STRONG&gt;
When granting authorizations to users for hive access - it works perfect !
However - when using groups (which is way more efficient to manage) it just doesn't work. Permission is always denied.
It seems using groups just doesn't work - only users.
&lt;STRONG&gt;Again - the sync works and i'm able to see the each users' groups in Ranger - but when i use groups instead of users for hive permissions - it does nothing.
&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="8035-snap-2016-09-27-at-182302.png" style="width: 1269px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/20056i6F36445C4504BDD6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="8035-snap-2016-09-27-at-182302.png" alt="8035-snap-2016-09-27-at-182302.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any ideas why ?&lt;/P&gt;&lt;P&gt;Thanks in advance !&lt;/P&gt;&lt;P&gt;Adi J.&lt;/P&gt;</description>
      <pubDate>Sun, 18 Aug 2019 10:39:42 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171518#M133815</guid>
      <dc:creator>Adija1</dc:creator>
      <dc:date>2019-08-18T10:39:42Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171519#M133816</link>
      <description>&lt;P&gt;@Adi Jabkowsky Usually this happens because Hiveserver2 cannot determine which groups the user belongs to. Check your Hiveserver2 log for a message that looks like "No groups for user XXX" where XXX is the user that is being denied access.&lt;/P&gt;&lt;P&gt;If this is the case you'll need to make sure that the OS on the Hiveserver2 node can resolve the groups for that user. Either configure the OS to pull user and group information from Active Directory or set up &lt;A href="http://hortonworks.com/blog/hadoop-groupmapping-ldap-integration/"&gt;Hadoop Group Mapping&lt;/A&gt;. &lt;/P&gt;</description>
      <pubDate>Tue, 27 Sep 2016 22:35:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171519#M133816</guid>
      <dc:creator>tstebbens</dc:creator>
      <dc:date>2016-09-27T22:35:46Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171520#M133817</link>
      <description>&lt;A rel="user" href="https://community.cloudera.com/users/50/tstebbens.html" nodeid="50"&gt;@Terry Stebbens&lt;/A&gt;&lt;P&gt;Thank you for replying !
It is as if the groups are not even being checked - just the user.
When i try to select a table which my group has access to the hiveserver2 log shows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&lt;STRONG&gt;2016-09-27 18:57:01,331 ERROR&lt;/STRONG&gt; [HiveServer2-Handler-Pool: Thread-45]: ql.Driver (SessionState.java:printError(960)) - FAILED: HiveAccessControlException &lt;STRONG&gt;Permission denied: user [adija] does not have [SELECT] privilege on [nifitest/dw_dim_subscriber]
org.apache.hadoop.hive.ql.security.authorization.plugin.HiveAccessControlException: Permission denied: user [adija] does not have [SELECT] privilege on [nifitest/dw_dim_subscriber]&lt;/STRONG&gt;
        at org.apache.ranger.authorization.hive.authorizer.RangerHiveAuthorizer.checkPrivileges(RangerHiveAuthorizer.java:352)
        at org.apache.hadoop.hive.ql.Driver.doAuthorizationV2(Driver.java:779)
        at org.apache.hadoop.hive.ql.Driver.doAuthorization(Driver.java:574)
        at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:468)
        at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:308)
        at org.apache.hadoop.hive.ql.Driver.compileInternal(Driver.java:1122)
        at org.apache.hadoop.hive.ql.Driver.compileAndRespond(Driver.java:1116)
        at org.apache.hive.service.cli.operation.SQLOperation.prepare(SQLOperation.java:110)
        at org.apache.hive.service.cli.operation.SQLOperation.runInternal(SQLOperation.java:181)
        at org.apache.hive.service.cli.operation.Operation.run(Operation.java:257)
        at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementInternal(HiveSessionImpl.java:388)
        at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementAsync(HiveSessionImpl.java:375)
        at org.apache.hive.service.cli.CLIService.executeStatementAsync(CLIService.java:274)
        at org.apache.hive.service.cli.thrift.ThriftCLIService.ExecuteStatement(ThriftCLIService.java:486)
        at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1313)
        at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1298)
        at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
        at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
        at org.apache.hive.service.auth.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:56)
        at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)&lt;/EM&gt;&lt;/P&gt;&lt;EM&gt;2016-09-27 18:57:01,365 WARN  [HiveServer2-Handler-Pool: Thread-45]: thrift.ThriftCLIService (ThriftCLIService.java:ExecuteStatement(492)) - Error executing statement:
org.apache.hive.service.cli.HiveSQLException: Error while compiling statement: FAILED: HiveAccessControlException Permission denied: user [adija] does not have [SELECT] privilege on [nifitest/dw_dim_subscriber]
        at org.apache.hive.service.cli.operation.Operation.toSQLException(Operation.java:315)
        at org.apache.hive.service.cli.operation.SQLOperation.prepare(SQLOperation.java:112)
        at org.apache.hive.service.cli.operation.SQLOperation.runInternal(SQLOperation.java:181)
        at org.apache.hive.service.cli.operation.Operation.run(Operation.java:257)
        at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementInternal(HiveSessionImpl.java:388)
        at org.apache.hive.service.cli.session.HiveSessionImpl.executeStatementAsync(HiveSessionImpl.java:375)
        at org.apache.hive.service.cli.CLIService.executeStatementAsync(CLIService.java:274)
        at org.apache.hive.service.cli.thrift.ThriftCLIService.ExecuteStatement(ThriftCLIService.java:486)
        at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1313)
        at org.apache.hive.service.cli.thrift.TCLIService$Processor$ExecuteStatement.getResult(TCLIService.java:1298)
        at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
        at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
        at org.apache.hive.service.auth.TSetIpAddressProcessor.process(TSetIpAddressProcessor.java:56)
        at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)
&lt;STRONG&gt;Caused by: org.apache.hadoop.hive.ql.security.authorization.plugin.HiveAccessControlException: Permission denied: user [adija] does not have [SELECT] privilege on [nifitest/dw_dim_subscriber]
        at &lt;/STRONG&gt;org.apache.ranger.authorization.hive.authorizer.RangerHiveAuthorizer.checkPrivileges(RangerHiveAuthorizer.java:352)
        at org.apache.hadoop.hive.ql.Driver.doAuthorizationV2(Driver.java:779)
        at org.apache.hadoop.hive.ql.Driver.doAuthorization(Driver.java:574)
        at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:468)
        at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:308)
        at org.apache.hadoop.hive.ql.Driver.compileInternal(Driver.java:1122)
        at org.apache.hadoop.hive.ql.Driver.compileAndRespond(Driver.java:1116)
        at org.apache.hive.service.cli.operation.SQLOperation.prepare(SQLOperation.java:110)
        ... 15 more&lt;/EM&gt;</description>
      <pubDate>Tue, 27 Sep 2016 23:05:59 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171520#M133817</guid>
      <dc:creator>Adija1</dc:creator>
      <dc:date>2016-09-27T23:05:59Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171521#M133818</link>
      <description>&lt;P&gt;&lt;A href="https://community.hortonworks.com/questions/58644/ranger-group-permissions-from-ldap-not-working-in.html#"&gt;@Adi Jabkowsky&lt;/A&gt; please check hdfs groups &amp;lt;user-id&amp;gt; resolve to fetch the user and it groups. if not hadoop user group mapping is not correct. you might need to check how at OS level user / group are synced ( e.g.SSSD)&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2016 02:47:34 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171521#M133818</guid>
      <dc:creator>rmani</dc:creator>
      <dc:date>2016-09-28T02:47:34Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171522#M133819</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/218/rmani.html" nodeid="218" target="_blank"&gt;@Ramesh Mani&lt;/A&gt; thank you for replying.
I don't understand why i need to use OS level group mapping for hive. The users do not exist on os and I'm not using the ranger for HDFS permissions. I'm using Ranger Just for granting &lt;STRONG&gt;hive &lt;/STRONG&gt;permissions for &lt;STRONG&gt;&lt;U&gt;users from Active Directory LDAP.&lt;/U&gt;&lt;/STRONG&gt;
The users &lt;STRONG&gt;are not created at OS&lt;/STRONG&gt; level. They do not exist on the os - they exist &lt;STRONG&gt;only&lt;/STRONG&gt; in Active Directory. 
Also, Ranger is able to&lt;STRONG&gt; see each users' groups from active directory &lt;/STRONG&gt;(please see screenshot):&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="8060-snap-2016-09-28-at-091011.png" style="width: 1588px;"&gt;&lt;img src="https://community.cloudera.com/t5/image/serverpage/image-id/20055i4172FD6BCFEFAD7E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="8060-snap-2016-09-28-at-091011.png" alt="8060-snap-2016-09-28-at-091011.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I just want to use those Active Directory groups for granting permissions - instead of users.&lt;/P&gt;&lt;P&gt;&lt;U&gt;To sum up:&lt;/U&gt;
Ranger is synced with LDAP.
Users &lt;STRONG&gt;DO NOT&lt;/STRONG&gt; exist on OS.
Ranger sees users from LDAP and &lt;STRONG&gt;their corresponding groups&lt;/STRONG&gt;. (as in screenshot).
I am able to grant LDAP users permissions for hive tables.
LDAP users can access hive tables according to the permissions i give them. 
BUT - if i'm using LDAP groups (which ranger sees) for granting permissions - LDAP users that reside in that group receive permission denied.
&lt;/P&gt;</description>
      <pubDate>Sun, 18 Aug 2019 10:39:35 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171522#M133819</guid>
      <dc:creator>Adija1</dc:creator>
      <dc:date>2019-08-18T10:39:35Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171523#M133820</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/2591/adija-1.html" nodeid="2591"&gt;@Adi Jabkowsky&lt;/A&gt; The reason that the users need to exist on the OS (or for you to use &lt;A href="http://hortonworks.com/blog/hadoop-groupmapping-ldap-integration/"&gt;Hadoop Group Mapping&lt;/A&gt;) is that it is the Hiveserver2 process that gets the username and looks up the groups that user is a member of. It then passes the username and its group membership list to the Ranger Hive plugin (which runs in a thread in the Hiveserver2 process) and this uses the user details to check against a cache of the policies defined for Hive. It is important to understand that the Ranger Hive plugin does not communicate back to the Ranger Admin component during this authorization process. If it did it would be much slower and would make Ranger Admin a single point of failure.&lt;/P&gt;&lt;P&gt;When you synchronize your Active Directory users to Ranger using Ranger UserSync, this is &lt;STRONG&gt;only&lt;/STRONG&gt; to allow you to add the users and groups to policies in the Ranger Admin UI, it doesn't then make those users available on the cluster itself. You either need to integrate the OS with Active Directory or use the &lt;A href="http://hortonworks.com/blog/hadoop-groupmapping-ldap-integration/"&gt;Hadoop Group Mapping&lt;/A&gt; feature to make the users and groups available.&lt;/P&gt;</description>
      <pubDate>Wed, 28 Sep 2016 14:39:46 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171523#M133820</guid>
      <dc:creator>tstebbens</dc:creator>
      <dc:date>2016-09-28T14:39:46Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171524#M133821</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Configuring SSSD OS level did the trick as per your suggestions !
Thank you so much !&lt;/P&gt;</description>
      <pubDate>Wed, 05 Oct 2016 14:55:05 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171524#M133821</guid>
      <dc:creator>Adija1</dc:creator>
      <dc:date>2016-10-05T14:55:05Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171525#M133822</link>
      <description>&lt;P&gt;I have configured both ranger usersync and hadoop group mapping: &lt;/P&gt;&lt;P&gt;-the user X appears to be in group G in the ranger admin menu&lt;/P&gt;&lt;P&gt;-the 'hdfs group X' shows the user X to be in group G&lt;/P&gt;&lt;P&gt;-using 'groups X' the user X is not in group G (SSSD not configured) &lt;/P&gt;&lt;P&gt;Do I still need to configure SSSD to sync group G to make Ranger group policies work?&lt;/P&gt;</description>
      <pubDate>Tue, 24 Oct 2017 19:28:30 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/171525#M133822</guid>
      <dc:creator>kkwekkeboom</dc:creator>
      <dc:date>2017-10-24T19:28:30Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/316947#M226956</link>
      <description>&lt;P&gt;I have the same problem using the latest hdp sandbox.&lt;/P&gt;&lt;P&gt;The GROUP in Ranger is not working, only the users, even if in Ranger it is clearly shown the users/groups relationship, and turn the group/user mapping on for AD authentication/authorization.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The sandbox is configured in convoluted way, I couldn't figure out where the hive server 2 is running, in the virtual machine, or in some docker container? Could someone help?&lt;/P&gt;</description>
      <pubDate>Fri, 21 May 2021 21:46:32 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/316947#M226956</guid>
      <dc:creator>snowman</dc:creator>
      <dc:date>2021-05-21T21:46:32Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/316994#M226982</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cloudera.com/t5/user/viewprofilepage/user-id/88799"&gt;@snowman&lt;/a&gt;&amp;nbsp;as this is an older post, you would have a better chance of receiving a resolution by&lt;A href="“https://community.cloudera.com/t5/forums/postpage/board-id/Questions”" target="_blank"&gt; starting a new thread&lt;/A&gt;. This will also be an opportunity to provide details specific to your environment that could aid others in assisting you with a more accurate answer to your question. You can link this thread as a reference in your new post.&lt;/P&gt;</description>
      <pubDate>Mon, 24 May 2021 05:31:08 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/316994#M226982</guid>
      <dc:creator>VidyaSargur</dc:creator>
      <dc:date>2021-05-24T05:31:08Z</dc:date>
    </item>
    <item>
      <title>Re: Ranger Group permissions from LDAP - not working in Hive</title>
      <link>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/322044#M228655</link>
      <description>&lt;P&gt;In my case I had to restart HiveServer2 services on nodes after I had connected the hosts to the domain (using sssd service).&lt;/P&gt;</description>
      <pubDate>Wed, 04 Aug 2021 13:31:13 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/Ranger-Group-permissions-from-LDAP-not-working-in-Hive/m-p/322044#M228655</guid>
      <dc:creator>arturbrandys1</dc:creator>
      <dc:date>2021-08-04T13:31:13Z</dc:date>
    </item>
  </channel>
</rss>

