码迷,mamicode.com
首页 > 其他好文 > 详细

RHCS配置-RHEL6-fence_vbox

时间:2015-11-21 07:16:55      阅读:151      评论:0      收藏:0      [点我收藏+]

标签:fence vbox

<?xml version="1.0"?>

<cluster config_version="57" name="HA">
<clusternodes>
<clusternode name="cluster1" nodeid="1">
<fence>
<method name="1">
<device name="VBoxManage" vmname="Cluster1"/>
</method>
</fence>
</clusternode>
<clusternode name="cluster2" nodeid="2">
<fence>
<method name="1">
<device name="VBoxManage" vmname="Cluster2"/>
</method>
</fence>
</clusternode>
</clusternodes>
<cman expected_votes="1" two_node="1"/>
<rm>
<failoverdomains>
<failoverdomain name="HA" ordered="1" restricted="1">
<failoverdomainnode name="cluster1" priority="1"/>
<failoverdomainnode name="cluster2" priority="2"/>
</failoverdomain>
</failoverdomains>
<resources>
<ip address="192.168.1.151/24" sleeptime="10"/>
<drbd name="DRBD" resource="r0"/>
<nfsserver name="NFS"/>
<fs device="/dev/drbd0" force_unmount="1" fsid="9595" fstype="ext4" mountpoint="/media/nfs" name="/media/nfs" nfsrestart="1" options="noatime" self_fence="1"/>
</resources>
<service domain="HA" exclusive="1" max_restarts="2" name="HA" recovery="restart" restart_expire_time="30">
<ip ref="192.168.1.151/24">
<drbd ref="DRBD">
<fs ref="/media/nfs">
<nfsserver ref="NFS"/>
</fs>
</drbd>
</ip>
</service>
</rm>
<fencedevices>
<fencedevice agent="fence_vbox" login="kamui0523" name="VBoxManage" vboxhost="192.168.0.128"/>
</fencedevices>
</cluster>

=======================================================================================

fence_vbox的要求如下

1.guest需要能够不通过密码ssh到host机.

2.需要确认vbox的运行用户,比如这里是kamui0523

fence_vbox测试

fence_vbox -s 192.168.1.100 -g Cluster1 -a status

-s为host机的ip地址,-g是vbox的VMName



RHCS配置-RHEL6-fence_vbox

标签:fence vbox

原文地址:http://kamui0523.blog.51cto.com/163315/1715241

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!