1、重启hadoop伪集群

cd /home/hadoop/hadoop-2.6.4/sbin
./start-all.sh

2、检查hadoop是否已经重启成功

cd  /home/hadoop/hadoop-2.6.4/bin
./hadoop fs  -ls /

在这里插入图片描述
3、清空zookeeper的缓存数据

rm -rf /home/hadoop/zookeeper-3.4.8/logs/version-2
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_1/version-2
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_1/zookeeper_server.pid
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_2/version-2
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_2/zookeeper_server.pid
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_3/version-2
rm -rf /home/hadoop/zookeeper-3.4.8/snapshot/d_3/zookeeper_server.pid

4、启动zookeeper

cd /home/hadoop/zookeeper-3.4.8/bin
./zkServer.sh start ../conf/zoo1.cfg 
./zkServer.sh start ../conf/zoo2.cfg 
./zkServer.sh start ../conf/zoo3.cfg 

5、启动hbase数据库

cd /home/hadoop/hbase-1.1.5/bin
./start-hbase.sh 

6、检查是否启动起来

./hbase shell
list

在这里插入图片描述
看到自己hbase的表后说明重启成功。

7、启动成功后,执行jps命令,查看是否全部进程启动成功。
在这里插入图片描述
8、hadoop集群怎么正常停止
8.1 关闭hadoop

cd /home/hadoop/hadoop-2.6.4/sbin
./stop-all.sh

8.2 关闭zookeeper

cd /home/hadoop/zookeeper-3.4.8/bin
./zkServer.sh stop ../conf/zoo1.cfg 
./zkServer.sh stop ../conf/zoo2.cfg 
./zkServer.sh stop ../conf/zoo3.cfg 

8.3 关闭hbase

cd /home/hadoop/hbase-1.1.5/bin
./stop-hbase.sh 
Logo

权威|前沿|技术|干货|国内首个API全生命周期开发者社区

更多推荐