那我看看 Hbase Shell 怎么样吧! 结果:
- hbase(main):002:0> list
- TABLE
- COLUMNSTABLE
- PERSONALINFO
- configtable
- 3 row(s) in 0.1230 seconds
-
- hbase(main):002:0> scan 'configtable'
- ROW COLUMN+CELL
-
- ERROR: org.apache.hadoop.hbase.client.NoServerForRegionException: Unable to find region for configtable,,99999999999999 after 7 tries.
-
- Here is some help for this command:
- Scan a table; pass table name and optionally a dictionary of scanner
- specifications. Scanner specifications may include one or more of:
- TIMERANGE, FILTER, LIMIT, STARTROW, STOPROW, TIMESTAMP, MAXLENGTH,
- or COLUMNS, CACHE
-
- If no columns are specified, all columns will be scanned.
- To scan all members of a column family, leave the qualifier empty as in
- 'col_family:'.
-
- The filter can be specified in two ways:
- 1. Using a filterString - more information on this is available in the
- Filter Language document attached to the HBASE-4176 JIRA
- 2. Using the entire package name of the filter.
-
- Some examples:
-
- hbase> scan '.META.'
- hbase> scan '.META.', {COLUMNS => 'info:regioninfo'}
- hbase> scan 't1', {COLUMNS => ['c1', 'c2'], LIMIT => 10, STARTROW => 'xyz'}
- hbase> scan 't1', {COLUMNS => 'c1', TIMERANGE => [1303668804, 1303668904]}
- hbase> scan 't1', {FILTER => "(PrefixFilter ('row2') AND (QualifierFilter (>=, 'binary:xyz'))) AND (TimestampsFilter ( 123, 456))"}
- hbase> scan 't1', {FILTER => org.apache.hadoop.hbase.filter.ColumnPaginationFilter.new(1, 0)}
-
- For experts, there is an additional option -- CACHE_BLOCKS -- which
- switches block caching for the scanner on (true) or off (false). By
- default it is enabled. Examples:
-
- hbase> scan 't1', {COLUMNS => ['c1', 'c2'], CACHE_BLOCKS => false}
-
- Also for experts, there is an advanced option -- RAW -- which instructs the
- scanner to return all cells (including delete markers and uncollected deleted
- cells). This option cannot be combined with requesting specific COLUMNS.
- Disabled by default. Example:
-
- hbase> scan 't1', {RAW => true, VERSIONS => 10}
复制代码
发现 Hbase 集群启动了,但 怎么也不像一个集群啊! 继续看日志:
- 2015-04-13 17:00:38,737 INFO org.apache.hadoop.hbase.zookeeper.RecoverableZooKeeper: The identifier of this process is 3820@Master.Hadoop
- 2015-04-13 17:00:38,738 INFO org.apache.zookeeper.ClientCnxn: Opening socket connection to server Slave1.Hadoop/192.168.1.3:2181. Will not attempt to authenticate using SASL (unknown error)
- 2015-04-13 17:00:38,738 INFO org.apache.zookeeper.ClientCnxn: Socket connection established to Slave1.Hadoop/192.168.1.3:2181, initiating session
- 2015-04-13 17:00:38,755 WARN org.apache.zookeeper.ClientCnxnSocket: Connected to an old server; r-o mode will be unavailable
- 2015-04-13 17:00:38,755 INFO org.apache.zookeeper.ClientCnxn: Session establishment complete on server Slave1.Hadoop/192.168.1.3:2181, sessionid = 0x24cb1fcf74e0004, negotiated timeout = 40000
- 2015-04-13 17:00:39,178 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 267374 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:40,680 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 268876 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:42,182 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 270378 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:43,684 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 271880 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:45,186 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 273382 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:46,688 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 274884 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:48,190 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 276386 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:49,692 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 277888 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:51,194 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 279390 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:52,696 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 280892 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:54,199 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 282395 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:55,701 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 283897 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
- 2015-04-13 17:00:57,203 INFO org.apache.hadoop.hbase.master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 285399 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms.
-
-
- HMaster 正常启动后,成了这个样子。。。。。。
复制代码
HRegionServer 日志 是这个样子的:
- 2015-04-13 16:10:03,292 INFO org.apache.hadoop.hbase.regionserver.HRegionServer: Attempting connect to Master server at localhost,60000,1428912179738
- 2015-04-13 16:11:03,326 WARN org.apache.hadoop.hbase.regionserver.HRegionServer: Unable to connect to master. Retrying. Error was:
- java.net.ConnectException: 拒绝连接
- at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
- at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:739)
- at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)
- at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:656)
- at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.setupConnection(HBaseClient.java:390)
- at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.setupIOstreams(HBaseClient.java:436)
- at org.apache.hadoop.hbase.ipc.HBaseClient.getConnection(HBaseClient.java:1124)
- at org.apache.hadoop.hbase.ipc.HBaseClient.call(HBaseClient.java:974)
- at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:86)
- at com.sun.proxy.$Proxy8.getProtocolVersion(Unknown Source)
- at org.apache.hadoop.hbase.ipc.WritableRpcEngine.getProxy(WritableRpcEngine.java:138)
- at org.apache.hadoop.hbase.ipc.HBaseRPC.waitForProxy(HBaseRPC.java:208)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.getMaster(HRegionServer.java:1995)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.reportForDuty(HRegionServer.java:2041)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.run(HRegionServer.java:736)
- at java.lang.Thread.run(Thread.java:745)
- 2015-04-13 16:11:03,527 INFO org.apache.hadoop.hbase.regionserver.HRegionServer: Attempting connect to Master server at localhost,60000,1428912179738
- 2015-04-13 16:12:03,562 WARN org.apache.hadoop.hbase.regionserver.HRegionServer: Unable to connect to master. Retrying. Error was:
- org.apache.hadoop.hbase.ipc.HBaseClient$FailedServerException: This server is in the failed servers list: localhost/192.168.1.3:60000
- at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.setupIOstreams(HBaseClient.java:425)
- at org.apache.hadoop.hbase.ipc.HBaseClient.getConnection(HBaseClient.java:1124)
- at org.apache.hadoop.hbase.ipc.HBaseClient.call(HBaseClient.java:974)
- at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:86)
- at com.sun.proxy.$Proxy8.getProtocolVersion(Unknown Source)
- at org.apache.hadoop.hbase.ipc.WritableRpcEngine.getProxy(WritableRpcEngine.java:138)
- at org.apache.hadoop.hbase.ipc.HBaseRPC.waitForProxy(HBaseRPC.java:208)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.getMaster(HRegionServer.java:1995)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.reportForDuty(HRegionServer.java:2041)
- at org.apache.hadoop.hbase.regionserver.HRegionServer.run(HRegionServer.java:736)
- at java.lang.Thread.run(Thread.java:745)
复制代码
试过恢复 .meta. 然后行不通。
- hbase hbck
- 1.重新修复hbase meta表
- hbase hbck -fixMeta
- 2.重新将hbase meta表分给regionserver
- hbase hbck -fixAssignments
-
- 但是一直 报提示:
-
- <div align="left">15/04/13 18:13:31 INFO zookeeper.ZooKeeper: Initiating client connection, connec tString=192.168.1.4:2181,192.168.1.3:2181,192.168.1.5:2181 sessionTimeout=180000 watcher=hconnection
- 15/04/13 18:13:31 INFO zookeeper.RecoverableZooKeeper: The identifier of this pr ocess is 5476@Master.Hadoop
- 15/04/13 18:13:31 INFO zookeeper.ClientCnxn: Opening socket connection to server Slave2.Hadoop/192.168.1.4:2181. Will not attempt to authenticate using SASL (un known error)
- 15/04/13 18:13:31 INFO zookeeper.ClientCnxn: Socket connection established to Sl ave2.Hadoop/192.168.1.4:2181, initiating session
- 15/04/13 18:13:31 WARN zookeeper.ClientCnxnSocket: Connected to an old server; r -o mode will be unavailable
- 15/04/13 18:13:31 INFO zookeeper.ClientCnxn: Session establishment complete on s erver Slave2.Hadoop/192.168.1.4:2181, sessionid = 0x34cb1fcf83e0000, negotiated timeout = 40000
- <font color="Red">15/04/13 18:14:31 DEBUG client.HConnectionManager$HConnectionImplementation: Looked up root region location, connection=org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation@735404c6; serverName=
- </font></div>
复制代码
还请大神,指点一二!! 小弟不胜感激, 现在这里谢谢,谢谢