/usr/lib/jvm/java-7-openjdk-amd64/bin/java -Didea.launcher.port=7538 -Didea.launcher.bin.path=/usr/local/idea-IC-139.225.3/bin -Dfile.encoding=UTF-8 -classpath /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/rhino.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/compilefontconfig.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/management-agent.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/resources.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/jsse.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/javazic.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/rt.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/charsets.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/jce.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/localedata.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/pulse-java.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/dnsns.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/zipfs.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/java-atk-wrapper.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/sunjce_provider.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/sunpkcs11.jar:/root/IdeaProjects/Test/out/production/HbaseTest:/usr/local/hbase-0.90.3/hbase-0.90.3.jar:/usr/local/hbase-0.90.3/lib/activation-1.1.jar:/usr/local/hbase-0.90.3/lib/asm-3.1.jar:/usr/local/hbase-0.90.3/lib/avro-1.3.3.jar:/usr/local/hbase-0.90.3/lib/commons-cli-1.2.jar:/usr/local/hbase-0.90.3/lib/commons-codec-1.4.jar:/usr/local/hbase-0.90.3/lib/commons-el-1.0.jar:/usr/local/hbase-0.90.3/lib/commons-httpclient-3.1.jar:/usr/local/hbase-0.90.3/lib/commons-lang-2.5.jar:/usr/local/hbase-0.90.3/lib/commons-logging-1.1.1.jar:/usr/local/hbase-0.90.3/lib/commons-net-1.4.1.jar:/usr/local/hbase-0.90.3/lib/core-3.1.1.jar:/usr/local/hbase-0.90.3/lib/guava-r06.jar:/usr/local/hbase-0.90.3/lib/hadoop-0.20.2-core.jar:/usr/local/hbase-0.90.3/lib/jackson-core-asl-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jackson-jaxrs-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jackson-mapper-asl-1.4.2.jar:/usr/local/hbase-0.90.3/lib/jackson-xc-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jasper-compiler-5.5.23.jar:/usr/local/hbase-0.90.3/lib/jasper-runtime-5.5.23.jar:/usr/local/hbase-0.90.3/lib/jaxb-api-2.1.jar:/usr/local/hbase-0.90.3/lib/jaxb-impl-2.1.12.jar:/usr/local/hbase-0.90.3/lib/jersey-core-1.4.jar:/usr/local/hbase-0.90.3/lib/jersey-json-1.4.jar:/usr/local/hbase-0.90.3/lib/jersey-server-1.4.jar:/usr/local/hbase-0.90.3/lib/jettison-1.1.jar:/usr/local/hbase-0.90.3/lib/jetty-6.1.26.jar:/usr/local/hbase-0.90.3/lib/jetty-util-6.1.26.jar:/usr/local/hbase-0.90.3/lib/jruby-complete-1.6.0.jar:/usr/local/hbase-0.90.3/lib/jsp-2.1-6.1.14.jar:/usr/local/hbase-0.90.3/lib/jsp-api-2.1-6.1.14.jar:/usr/local/hbase-0.90.3/lib/jsr311-api-1.1.1.jar:/usr/local/hbase-0.90.3/lib/log4j-1.2.16.jar:/usr/local/hbase-0.90.3/lib/protobuf-java-2.3.0.jar:/usr/local/hbase-0.90.3/lib/servlet-api-2.5-6.1.14.jar:/usr/local/hbase-0.90.3/lib/slf4j-api-1.5.8.jar:/usr/local/hbase-0.90.3/lib/slf4j-log4j12-1.5.8.jar:/usr/local/hbase-0.90.3/lib/stax-api-1.0.1.jar:/usr/local/hbase-0.90.3/lib/thrift-0.2.0.jar:/usr/local/hbase-0.90.3/lib/xmlenc-0.52.jar:/usr/local/hbase-0.90.3/lib/zookeeper-3.3.2.jar:/usr/local/idea-IC-139.225.3/lib/idea_rt.jar com.intellij.rt.execution.application.AppMain PutEcample
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:zookeeper.version=3.3.2-1031432, built on 11/05/2010 05:32 GMT
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:host.name=localhost
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.version=1.7.0_65
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.vendor=Oracle Corporation
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.home=/usr/lib/jvm/java-7-openjdk-amd64/jre
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.class.path=/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/rhino.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/compilefontconfig.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/management-agent.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/resources.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/jsse.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/javazic.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/rt.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/charsets.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/jce.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/localedata.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/pulse-java.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/dnsns.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/zipfs.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/java-atk-wrapper.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/sunjce_provider.jar:/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/ext/sunpkcs11.jar:/root/IdeaProjects/Test/out/production/HbaseTest:/usr/local/hbase-0.90.3/hbase-0.90.3.jar:/usr/local/hbase-0.90.3/lib/activation-1.1.jar:/usr/local/hbase-0.90.3/lib/asm-3.1.jar:/usr/local/hbase-0.90.3/lib/avro-1.3.3.jar:/usr/local/hbase-0.90.3/lib/commons-cli-1.2.jar:/usr/local/hbase-0.90.3/lib/commons-codec-1.4.jar:/usr/local/hbase-0.90.3/lib/commons-el-1.0.jar:/usr/local/hbase-0.90.3/lib/commons-httpclient-3.1.jar:/usr/local/hbase-0.90.3/lib/commons-lang-2.5.jar:/usr/local/hbase-0.90.3/lib/commons-logging-1.1.1.jar:/usr/local/hbase-0.90.3/lib/commons-net-1.4.1.jar:/usr/local/hbase-0.90.3/lib/core-3.1.1.jar:/usr/local/hbase-0.90.3/lib/guava-r06.jar:/usr/local/hbase-0.90.3/lib/hadoop-0.20.2-core.jar:/usr/local/hbase-0.90.3/lib/jackson-core-asl-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jackson-jaxrs-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jackson-mapper-asl-1.4.2.jar:/usr/local/hbase-0.90.3/lib/jackson-xc-1.5.5.jar:/usr/local/hbase-0.90.3/lib/jasper-compiler-5.5.23.jar:/usr/local/hbase-0.90.3/lib/jasper-runtime-5.5.23.jar:/usr/local/hbase-0.90.3/lib/jaxb-api-2.1.jar:/usr/local/hbase-0.90.3/lib/jaxb-impl-2.1.12.jar:/usr/local/hbase-0.90.3/lib/jersey-core-1.4.jar:/usr/local/hbase-0.90.3/lib/jersey-json-1.4.jar:/usr/local/hbase-0.90.3/lib/jersey-server-1.4.jar:/usr/local/hbase-0.90.3/lib/jettison-1.1.jar:/usr/local/hbase-0.90.3/lib/jetty-6.1.26.jar:/usr/local/hbase-0.90.3/lib/jetty-util-6.1.26.jar:/usr/local/hbase-0.90.3/lib/jruby-complete-1.6.0.jar:/usr/local/hbase-0.90.3/lib/jsp-2.1-6.1.14.jar:/usr/local/hbase-0.90.3/lib/jsp-api-2.1-6.1.14.jar:/usr/local/hbase-0.90.3/lib/jsr311-api-1.1.1.jar:/usr/local/hbase-0.90.3/lib/log4j-1.2.16.jar:/usr/local/hbase-0.90.3/lib/protobuf-java-2.3.0.jar:/usr/local/hbase-0.90.3/lib/servlet-api-2.5-6.1.14.jar:/usr/local/hbase-0.90.3/lib/slf4j-api-1.5.8.jar:/usr/local/hbase-0.90.3/lib/slf4j-log4j12-1.5.8.jar:/usr/local/hbase-0.90.3/lib/stax-api-1.0.1.jar:/usr/local/hbase-0.90.3/lib/thrift-0.2.0.jar:/usr/local/hbase-0.90.3/lib/xmlenc-0.52.jar:/usr/local/hbase-0.90.3/lib/zookeeper-3.3.2.jar:/usr/local/idea-IC-139.225.3/lib/idea_rt.jar
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.library.path=/usr/local/idea-IC-139.225.3/bin::/usr/java/packages/lib/amd64:/usr/lib/x86_64-linux-gnu/jni:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/usr/lib/jni:/lib:/usr/lib
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.io.tmpdir=/tmp
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:java.compiler=<NA>
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:os.name=Linux
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:os.arch=amd64
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:os.version=3.8.0-44-generic
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:user.name=root
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:user.home=/root
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Client environment:user.dir=/root/IdeaProjects/Test
15/01/04 11:18:17 INFO zookeeper.ZooKeeper: Initiating client connection, connectString=localhost:2181 sessionTimeout=180000 watcher=hconnection
15/01/04 11:18:17 INFO zookeeper.ClientCnxn: Opening socket connection to server localhost/127.0.0.1:2181
15/01/04 11:18:17 INFO zookeeper.ClientCnxn: Socket connection established to localhost/127.0.0.1:2181, initiating session
15/01/04 11:18:17 INFO zookeeper.ClientCnxn: Session establishment complete on server localhost/127.0.0.1:2181, sessionid = 0x14ab2ae95630011, negotiated timeout = 40000
15/01/04 11:18:17 WARN client.HConnectionManager$HConnectionImplementation: Encountered problems when prefetch META table:
org.apache.hadoop.hbase.TableNotFoundException: Cannot find row in .META. for table: testtable9, row=testtable9,,99999999999999
at org.apache.hadoop.hbase.client.MetaScanner.metaScan(MetaScanner.java:136)
at org.apache.hadoop.hbase.client.MetaScanner.metaScan(MetaScanner.java:95)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.prefetchRegionCache(HConnectionManager.java:648)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegionInMeta(HConnectionManager.java:702)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:593)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:558)
at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:172)
at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:146)
at PutEcample.main(PutEcample.java:21)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)
Exception in thread "main" org.apache.hadoop.hbase.TableNotFoundException: testtable9
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegionInMeta(HConnectionManager.java:724)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:593)
at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.locateRegion(HConnectionManager.java:558)
at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:172)
at org.apache.hadoop.hbase.client.HTable.<init>(HTable.java:146)
at PutEcample.main(PutEcample.java:21)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:134)
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.hbase.HBaseConfiguration;
import org.apache.hadoop.hbase.HColumnDescriptor;
import org.apache.hadoop.hbase.HTableDescriptor;
import org.apache.hadoop.hbase.client.HBaseAdmin;
import org.apache.hadoop.hbase.client.HTable;
import org.apache.hadoop.hbase.client.Put;
import org.apache.hadoop.hbase.util.Bytes; import java.io.IOException; public class PutEcample {
public static void main(String[] args) throws IOException{
Configuration conf= HBaseConfiguration.create();
HBaseAdmin hbase=new HBaseAdmin(conf);
HTableDescriptor desc=new HTableDescriptor("testtable1");
HColumnDescriptor colfam1=new HColumnDescriptor("colfam1".getBytes());
desc.addFamily(colfam1);
hbase.createTable(desc);
HTable table=new HTable(conf,"testtable1");
Put put=new Put(Bytes.toBytes("row1"));
put.add(Bytes.toBytes("colfam1"),Bytes.toBytes("qual1"),Bytes.toBytes("val1"));
//Put.add(Bytes.toBytes("colfam1"),Bytes.toBytes("qual2"),Bytes.toBytes("val2"));
table.put(put);
System.out.println("ok");
}
}
使用hbase的api创建表时要先创建表的结构。
使用hbase的api创建表时出现的异常的更多相关文章
-
oracle与mysql创建表时的区别
oracle创建表时,不支持在建表时同时增加字段注释.故采用以下方式: #创建表CREATE TABLE predict_data as ( id integer ), mid ), time dat ...
-
Oracle创建表时涉及的参数解析
1.oracle pctfree和pctused详解 http://www.cnblogs.com/linjiqin/archive/2012/01/16/2323320.html http:// ...
-
mysql创建表时,设置timestamp DEFAULT NULL报错1067 - Invalid default value for &#39;updated_at&#39;
问题背景: 线上的linux服务器上的mysql服务器中导出数据库的结构.想要在本地创建一个测试版本 导出后再本地mysql上运行却报错 1067 - Invalid default value ...
-
Mysql 创建表时错误:Tablespace for table `tablexx` exists. Please DISCARD the tablespace before IMPORT.
在本地的一个数据库创建表时意外的出现了以下错误,说是表已经存在了 但通过desc 查看表信息时又说表不存在 在本地系统搜索表名却发现一个.ibd文件[InnoDB File] 在删除了该.ibd文件文 ...
-
mysql 创建表时注意事项
mysql 创建表时注意事项 mysql 想必大家都不会陌生吧 是我学习中第一个接触的的数据库 已学习就很快上手的 这是一个关系型数据库 不懂什么是关系型数据库 啊哈哈哈 现在知道啦 因 ...
-
MySQL创建表时加入的约束以及外键约束的的意义
1,创建表时加入的约束 a) 非空约束,not null b) 唯一约束,unique c) 主键约束,primary key d) 外键约束,foreign key 1,非空约束,针对某个字段设置其 ...
-
MySQL 创建表时,设置时间字段自己主动插入当前时间
MySQL 创建表时,设置时间字段自己主动插入当前时间 DROP TABLE IF EXISTS `CONTENT`; CREATE TABLE `CONTENT` ( `ID` char(20) N ...
-
Oracle创建表时Storage参数具体含义
本文通过图表和实例的阐述在Oracle数据库创建新表时Storage的参数具体含义. 可用于:表空间.回滚段.表.索引.分区.快照.快照日志 参数名称 缺省值 最小值 最大值 说明 INITIAL 5 ...
-
【oracle】关于创建表时用default指定默认值的坑
刚开始学create table的时候没注意,学到后面发现可以指定默认值.于是写了如下语句: 当我查询的时候发现,查出来的结果是这样的.. 很纳闷有没有,我明明指定默认值了呀,为什么创建出来的表还是空 ...
随机推荐
-
微软*工具箱-Sysinternals Suite
工具包由来 Sysinternals Suite是微软发布的一套非常强大的免费工具程序集,一共包括74个windows工具.Sysinternals是Winternals公司提供的免费工具,Winte ...
-
Linux下压缩与解压命令tar
Linux下常见压缩文件的扩展名 *.gz:gzip压缩的: *.bz2:bzip2压缩的: *.tar:tar程序打包但没有压缩的: *.tar.gz:打包后并经过gzip压缩的: *.tar.bz ...
-
Windows平台下的读写锁
Windows平台下的读写锁简单介绍Windows平台下的读写锁以及实现.背景介绍Windows在Vista 和 Server2008以后才开始提供读写锁API,即SRW系列函数(Initialize ...
-
C#读写文件总结
1.使用FileStream读写文件 文件头: using System; using System.Collections.Generic; using System.Text; using ...
-
html 中根据后台参数显示 相应的样式 EL表达式
<li><a class="${return_product_statu==-1||return_product_statu==null?'switch_xz':'none ...
-
[转载] 谷歌技术";三宝";之谷歌文件系统
转载自http://blog.csdn.net/opennaive/article/details/7483523 题记:初学分布式文件系统,写篇博客加深点印象.GFS的特点是使用一堆廉价的商用计算机 ...
-
Oracle学习笔记三
一.创建表空间 表空间是ORACLE数据库的逻辑单元.数据库--表空间 一个表空间可以与多个数据文件(物理结构)关联一个数据库下可以建立多个表空间,一个表空间可以建立多个用户个用户下可以建立多个表. ...
-
shelly - HYMN TO INTELLECTUAL BEAUTY
HYMN TO INTELLECTUAL BEAUTY III No voice from some sublimer world hath ever To sage or poet these r ...
-
NPM和Yarn添加淘宝镜像
NPM设置淘宝镜像 1.查询当前配置的镜像 npm get registry > https://registry.npmjs.org/ 设置成淘宝镜像 npm config set regis ...
-
自定义Asp.net core——日志记录
本文我将演示如何定制日志记录.默认的日志记录仅仅向控制台或者debug窗口输出日志,这样可以满足一些情况,但是你可能还需要把日志记录到一个磁盘文件或者数据库,或者你想为记录额外的信息.这样的场景你就需 ...