Monthly Archives: April 2017

  • 0

Error: org.apache.hadoop.hbase.security.AccessDeniedException: Insufficient permissions

If you try to connect to phoenix server from hbase or you do some service checks then if you are facing following error then do not worry,be relax as here you will find solution of this problem.

Error :

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/hdp/2.3.4.0-3485/phoenix/phoenix-4.4.0.2.3.4.0-3485-client.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/hdp/2.3.4.0-3485/hadoop/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
Error: org.apache.hadoop.hbase.security.AccessDeniedException: Insufficient permissions (user=saurkuma, scope=default:SYSTEM.CATALOG, params=[table=default:SYSTEM.CATALOG],action=CREATE)
at org.apache.hadoop.hbase.security.access.AccessController.requirePermission(AccessController.java:433)
at org.apache.hadoop.hbase.security.access.AccessController.preGetTableDescriptors(AccessController.java:2447)
at org.apache.hadoop.hbase.master.MasterCoprocessorHost$75.call(MasterCoprocessorHost.java:896)

org.apache.phoenix.exception.PhoenixIOException: org.apache.hadoop.hbase.security.AccessDeniedException: Insufficient permissions (user=saurkuma, scope=default:SYSTEM.CATALOG, params=[table=default:SYSTEM.CATALOG],action=CREATE)

Root cause : You are getting an Access control exception, because by default the user is not allowed to create a table.

Resolution: You should give either global level or namespace level privileges to the desired user so that that user can create a table.Out of the box, only the HBase user will have permissions to grant other permissions, so you have to log in as the hbase user.

[s0998dnz@m1.hdp22 ~]$ sudo su - hbase
Last login: Wed Apr 5 14:52:41 EDT 2017
[hbase@m1.hdp22 ~]$ hbase shell
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/hdp/2.3.4.0-3485/hadoop/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/hdp/2.3.4.0-3485/zookeeper/lib/slf4j-log4j12-1.6.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
HBase Shell; enter 'help<RETURN>' for list of supported commands.
Type "exit<RETURN>" to leave the HBase Shell
Version 1.1.2.2.3.4.0-3485, ra2b7fd38f4dcca6eb81f99b5d37b2ea3beeef09e, Wed Dec 16 03:49:28 UTC 2015
hbase(main):001:0> grant 'saurkuma', 'RWCA'
0 row(s) in 1.3310 seconds

hbase(main):002:0> grant 'ambari-qa', 'RWCA'
0 row(s) in 0.0830 seconds

Please feel free to give your valuable feedback or suggestion.


  • 0

Ambari is showing “Add Service Wizard in Progress” or “Move Master Wizard In Progress”

If you are using ambari 2.4.1 or 2.4.2 then you may see following message in your ambari page and you will not get any option to “Service Action” to restart or doing anything to any services.

Root Cause : If there are more than one Ambari Admin users present. Then if one of the admin user say “admin1” click on the “Actions” => “Add Service” in the ambari UI and does nothing. Then other logged in admin users will keep seeing the “Add Service Wizard in Progress” blinking bar in the ambari UI and the “service action” dropdown button will not be visible to them.It is captured by following jira also.

https://issues.apache.org/jira/browse/AMBARI-18932

Solution: Take ambari server backup and run below command from Ambari node.

curl -u admin:admin -i -H 'X-Requested-By: ambari' -X POST -d 
'{"wizard-data":"{\"userName\":\"admin\",\"controllerName\":\"addServiceController\"}"}' 
http://<ambari_server_name>.lowes.com:8080/api/v1/persist

or for “Move Master Wizard In Progress” message do the following :

curl -u admin:admin -i -H 'X-Requested-By: ambari' -X POST -d 
'{"wizard-data":"{\"userName\":\"admin\",\"controllerName\":\"moveMasterController\"}"}' 
http://&lt;ambari_server_name&gt;.lowes.com:8080/api/v1/persist

 

Note : Replace the following value as per your cluster config.
username = the user for which you are facing issue
Ambari_host = hostname of ambari node
controller_name = name of the controller for which you are making request.

 

There are few things to be aware of

1. This will resolve issue for the current logged in user but other users will have same issue of seeing “Add service wizard” in progress label unless the current logged in user logs off and logs in back at which user will be directed to add service wizard and then cancels add service wizard. After that this issue will go away for all other ambari users.

2. As said above after the execution of the API if current user signs out and signs back in then user will be directly redirected to add service wizard.

Please feel free to give your valuable feedback or suggestion.


  • 0

java.lang.IllegalArgumentException: stream exceeds limit [2,048]

When we run oozie job with SSH action and we use capture output then it may fail with following error.

java.lang.IllegalArgumentException: stream exceeds limit [2,048]
at org.apache.oozie.util.IOUtils.getReaderAsString(IOUtils.java:84)
at org.apache.oozie.servlet.CallbackServlet.doPost(CallbackServlet.java:117)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
at org.apache.oozie.servlet.JsonRestServlet.service(JsonRestServlet.java:304)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.oozie.servlet.HostnameFilter.doFilter(HostnameFilter.java:86)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:620)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:745)

Root Cause: It is because of insufficient value for oozie.servlet.CallbackServlet.max.data.len property in oozie-site.xml. In this case it was set to 2048, which wasn’t sufficient for the output.
Resolution:

Option 1: If you are using oozie version before 4.2 then add the following property in oozie-site.xml or add in custom oozie-site via Ambari. 

<property>
 <name>oozie.servlet.CallbackServlet.max.data.len</name>
 <value>16000</value>
</property>

Option 2: If you are using oozie version after 4.2 then add the following property in oozie-site.xml or add in custom oozie-site via Ambari.

<property>
<name>oozie.action.max.output.data</name>
<value>16000</value>
</property>

 

I hope it helped you,feel free to give your valuable feedback suggestions.