Bonjour à tous,
J’ai mis en place un LB avec KeepAlived, pour mes deux serveurs Squid. Tout fonctionne très bien pour cette partie (LoadBalancing avec deux serveurs sur le port 3128), cependant j’aimerais migrer mes fichiers proxy.pac (actuellement sur un autre serveur) sur les serveurs proxies et donc rendre accessible le proxy.pac via l’adresse virtuel du Cluster.
Ip virtuel du cluster : 192.168.21.30
Ip du proxy 1 : 192.168.21.26
Ip du proxy 2 : 192.168.21.27
J’ai tenté avec un TCP_CHECK, avec le digest/sans le digest… Rien à faire le LB pense que le service est down.
L’Apache est bien entendu fonctionnel et écoute sur toutes les interfaces des serveurs port 80.
Voici mon fichier /etc/keepalived/keepalived.conf
virtual_server 192.168.21.30 3128 {
delay_loop 30
lb_algo lc
lb_kind DR
persistence_timeout 50
protocol TCP
real_server 192.168.21.26 3128 {
#weight 1
inhibit_on_failure
TCP_CHECK {
connect_port 3128
connect_timeout 3
nb_get_retry 3
delay_before_retry 1
}
}
real_server 192.168.21.27 3128 {
#weight 1
inhibit_on_failure
TCP_CHECK {
connect_port 3128
connect_timeout 3
nb_get_retry 3
delay_before_retry 1
}
}
}
virtual_server 192.168.21.30 80 {
delay_loop 60
lb_algo lc
lb_kind DR
persistence_timeout 50
protocol TCP
real_server 191.168.21.26 80 {
inhibit_on_failure
HTTP_GET {
url {
path /lbcheck.html
#digest a8385b26c45592552ec45ed7249c2593
connect_timeout 3
nb_get_retry 3
delay_before_retry 1
}
}
}
real_server 191.168.21.27 80 {
inhibit_on_failure
HTTP_GET {
url {
path /lbcheck.html
#digest a8385b26c45592552ec45ed7249c2593
}
}
}
}
Et voici les logs correspondant :
Keepalived_healthcheckers: Initializing ipvs 2.6
Keepalived_healthcheckers: Registering Kernel netlink reflector
Keepalived_healthcheckers: Registering Kernel netlink command channel
Keepalived_healthcheckers: Opening file '/etc/keepalived/keepalived.conf'.
Keepalived_healthcheckers: Configuration is using : 22363 Bytes
Keepalived_healthcheckers: Using LinkWatch kernel netlink reflector...
Keepalived_healthcheckers: Activating healtchecker for service [192.168.21.26]:3128
Keepalived_healthcheckers: Activating healtchecker for service [192.168.21.27]:3128
Keepalived_healthcheckers: Activating healtchecker for service [191.168.21.26]:80
Keepalived_healthcheckers: Activating healtchecker for service [191.168.21.27]:80
Keepalived_healthcheckers: Error connecting server [191.168.21.26]:80.
Keepalived_healthcheckers: Disabling service [191.168.21.26]:80 from VS [192.168.21.3 0]:80
Keepalived_healthcheckers: Error connecting server [191.168.21.27]:80.
Keepalived_healthcheckers: Disabling service [191.168.21.27]:80 from VS [192.168.21.3 0]:80
Keepalived_healthcheckers: Lost quorum 1-0=1 > 0 for VS [192.168.21.30]:80
Quelqu’un aurait-il une idée ?
Bonne journée,
Bastichou