MySQL port 3306 became filtered when configured with Keepalived on Ubuntu server 12.04 lts
Posted
by
Ludwig
on Server Fault
See other posts from Server Fault
or by Ludwig
Published on 2012-06-26T05:03:54Z
Indexed on
2012/06/29
15:17 UTC
Read the original article
Hit count: 305
I'm configuring two load balancer (lb01 & lb02) with keepalived for my two mysql server (db01 & db02) with standard port 3306. There is virtual ip address (192.168.205.10) to access it also act as failover, but somehow the web server in the front can't access this mysql server using vip. Here is my config:
Keepalived:
Only the mysql part that i added here.
LB01:
virtual_server 192.168.205.10 3306 {
delay_loop 6
lb_algo rr
lb_kind DR
protocol TCP
real_server 192.168.205.4 3306 {
weight 10
TCP_CHECK {
connect_port 3306
connect_timeout 2
}
}
}
LB02:
virtual_server 192.168.205.10 3306 {
delay_loop 6
lb_algo rr
lb_kind DR
protocol TCP
real_server 192.168.205.6 3306 {
weight 10
TCP_CHECK {
connect_port 3306
connect_timeout 2
}
}
}
I already comment out the "bind-address=127.0.0.1" part in both server my.cnf. Also, remove all the firewall prog from my ubuntu server (ufw or iptables).
Any help?
thanks.
© Server Fault or respective owner