cat authkeys
auth 2
2 sha1 test-ha-keystone

 

 

 cat ha.cf
logfile /var/log/ha-log
logfacility local0
keepalive 2
deadtime 30
initdead 120
udpport 695
ucast eth0 10.12.31.22
auto_failback off
node keystone01
node keystone02

 

 cat haresources
keystone01 IPaddr2::10.12.31.40/22/eth0/10.12.31.255
 

ifconfig

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 02:16:3e:1a:b1:5d brd ff:ff:ff:ff:ff:ff
    inet 10.12.31.22/22 brd 10.12.31.255 scope global eth0
    inet 10.12.31.40/22 brd 10.12.31.255 scope global secondary eth0

tail /var/log/ha-log
Sep 05 14:11:15 keystone01 heartbeat: [1994]: info: Link keystone02:eth0 dead.
Sep 05 14:11:26 keystone01 heartbeat: [1994]: info: Heartbeat restart on node keystone02
Sep 05 14:11:26 keystone01 heartbeat: [1994]: info: Link keystone02:eth0 up.
Sep 05 14:11:26 keystone01 heartbeat: [1994]: info: Status update for node keystone02: status init
Sep 05 14:11:26 keystone01 heartbeat: [1994]: info: Status update for node keystone02: status up
harc[15547]: 2012/09/05_14:11:26 info: Running /etc/ha.d//rc.d/status status
harc[15564]: 2012/09/05_14:11:26 info: Running /etc/ha.d//rc.d/status status
Sep 05 14:11:29 keystone01 heartbeat: [1994]: info: Status update for node keystone02: status active
harc[15581]: 2012/09/05_14:11:29 info: Running /etc/ha.d//rc.d/status status
Sep 05 14:11:30 keystone01 heartbeat: [1994]: info: remote resource transition completed.