Hi, i have a “design” question.
We have an external mysql cluster with x-nodes. I have configured one external-service in a stack with all ips of the nodes. also i configured service check ( http ) for all nodes. ( this service checks are working correct for each node)
As i want to exchange our hardware loadbalancer cluster as point of failure, i have added a rancher loadbalancer to the stack linked with the external-service mentioned above as only source destination.
a) does loadbalancing over external service works correctly, if all ips configured in on external service ?
b) for testing i have stopped all mysql nodes, but i don´t see in rancher any warning ? must be the stack shown unhealthy ?
my stack config:
version: '2'
services:
lb-mysql-cluster-2:
image: rancher/lb-service-haproxy:v0.6.2
ports:
- 3307:3307/tcp
labels:
io.rancher.container.agent.role: environmentAdmin
io.rancher.container.create_agent: 'true'
io.rancher.scheduler.global: 'true'
lb-mysql-cluster-1:
image: rancher/lb-service-haproxy:v0.6.2
ports:
- 3306:3306/tcp
labels:
io.rancher.container.agent.role: environmentAdmin
io.rancher.container.create_agent: 'true'
io.rancher.scheduler.global: 'true'
mysql-cluster-1:
image: rancher/external-service
mysql-cluster-2:
image: rancher/external-service
version: ‘2’
services:
lb-mysql-cluster-2:
start_on_create: true
lb_config:
certs:
port_rules:
- priority: 1
protocol: tcp
service: mysql-cluster-2
source_port: 3307
target_port: 3306
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 42
unhealthy_threshold: 3
interval: 2000
lb-mysql-cluster-1:
start_on_create: true
lb_config:
certs:
port_rules:
- priority: 1
protocol: tcp
service: mysql-cluster-1
source_port: 3306
target_port: 3306
health_check:
response_timeout: 2000
healthy_threshold: 2
port: 42
unhealthy_threshold: 3
interval: 2000
mysql-cluster-1:
external_ips:
- 10.100.0.x1
- 10.100.0.x2
- 10.100.0.x2
- 10.100.0.x3
start_on_create: true
health_check:
response_timeout: 2000
healthy_threshold: 2
port: 9200
unhealthy_threshold: 1
initializing_timeout: 60000
interval: 2000
strategy: recreate
request_line: GET “/” “HTTP/1.0”
reinitializing_timeout: 60000
mysql-cluster-2:
external_ips:
- 10.110.0.x1
- 10.110.0.x2
- 10.110.0.x3
start_on_create: true
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 9200
unhealthy_threshold: 1
initializing_timeout: 60000
interval: 2000
strategy: recreate
request_line: GET “/” “HTTP/1.0”
reinitializing_timeout: 60000