I have a setup with three VMs that are running on a core i74xx. The machines form a LAMP cluster with HAProxy doing the loadbalancing.
After running multiple load tests I found out, that throughput doubles as soon as I put the Apache Instance running on the same node as HAProxy into maintenance mode - Therefore giving HAProxy more CPU.
Now the problem is, that both HAProxy instances run in keepalived failover mode. One never knows which node runs the HAProxy.
The architecture itself looks like this:
I do not want to add more machines to the cluster but rather spread the services inside more efficiently.
Is there a way to automatically manage the status of Apache with HAProxy?