ROW KEY
Column Family列族 & qualifier列
Timestamp时间戳
Cell单元格
HLog(WAL log)
Client
包含访问HBase的接口并维护cache来加快对HBase的访问。
Zookeeper
Master
RegionServer
5.Region
确认是否已安装ntp:
rpm –qa | grep ntp
若只有ntpdate而未见ntp,则需删除原有ntpdate。如:
yum –y remove ntpdate-4.2.6p5-22.el7.x86_64
安装ntp:
yum –y install ntp
所有节点设置为中国时区
timedatectl set-timezone Asia/Shanghai
在server节点上设置现在的准确时间
timedatectl set-time HH:MM:SS
vi /etc/ntp.conf
# 集群所在网段的网关(Gateway),子网掩码(Genmask)
restrict 192.168.33.2 mask 255.255.255.0 nomodify notrap
# 在server部分添加一下部分(注意不是127.0.0.1),并注释掉server 0 ~ n
server 127.127.1.0
Fudge 127.127.1.0 stratum 10
vi /etc/ntp.conf
# 在server部分添加如下语句,将server指向主节点。并注释掉server 0 ~ n
server 192.168.33.101
Fudge 192.168.33.101 stratum 10
修改/etc/sysconfig/ntpdate,让ntpdate每次同步时间之后把时间写入hwclock,相当于命令hwclock -w:
把最后一行SYNC_HWCLOCK=no修改为:SYNC_HWCLOCK=yes
service ntpd start
或
systemctl start ntpd
chkconfig ntpd on
或
systemctl enable ntpd
所有节点启动时间同步
timedatectl set-ntp yes
与本地ntpd Server同步一下
ntpdate -u node01
过几分钟客户机就会自动从服务机同步时间了。
前提:1、Hadoop集群正常运行;2、ZooKeeper集群正常运行。
cd /opt/hbase-2.1.2/conf/
vi regionservers
node01
node02
node03
vi backup-masters
# 添加备用hbase-master
node03
export JAVA_HOME=/opt/jdk1.8
export HBASE_MANAGES_ZK=false
hbase.rootdir
hdfs://mycluster/hbase
hbase.cluster.distributed
true
hbase.zookeeper.quorum
node01:2181,node01:2181,node01:2181
hbase.zookeeper.property.dataDir
/var/zookeeper
zookeeper.session.timeout
120000
hbase.regionserver.restart.on.zk.expire
true
复制hdfs-site.xml到conf目录下
在全部节点的环境变量配置文件中加入HBASE_HOME
启动Hbase: start-hbase.sh
ERROR [main] regionserver.HRegionServer: Failed construction RegionServer
java.lang.NoClassDefFoundError: org/apache/htrace/SamplerBuilder
解决方案:cp $HBASE_HOME/lib/client-facing-thirdparty/htrace-core-3.1.0-incubating.jar $HBASE_HOME/lib/
Please check the config value of 'hbase.procedure.store.wal.use.hsync' to set the desired level of robustness and ensure the config value of 'hbase.wal.dir' points to a FileSystem mount that can provide it
解决方案:在hbase-site.xml文件中加入:
hbase.unsafe.stream.capability.enforce
false