Hbase深入学习(二) 安装hbase

This guidedescribes setup of a standalone hbase instance that uses the local filesystem. Itleads you through creating a table, inserting rows via the hbase shell, andthen cleaning up and shutting down your standalone hbase instance.

Uncompress thehbase download file, before starting it, edit conf/hbase-site.xml, the file youwrite your site-specific configurations into. Set hbase.rootdir, the directoryhbase writes data to, and hbase.zookeeper.property.datadir, the director zookeeperwrites its data too:

<?xmlversion="1.0"?>

<?xml-stylesheettype="text/xsl" href="configuration.xsl"?>

<configuration>

<property>

<name>hbase.rootdir</name>

<value>file:///DIRECTORY/hbase</value>

</property>

<property>

<name>hbase.zookeeper.property.dataDir</name>

<value>/DIRECTORY/zookeeper</value>

</property>

</configuration>

Replace DIRECTORYin the above with the path to the directory you would have HBase and ZooKeeperwrite their data. By default, hbase.rootdir is set to /tmp/hbase-${user.name}and similarly so for the default ZooKeeper data location which means you'lllose all your data whenever your server reboots unless you change it (Mostoperating systems clear /tmp on restart).

Edit hbase-config.sh,export JAVA_HOME=/export/opt/jrockit/6.0_14R27.6.5l64

$ ./start-hbase.sh

[WARN ]-XX:OnOutOfMemoryError=kill -9 %p is not a valid VM option. Ignoring

[WARN ]-XX:+UseConcMarkSweepGC is not a valid VM option. Ignoring

starting master,logging to /home/yj70978/hbase-0.94.11/bin/../logs/hbase-yj70978-master-retailvm1d.out

[WARN ]-XX:OnOutOfMemoryError=kill -9 %p is not a valid VM option. Ignoring

[WARN ]-XX:+UseConcMarkSweepGC is not a valid VM option. Ignoring

$ ps -ef | grephbase

yj70978  25111    1 42 03:33 pts/4    00:00:06/export/opt/jrockit/6.0_14R27.6.5l64/bin/java -XX:OnOutOfMemoryError=kill -9 %p-Xmx1000m -XX:+UseConcMarkSweepGC-Dhbase.log.dir=/home/yj70978/hbase-0.94.11/bin/../logs-Dhbase.log.file=hbase-yj70978-master-retailvm1d.log -Dhbase.home.dir=/home/yj70978/hbase-0.94.11/bin/..-Dhbase.id.str=yj70978 -Dhbase.root.logger=INFO,DRFA-Djava.library.path=/home/yj70978/hbase-0.94.11/bin/../lib/native/Linux-amd64-64-Dhbase.security.logger=INFO,DRFAS -classpath /home/yj70978/hbase-0.94.11/bin/../conf:/export/opt/jrockit/6.0_14R27.6.5l64/lib/tools.jar:/home/yj70978/hbase-0.94.11/bin/..:/home/yj70978/hbase-0.94.11/bin/../hbase-0.94.11.jar:/home/yj70978/hbase-0.94.11/bin/../hbase-0.94.11-tests.jar:/home/yj70978/hbase-0.94.11/bin/../lib/activation-1.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/asm-3.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/avro-1.5.3.jar:/home/yj70978/hbase-0.94.11/bin/../lib/avro-ipc-1.5.3.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-beanutils-1.7.0.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-beanutils-core-1.8.0.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-cli-1.2.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-codec-1.4.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-collections-3.2.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-configuration-1.6.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-digester-1.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-el-1.0.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-httpclient-3.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-io-2.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-lang-2.5.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-logging-1.1.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-math-2.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/commons-net-1.4.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/core-3.1.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/guava-11.0.2.jar:/home/yj70978/hbase-0.94.11/bin/../lib/hadoop-core-1.0.4.jar:/home/yj70978/hbase-0.94.11/bin/../lib/high-scale-lib-1.1.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/httpclient-4.1.2.jar:/home/yj70978/hbase-0.94.11/bin/../lib/httpcore-4.1.3.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jackson-core-asl-1.8.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jackson-jaxrs-1.8.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jackson-mapper-asl-1.8.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jackson-xc-1.8.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jamon-runtime-2.3.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jasper-compiler-5.5.23.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jasper-runtime-5.5.23.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jaxb-api-2.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jaxb-impl-2.2.3-1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jersey-core-1.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jersey-json-1.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jersey-server-1.8.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jettison-1.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jetty-6.1.26.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jetty-util-6.1.26.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jruby-complete-1.6.5.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jsp-2.1-6.1.14.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jsp-api-2.1-6.1.14.jar:/home/yj70978/hbase-0.94.11/bin/../lib/jsr305-1.3.9.jar:/home/yj70978/hbase-0.94.11/bin/../lib/junit-4.10-HBASE-1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/libthrift-0.8.0.jar:/home/yj70978/hbase-0.94.11/bin/../lib/log4j-1.2.16.jar:/home/yj70978/hbase-0.94.11/bin/../lib/metrics-core-2.1.2.jar:/home/yj70978/hbase-0.94.11/bin/../lib/netty-3.2.4.Final.jar:/home/yj70978/hbase-0.94.11/bin/../lib/protobuf-java-2.4.0a.jar:/home/yj70978/hbase-0.94.11/bin/../lib/servlet-api-2.5-6.1.14.jar:/home/yj70978/hbase-0.94.11/bin/../lib/slf4j-api-1.4.3.jar:/home/yj70978/hbase-0.94.11/bin/../lib/slf4j-log4j12-1.4.3.jar:/home/yj70978/hbase-0.94.11/bin/../lib/snappy-java-1.0.3.2.jar:/home/yj70978/hbase-0.94.11/bin/../lib/stax-api-1.0.1.jar:/home/yj70978/hbase-0.94.11/bin/../lib/velocity-1.7.jar:/home/yj70978/hbase-0.94.11/bin/../lib/xmlenc-0.52.

