Member since
04-20-2023
2
Posts
0
Kudos Received
0
Solutions
04-20-2023
09:09 AM
PS. It seems I made some progress. I consulted this documentation https://docs.cloudera.com/HDPDocuments/HDP3/HDP-3.1.4/authorization-ranger/sec_authorization_ranger.pdf and made sure to include the rules from the hadoop.security.auth_to_local property as found in /etc/hadoop/conf. I can now test the connection in the HDFS service in Ranger and that tests ok. The error I get now though is 2023-04-20 18:05:27,074 ERROR util.PolicyRefresher (PolicyRefresher.java:loadPolicyfromPolicyAdmin(275)) - PolicyRefresher(serviceName=XYZ_hadoop): failed to refresh policies. Will continue to use last known version of policies (-1) com.sun.jersey.api.client.ClientHandlerException: java.lang.RuntimeException: java.lang.NullPointerException at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle(URLConnectionClientHandler.java:155) at com.sun.jersey.api.client.Client.handle(Client.java:652) at com.sun.jersey.api.client.WebResource.handle(WebResource.java:682) at com.sun.jersey.api.client.WebResource.access$200(WebResource.java:74) at com.sun.jersey.api.client.WebResource$Builder.get(WebResource.java:509) at org.apache.ranger.admin.client.RangerAdminRESTClient$3.run(RangerAdminRESTClient.java:140) at org.apache.ranger.admin.client.RangerAdminRESTClient$3.run(RangerAdminRESTClient.java:132) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:360) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1710) at org.apache.ranger.admin.client.RangerAdminRESTClient.getServicePoliciesIfUpdated(RangerAdminRESTClient.java:143) at org.apache.ranger.plugin.util.PolicyRefresher.loadPolicyfromPolicyAdmin(PolicyRefresher.java:251) at org.apache.ranger.plugin.util.PolicyRefresher.loadPolicy(PolicyRefresher.java:191) at org.apache.ranger.plugin.util.PolicyRefresher.run(PolicyRefresher.java:161) Caused by: java.lang.RuntimeException: java.lang.NullPointerException at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1488) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1474) at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:3018) at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:489) at com.sun.jersey.client.urlconnection.URLConnectionClientHandler._invoke(URLConnectionClientHandler.java:253) at com.sun.jersey.client.urlconnection.URLConnectionClientHandler.handle(URLConnectionClientHandler.java:153) ... 13 more Caused by: java.lang.NullPointerException at java.util.Base64$Encoder.encode(Base64.java:261) at java.util.Base64$Encoder.encodeToString(Base64.java:315) at sun.net.www.protocol.http.NegotiateAuthentication.setHeaders(NegotiateAuthentication.java:182) at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1731) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1474) at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:480) ... 15 more So it seems the NameNode still is not able to obtain the relevant information from Ranger.
... View more