這篇文章主要介紹“hbase表結(jié)構(gòu)及安裝部署過(guò)程”,在日常操作中,相信很多人在hbase表結(jié)構(gòu)及安裝部署過(guò)程問(wèn)題上存在疑惑,小編查閱了各式資料,整理出簡(jiǎn)單好用的操作方法,希望對(duì)大家解答”hbase表結(jié)構(gòu)及安裝部署過(guò)程”的疑惑有所幫助!接下來(lái),請(qǐng)跟著小編一起來(lái)學(xué)習(xí)吧!
十年的謝通門網(wǎng)站建設(shè)經(jīng)驗(yàn),針對(duì)設(shè)計(jì)、前端、開(kāi)發(fā)、售后、文案、推廣等六對(duì)一服務(wù),響應(yīng)快,48小時(shí)及時(shí)工作處理。營(yíng)銷型網(wǎng)站的優(yōu)勢(shì)是能夠根據(jù)用戶設(shè)備顯示端的尺寸不同,自動(dòng)調(diào)整謝通門建站的顯示方式,使網(wǎng)站能夠適用不同顯示終端,在瀏覽器中調(diào)整網(wǎng)站的寬度,無(wú)論在任何一種瀏覽器上瀏覽網(wǎng)站,都能展現(xiàn)優(yōu)雅布局與設(shè)計(jì),從而大程度地提升瀏覽體驗(yàn)。成都創(chuàng)新互聯(lián)公司從事“謝通門網(wǎng)站設(shè)計(jì)”,“謝通門網(wǎng)站推廣”以來(lái),每個(gè)客戶項(xiàng)目都認(rèn)真落實(shí)執(zhí)行。
hbase表結(jié)構(gòu)及安裝部署
建表時(shí)只需要指定表名和列族
每一行是一條記錄, 每一行的字段數(shù)是任意的,每一個(gè)字段都要指定存儲(chǔ)
字段名和字段值,查詢某一個(gè)字段時(shí),需要指定的坐標(biāo):表名--行健--列族
字段名clolumn family 字段
[root@hadoop04 Desktop]# tar -zxvf hbase-0.96.2-hadoop2-bin.tar.gz -C ../app
[root@hadoop04 Desktop]# cd ../app
[root@hadoop04 app]# cd hbase-0.96.2-hadoop2
[root@hadoop04 hbase-0.96.2-hadoop2]# ls
bin conf hbase-webapps LICENSE.txt README.txt
CHANGES.txt docs lib NOTICE.txt
[root@hadoop04 hbase-0.96.2-hadoop2]# cd conf
[root@hadoop04 conf]# ls
hadoop-metrics2-hbase.properties hbase-policy.xml regionservers
hbase-env.cmd hbase-site.xml
hbase-env.sh log4j.properties
[root@hadoop04 conf]# echo $JAVA_HOME
/usr/lib/java/java-7-sun
[root@hadoop04 conf]# vi hbase-env.sh
export JAVA_HOME=/usr/lib/java/java-7-sun
export HBASE_MANAGES_ZK=false指定外部的zk
[root@hadoop04 conf]# vi hbase-site.xml
[root@hadoop04 conf]# vi regionservers
hadoop01
hadoop02
hadoop03
注意要把hadoop 的hdfs-site.xml,core-site.xml放到hbase/conf下
[root@hadoop04 conf]# cp /home/hadoop/hadoop-2.6.0/etc/hadoop/{core-site.xml,hdfs-site.xml} ./
[root@hadoop05 ~]# mkdir /root/app
[root@hadoop01 ~]# mkdir /root/app
[root@hadoop02 ~]# mkdir /root/app
[root@hadoop03 ~]# mkdir /root/app
[root@hadoop04 app]# scp -r hbase-0.96.2-hadoop2/ hadoop05:/root/app
[root@hadoop04 app]# scp -r hbase-0.96.2-hadoop2/ hadoop01:/root/app
[root@hadoop04 app]# scp -r hbase-0.96.2-hadoop2/ hadoop02:/root/app
[root@hadoop04 app]# scp -r hbase-0.96.2-hadoop2/ hadoop03:/root/app
[root@hadoop04 app]# hdfs dfsadmin report
[root@hadoop04 app]# cd hbase-0.96.2-hadoop2
[root@hadoop04 hbase-0.96.2-hadoop2]# cd bin
[root@hadoop04 bin]# ./start-hbase.sh
starting master, logging to /root/app/hbase-0.96.2-hadoop2/bin/../logs/hbase-root-master-hadoop04.out
hadoop03: starting regionserver, logging to /root/app/hbase-0.96.2-hadoop2/bin/../logs/hbase-root-regionserver-hadoop03.out
hadoop02: starting regionserver, logging to /root/app/hbase-0.96.2-hadoop2/bin/../logs/hbase-root-regionserver-hadoop02.out
hadoop01: starting regionserver, logging to /root/app/hbase-0.96.2-hadoop2/bin/../logs/hbase-root-regionserver-hadoop01.out
[root@hadoop04 bin]# jps
16023 Jps
25023 DFSZKFailoverController
24498 NameNode
15805 HMaster
[root@hadoop01 app]# jps
15125 DataNode
19939 HRegionServer
20100 Jps
15243 NodeManager
4649 QuorumPeerMain
4822 JournalNode
[root@hadoop04 bin]# ./hbase shell
2016-01-16 18:51:14,061 INFO [main] Configuration.deprecation: hadoop.native.lib is deprecated. Instead, use io.native.lib.available
HBase Shell; enter 'help
Type "exit
Version 0.96.2-hadoop2, r1581096, Mon Mar 24 16:03:18 PDT 2014
hbase(main):001:0>
hbase(main):013:0> help
啟動(dòng)所有的hbase
分別啟動(dòng)zk
./zkServer.sh start
啟動(dòng)hbase集群
start-dfs.sh
啟動(dòng)hbase,在主節(jié)點(diǎn)上運(yùn)行
start-hbase.sh
通過(guò)瀏覽器訪問(wèn)hbase管理頁(yè)面
hadoop04:60010
為保證集群的可靠性,要啟動(dòng)多個(gè)hmaster
hbase-daemon.sh start master
到此,關(guān)于“hbase表結(jié)構(gòu)及安裝部署過(guò)程”的學(xué)習(xí)就結(jié)束了,希望能夠解決大家的疑惑。理論與實(shí)踐的搭配能更好的幫助大家學(xué)習(xí),快去試試吧!若想繼續(xù)學(xué)習(xí)更多相關(guān)知識(shí),請(qǐng)繼續(xù)關(guān)注創(chuàng)新互聯(lián)網(wǎng)站,小編會(huì)繼續(xù)努力為大家?guī)?lái)更多實(shí)用的文章!