you should now havea running standalone hbase instance. In standalone mode, hbase runs all daemonsin the one jvm;i.e. both the hbase and zookeeper daemons. Hbase logs can befound in the logs subdirectory. Check them out especially of it seems hbase hadtrouble starting.

Log in here: /home/yj70978/hbase-0.94.11/bin/../logs/hbase-yj70978-master-retailvm1d.out

Hbase深入学习(二) 安装hbase的更多相关文章

  1. hbase总结(二)-hbase安装

    本篇介绍两种HBase的安装方式:本地安装方式和伪分布式安装方式. 安装的前提条件是已经安装成功了hadoop,并且hadoop的版本号要和hbase的版本号相匹配. 我将要安装的hbase是hbas ...

  2. HBase 系列(二)—— HBase 系统架构及数据结构

    一.基本概念 一个典型的 Hbase Table 表如下: 1.1 Row Key (行键) Row Key 是用来检索记录的主键.想要访问 HBase Table 中的数据,只有以下三种方式: 通过 ...

  3. YII2.0学习二 安装adminlte 后台模板

    控制台切换到安装目录wwwroot/shanghai/ 修改一下composer镜像地址:composer 使用中国镜像 运行 composer require dmstr/yii2-adminlte ...

  4. HBase 学习之一 <<HBase使用客户端API动态创建Hbase数据表并在Hbase下导出执行>>

    HBase使用客户端API动态创建Hbase数据表并在Hbase下导出执行                       ----首先感谢网络能够给我提供一个开放的学习平台,如果没有网上的技术爱好者提供 ...

  5. Hbase总结(一)-hbase命令,hbase安装,与Hive的区别,与传统数据库的区别,Hbase数据模型

    Hbase总结(一)-hbase命令 下面我们看看HBase Shell的一些基本操作命令,我列出了几个常用的HBase Shell命令,如下: 名称 命令表达式 创建表 create '表名称', ...

  6. HBase学习之路 (二)HBase集群安装

    前提 1.HBase 依赖于 HDFS 做底层的数据存储 2.HBase 依赖于 MapReduce 做数据计算 3.HBase 依赖于 ZooKeeper 做服务协调 4.HBase源码是java编 ...

  7. hbase学习(二)hbase单机和高可用完全分布式安装部署

    hbase版本 2.0.4  与hadoop兼容表http://hbase.apache.org/book.html#hadoop  我的 hadoop版本是3.1   1.单机版hbase 1.1解 ...

  8. 【Hbase学习之二】Hbase 搭建

    环境 虚拟机:VMware 10 Linux版本:CentOS-6.5-x86_64 客户端:Xshell4 FTP:Xftp4 jdk8 hadoop-3.1.1 hbase-2.1.3 一.单机模 ...

  9. HBase 系列(二)安装部署

    HBase 系列(二)安装部署 本节以 Hadoop-2.7.6,HBase-1.4.5 为例安装 HBase 环境.HBase 也有三种模式:本地模式.伪分布模式.分布模式. 一.环境准备 (1) ...

随机推荐

  1. libeXosip2(1-2) -- How-To initiate, modify or terminate calls.

    How-To initiate, modify or terminate calls. The eXtented eXosip stack eXosip2 offers a flexible API ...

  2. unix c 07

    进程的结束函数 (exit._Exit)    exit 并不是立即退出,退出前执行 用atexit/on_exit函数 注册的函数.    exit(int status)中的status可以用 w ...

  3. RFC3261--sip

    本文转载自 http://www.ietf.org/rfc/rfc3261.txt 中文翻译可参考 http://wenku.baidu.com/view/3e59517b1711cc7931b716 ...

  4. Reverse Nodes in k-Group 解答

    Question Given a linked list, reverse the nodes of a linked list k at a time and return its modified ...

  5. Hdu4005-The war(双连通缩点)

    In the war, the intelligence about the enemy is very important. Now, our troop has mastered the situ ...

  6. 理解mcelog如何工作

    前言 本文,带你了解几个问题? 本文重点,主要看案例2,带你很好的理解mcelog如何工作的? mcelog的干什么的? mcelog 是 x86 的 Linux 系统上用来 检查硬件错误,特别是内存 ...

  7. JS~Boxy和JS模版实现一个标准的消息提示框

    面向对象的封装 面向对象一个入最重要的特性就是“封装”,将一些没有必要公开的方法和属性以特定的方式进行组装,使它对外只公开一个接口,外界在调用它时,不需要关注它实现的细节,而只要关注它的方法签名即可, ...

  8. UVA247- Calling Circles(有向图的强连通分量)

    题目链接 题意: 给定一张有向图.找出全部强连通分量,并输出. 思路:有向图的强连通分量用Tarjan算法,然后用map映射,便于输出,注意输出格式. 代码: #include <iostrea ...

  9. 用CSS3实现对图片的放大效果

    用CSS3对图片放大效果 .right_div .topicons li a:hover img{     -webkit-transform:scale(1.5,1.5);     -moz-tra ...

  10. 男同胞爱小秘籍--作为爱他的女朋友了几天C规划

    各位男同胞,不知道你的女朋友没有在过去的一问天,你这个问题~~ 场景重现: 女友:"今天天气不错." 你们:"对" 女友:"今天是我们知道它的最初几天 ...