Support Questions
Find answers, ask questions, and share your expertise

Ranger audit not taking place on Hive

Rising Star

Hi,

I have upgraded my cluster to 2.4.2 recently

After the upgrade I see below errors in hiveserver2.log

2016-06-29 16:07:19,197 ERROR [Thread-9]: util.PolicyRefresher (PolicyRefresher.java:loadPolicyfromPolicyAdmin(228)) - PolicyRefresher(serviceName=mdcthdp01_hive): failed to refresh policies. Will continue to use last known version of policies (-1) com.sun.jersey.api.client.ClientHandlerException: java.net.SocketException: Broken pipe at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle(URLConnectionClientHandler.java:149) at com.sun.jersey.api.client.Client.handle(Client.java:648) at com.sun.jersey.api.client.WebResource.handle(WebResource.java:670) at com.sun.jersey.api.client.WebResource.access$200(WebResource.java:74) at com.sun.jersey.api.client.WebResource$Builder.get(WebResource.java:503) at org.apache.ranger.admin.client.RangerAdminRESTClient.getServicePoliciesIfUpdated(RangerAdminRESTClient.java:73) at org.apache.ranger.plugin.util.PolicyRefresher.loadPolicyfromPolicyAdmin(PolicyRefresher.java:205) at org.apache.ranger.plugin.util.PolicyRefresher.loadPolicy(PolicyRefresher.java:175) at org.apache.ranger.plugin.util.PolicyRefresher.run(PolicyRefresher.java:154) Caused by: java.net.SocketException: Broken pipe Due to this, I could not see any databases in Hive when I connect via beeline

Also, the ranger audit not taking place on Hive.

If I disable Ranger-Hive plugin then I am able to view database information from beeline but if plugin is enabled then the above errors appears.

Accessing Hive via beeline

Transaction isolation: TRANSACTION_REPEATABLE_READ 0: jdbc:hive2://<hiveserver>:1000> show databases; +----------------+--+ | database_name | +----------------+--+ +----------------+--+ No rows selected (0.142 seconds) 0: jdbc:hive2://hiveserver:1000>

Please help me on this

3 REPLIES 3

Hi @Venkata Sridhar Gangavarapu

What version of HDP did you upgrade from?

Rising Star

After upgaded from HDp-2.2.4-.2, I don't see below file getting upaded

Upgrade from HDP-2.3. Earlier it was HDP-2.2.4.2. This problems was there even when it was upgraded from HDP-2.2.4.2 to HDP-2.3

I see that /usr/hdp/2.4.0.0-169/ranger-hive-plugin/install.properties is not populated with config values like POLICY_MGR_URL and DB properties.

Rising Star

Any help on this?