您好,欢迎访问三七文档
当前位置:首页 > 临时分类 > educoder平台hbase的安装与环境搭建
第一关Hbase数据库的安装mkdir/app回车cd/opt回车ulimit-f1000000回车tar-zxvfhbase-2.1.1-bin.tar.gz-C/app回车echo$JAVA_HOME回车;(复制这个命令所显示出的路径,要用)结果是:/usr/lib/jvm/jdk1.8.0_111vim/app/hbase-2.1.1/conf/hbase-env.sh回车,翻到第二十八行,找到#exportJAVA_HOME=/usr/java/jdk1.8.0/把前面的#删了、把/usr/java/jdk1.8.0/换成exportJAVA_HOME=/usr/lib/jvm/jdk1.8.0_111esc,wqcd(回到根目录)回车vim/app/hbase-2.1.1/conf//hbase-site.xml回车到最后一行把代码复制到configuration标签上configurationpropertynamehbase.rootdir/namevaluefile:///root/data/hbase/data/value/propertypropertynamehbase.zookeeper.property.dataDir/namevalue/root/data/hbase/zookeeper/value/propertypropertynamehbase.unsafe.stream.capability.enforce/namevaluefalse/value/property/configuration然后wqvim/etc/profile在末尾添加以下#SETHBASE_enviromentHBASE_HOME=/app/hbase-2.1.1exportPATH=$PATH:$HBASE_HOME/bin然后wqsource/etc/profile(使配置生效)回车start-hbase.sh(启动)回车jps(查看是否成功)回车测评!!!------------------------------------------------------------------------第二关创建表hbaseshell回车create'test','data'回车create'dept','data'回车create'emp','data'回车list测评------------------------------------------------------------------------第三关添加数据、删除数据、删除表create'mytable','data'回车put'mytable','row1','data:1','zhangsan'put'mytable','row2','data:2','zhangsanfeng'put'mytable','row3','data:3','zhangwuji'scan'mytable'测评deleteall'mytable','row1'删除表不用复制这一条
本文标题:educoder平台hbase的安装与环境搭建
链接地址:https://www.777doc.com/doc-8140215 .html