Mình làm theo lab trên khi đã cài heartbeat thành công.
Nhưng khi start dịch vụ heartbeat lên show ip bằng lệnh ifconfig|more thì không thấy Ip ảo: VIP: 192.168.1.15 trên máy active
cấu hình máy active:
etho:192.168.1.11
eth1:172.16.1.1
Máy passive
eth0:192.168.1.12
eth1:172.16.1.2
Cấu hình file /etc/ha.d/ha.cf như sau:
#ldebugfile /var/log/ha-debug
logfile /var/log/ha-log
logfacility local0
keepalive 2
deadtime 30
initdead 120
bcast eth1
udpport 694
auto_failback on
node db1.domain.com
node db2.domain.com
cấu hình file /etc/ha.d/haresources
db1.domain.com IPaddr::192.168.1.15/24/eth0 drbddisk::mysql
Filesystem::/dev/drbd0::/var/lib/mysql::ext3::defaults mysqld
Mình đã copy các file trên qua máy passive.
Khi start heartbeat ko thấy hiện lên VIP:192.168.1.15
Mình ko hiểu nguyên nhân tại sao.Mong các pro chỉ rõ.
Lab thực hiện trên centos