hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "lagend" <lag...@foxmail.com>
Subject Default hbase.ipc.server.callqueue.scan.ratio is 0, is this right?
Date Mon, 18 May 2015 10:53:26 GMT
When I start a new cluster, package is hbase-1.0.1-bin.tar.gz, error occurs:
2015-05-18 17:21:09,514 ERROR [main] regionserver.HRegionServerCommandLine: Region server
exiting
java.lang.RuntimeException: Failed construction of Regionserver: class org.apache.hadoop.hbase.regionserver.HRegionServer
        at org.apache.hadoop.hbase.regionserver.HRegionServer.constructRegionServer(HRegionServer.java:2496)
        at org.apache.hadoop.hbase.regionserver.HRegionServerCommandLine.start(HRegionServerCommandLine.java:64)
        at org.apache.hadoop.hbase.regionserver.HRegionServerCommandLine.run(HRegionServerCommandLine.java:87)
        at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
        at org.apache.hadoop.hbase.util.ServerCommandLine.doMain(ServerCommandLine.java:126)
        at org.apache.hadoop.hbase.regionserver.HRegionServer.main(HRegionServer.java:2511)
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
        at org.apache.hadoop.hbase.regionserver.HRegionServer.constructRegionServer(HRegionServer.java:2494)
        ... 5 more
Caused by: java.lang.IllegalArgumentException: Queue size is <= 0, must be at least 1
        at com.google.common.base.Preconditions.checkArgument(Preconditions.java:92)
        at org.apache.hadoop.hbase.ipc.RpcExecutor.getBalancer(RpcExecutor.java:177)
        at org.apache.hadoop.hbase.ipc.RWQueueRpcExecutor.<init>(RWQueueRpcExecutor.java:133)
        at org.apache.hadoop.hbase.ipc.RWQueueRpcExecutor.<init>(RWQueueRpcExecutor.java:95)
        at org.apache.hadoop.hbase.ipc.SimpleRpcScheduler.<init>(SimpleRpcScheduler.java:134)
        at org.apache.hadoop.hbase.regionserver.SimpleRpcSchedulerFactory.create(SimpleRpcSchedulerFactory.java:46)
        at org.apache.hadoop.hbase.regionserver.RSRpcServices.<init>(RSRpcServices.java:792)
        at org.apache.hadoop.hbase.regionserver.HRegionServer.createRpcServices(HRegionServer.java:575)
        at org.apache.hadoop.hbase.regionserver.HRegionServer.<init>(HRegionServer.java:492)


I found the probably reason:
in hbase-default.xml, hbase.ipc.server.callqueue.read.ratio default value is 0


hbase/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/SimpleRpcScheduler#init
line 44.		public static final String CALL_QUEUE_SCAN_SHARE_CONF_KEY = "hbase.ipc.server.callqueue.scan.ratio";
line 123.	float callqScanShare = conf.getFloat(CALL_QUEUE_SCAN_SHARE_CONF_KEY, 0);	// default
is 0
line 134.	callExecutor = new RWQueueRpcExecutor("RW.default", handlerCount, numCallQueues,
            callqReadShare, callqScanShare, maxQueueLength, conf, abortable,
            BoundedPriorityBlockingQueue.class, callPriority);
 
hbase/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RWQueueRpcExecutor#init
line 116.	int numScanQueues = Math.max(0, (int)Math.floor(numReadQueues * scanShare)); //
numScanQueues is 0
line 133.    this.scanBalancer = getBalancer(numScanQueues);




hbase/hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcExecutor#getBalancer
line 177.    Preconditions.checkArgument(queueSize > 0, "Queue size is <= 0, must be
at least 1");
the queueSize is 0, so, throw IllegalArgumentEception:
Caused by: java.lang.IllegalArgumentException: Queue size is <= 0, must be at least 1


my answer is:
this config, hbase.ipc.server.callqueue.scan.ratio, can be '0'? or other reason cause this
fault?
Thanks
Mime
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message