自动恢复被挂掉的hbase region server

最近老遇到hbase的regionserver自动挂掉的情况
日志总是看不出什么原因

不得已弄了个定时任务,任务的脚本类似是:

pssh -H "bluejoe1 bluejoe2..." "/usr/local/hbase/bin/hbase-daemon.sh start regionserver"

加入定时任务,让它隔10分钟执行一次:

crontab -e
10,20,30,40,50,0 * * * * pssh -H "bluejoe1 bluejoe2..." "/usr/local/hbase/bin/hbase-daemon.sh start regionserver"

service crond start    //启动服务

感觉办法有点下三滥,但也是无奈之举了。。。

原文地址:https://www.cnblogs.com/bluejoe/p/5115821.html