HBase无法创建表的问题的解决
来源:互联网 发布:显示iphone在线软件 编辑:程序博客网 时间:2024/05/17 01:39
用HBase创建表时报如下错误:
hbase(main):001:0> create 't1', {NAME => 'f1'}, {NAME => 'f2'}, {NAME => 'f3'}
ERROR: org.apache.hadoop.hbase.PleaseHoldException: Master is initializingat org.apache.hadoop.hbase.master.HMaster.checkInitialized(HMaster.java:1869)
at org.apache.hadoop.hbase.master.HMaster.checkNamespaceManagerReady(HMaster.java:1874)
at org.apache.hadoop.hbase.master.HMaster.ensureNamespaceExists(HMaster.java:2067)
at org.apache.hadoop.hbase.master.HMaster.createTable(HMaster.java:1262)
at org.apache.hadoop.hbase.master.MasterRpcServices.createTable(MasterRpcServices.java:398)
at org.apache.hadoop.hbase.protobuf.generated.MasterProtos$MasterService$2.callBlockingMethod(MasterProtos.java:42436)
at org.apache.hadoop.hbase.ipc.RpcServer.call(RpcServer.java:2031)
at org.apache.hadoop.hbase.ipc.CallRunner.run(CallRunner.java:107)
at org.apache.hadoop.hbase.ipc.RpcExecutor.consumerLoop(RpcExecutor.java:130)
at org.apache.hadoop.hbase.ipc.RpcExecutor$1.run(RpcExecutor.java:107)
at java.lang.Thread.run(Thread.java:745)
Here is some help for this command:
Creates a table. Pass a table name, and a set of column family
specifications (at least one), and, optionally, table configuration.
Column specification can be a simple string (name), or a dictionary
(dictionaries are described below in main help output), necessarily
including NAME attribute.
Examples:
Create a table with namespace=ns1 and table qualifier=t1
hbase> create 'ns1:t1', {NAME => 'f1', VERSIONS => 5}
Create a table with namespace=default and table qualifier=t1
hbase> create 't1', {NAME => 'f1'}, {NAME => 'f2'}, {NAME => 'f3'}
hbase> # The above in shorthand would be the following:
hbase> create 't1', 'f1', 'f2', 'f3'
hbase> create 't1', {NAME => 'f1', VERSIONS => 1, TTL => 2592000, BLOCKCACHE => true}
hbase> create 't1', {NAME => 'f1', CONFIGURATION => {'hbase.hstore.blockingStoreFiles' => '10'}}
Table configuration options can be put at the end.
Examples:
hbase> create 'ns1:t1', 'f1', SPLITS => ['10', '20', '30', '40']
hbase> create 't1', 'f1', SPLITS => ['10', '20', '30', '40']
hbase> create 't1', 'f1', SPLITS_FILE => 'splits.txt', OWNER => 'johndoe'
hbase> create 't1', {NAME => 'f1', VERSIONS => 5}, METADATA => { 'mykey' => 'myvalue' }
hbase> # Optionally pre-split the table into NUMREGIONS, using
hbase> # SPLITALGO ("HexStringSplit", "UniformSplit" or classname)
hbase> create 't1', 'f1', {NUMREGIONS => 15, SPLITALGO => 'HexStringSplit'}
hbase> create 't1', 'f1', {NUMREGIONS => 15, SPLITALGO => 'HexStringSplit', REGION_REPLICATION => 2, CONFIGURATION => {'hbase.hregion.scan.loadColumnFamiliesOnDemand' => 'true'}}
You can also keep around a reference to the created table:
hbase> t1 = create 't1', 'f1'
我网上查找了下,有同学说:vi /etc/hosts 将
127.0.1.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
改成
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
即可,但是我的hosts中的文件是:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain5
::1 localhost localhost.localdomain localhost6 localhost6.localdomain7
我试着将它改成:
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
重启服务器后,用./start-hbase.sh 开启HMaster和HRegionServer,然后再./hbase shell ,发现也可以正常建表了。
- HBase无法创建表的问题的解决
- HBase Shell输入命令无法删除问题的解决技巧
- 解决mapreduce无法将数据批量导入hbase的问题
- 解决无法创建模拟器问题的方法
- 无法解决的问题
- 解决在IE下创建checkbox无法选中的问题
- 解决MMC无法创建管理单元的问题!
- 解决centos6 的virt-manager 无法创建network interface问题
- 教你解决无法创建虚拟拨号连接的问题
- SQLSERVER2008中无法创建数据库图表问题的解决
- 解决IOS8上无法创建同名删除相册的问题
- 解决sqoop1.4.4无法导入oracle的blob字段到hbase的问题
- HBase的退格键back键使用方法(解决无法使用退格键的问题)
- 解决Linux无法创建新用户和/home目录下无法创建新目录的问题
- 解决Hibernate4连接MySQL5.5数据库无法自动创建表的问题
- 解决Hibernate4连接MySQL5.5数据库无法自动创建表的问题
- 解决Hibernate4连接MySQL5.5数据库无法自动创建表的问题
- 【解决】hive与hbase表结合级联查询的问题
- 教你几个规避offer、三方和劳动合同违约金的方法
- iOS学习——数据库操作(使用FMDB)
- uva 10271 Chopsticks (DP)
- 使用ssh-keygen生存密钥对
- AndroidManifest.xml详解(上)
- HBase无法创建表的问题的解决
- Parity HDU 2700
- Android:Layout_weight的理解及遇到的问题
- 详解《高校毕业生就业协议书》及各种注意事项
- Java 并发编程之线程安全(随手笔记)
- appframework的左侧和右侧的api接口
- AndroidManifest.xml详解(下)
- 应届生大学毕业后后档案的三种去处及优缺点分析
- 用生产者消费者模式实现爬虫批量提交网页给搜索引擎