heardbeat安装

 

安装cluster glue

安装heartbeat之前需要安装glue。

01 yum install autoconf automake libtool glib2-devel libxml2-devel bzip2-devel e2fsprogs-devel libxslt-devel
02groupadd haclient
03 useradd -g haclient hacluster
04 cd /tmp
05 wget http://hg.linux-ha.org/glue/archive/glue-1.0.9.tar.bz2
06 tar xjf glue-1.0.9.tar.bz2
07 cd Reusable-Cluster-Components-glue--glue-1.0.9
08 ./autogen.sh
09 ./configure LIBS=/lib/libuuid.so.1 --prefix=/usr/local/heartbeat
10 make && make install

安装Resource Agents

1 cd /tmp
2 wget --no-check-certificate https://github.com/ClusterLabs/resource-agents/tarball/v3.9.2
3 tar xzf v3.9.2
4 cd ClusterLabs-resource-agents-b735277/
5 ./autogen.sh
6 export CFLAGS="$CFLAGS -I/usr/local/heartbeat/include -L/usr/local/heartbeat/lib"
7 ./configure --prefix=/usr/local/heartbeat
8 ln -s  /usr/local/heartbeat/lib//lib/
9 make && make install

安装Heartbeat

01 cd /tmp
02 wget http://hg.linux-ha.org/heartbeat-STABLE_3_0/archive/7e3a82377fa8.tar.bz2
03 tar xjf 7e3a82377fa8.tar.bz2
04 cd Heartbeat-3-0-7e3a82377fa8/
05 ./bootstrap
06 export CFLAGS="$CFLAGS -I/usr/local/heartbeat/include -L/usr/local/heartbeat/lib"
07 ./configure --prefix=/usr/local/heartbeat
08 make && make install
09 cp doc/ha.cf /usr/local/heartbeat/etc/ha.d/
10 cp doc/haresources /usr/local/heartbeat/etc/ha.d/
11 cp doc/authkeys /usr/local/heartbeat/etc/ha.d/
12 cp heartbeat/init.d/heartbeat /etc/rc.d/init.d/
13chkconfig --add heartbeat
14chkconfig heartbeat on
15 chmod 600 /usr/local/heartbeat/etc/ha.d/authkeys
16 sed -i 's#/usr/lib/ocf#/usr/local/heartbeat/usr/lib/ocf#g' /usr/local/heartbeat/etc/ha.d/shellfuncs
17 sed -i 's#/usr/lib/ocf#/usr/local/heartbeat/usr/lib/ocf#g' /usr/local/heartbeat/usr/lib/ocf/lib//heartbeat/ocf-shellfuncs
18 sed -i 's#/usr/lib/ocf#/usr/local/heartbeat/usr/lib/ocf#g' /usr/local/heartbeat/etc/ha.d/resource.d//hto-mapfuncs

除错

1、错误:glue_config.h:99:1: error: “HA_HBCONF_DIR” redefined
解决方法:http://www.centos.bz/2012/02/glue_config-h991-error-ha_hbconf_dir-redefined/
2、错误configure.ac:9: error: Autoconf version 2.63 or higher is required
解决方法:http://www.centos.bz/2012/03/configure-ac9-error-autoconf-version-2-63-or-higher-is-required/
3、错误configure.ac:63: require Automake 1.10.1, but have 1.9.6
解决方法:http://www.centos.bz/2012/03/configure-ac63-require-automake-1-10-1-but-have-1-9-6/

 

./.libs/libplumb.so: undefined reference to `uuid_parse’
./.libs/libplumb.so: undefined reference to `uuid_generate’
./.libs/libplumb.so: undefined reference to `uuid_copy’
./.libs/libplumb.so: undefined reference to `uuid_is_null’
./.libs/libplumb.so: undefined reference to `uuid_unparse’
./.libs/libplumb.so: undefined reference to `uuid_clear’
./.libs/libplumb.so: undefined reference to `uuid_compare’
collect2: ld returned 1 exit status
gmake[2]: *** [ipctest] Error 1
gmake[2]: Leaving directory `/root/Reusable-Cluster-Components-glue-1.0.6/lib/clplumbing’
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/root/Reusable-Cluster-Components-glue-1.0.6/lib’
make: *** [all-recursive] Error 1

这个差不多能看出来是uuid方面的包的故障,所以我一开始就想去安装一个libuuid-devel的包,在这个上面消耗了不少时间。但最后通过 google与linux-ha的maillist得到了提示,总算是把这个问题给解决了。解决方法其实很简单,只要在configure时在后面加上:
LIBS=’/lib/libuuid.so.1′

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值