Harsha
Harsha

Reputation: 737

Load balancer slowing down the site

We have 6 web servers and a load balancer in between.

But load balancing seems to actually slowing down the things. If I access the site using any server's IP address the site gets opened fast compared to accessing through load balancer.

On load balancer it seems requests wait for long till they get response from other requests, especially for JS code. Load balancer is configured with session affinity though. Some times there are even redirect loops. On certain networks the response doesn't come at all leaving the site broken.

Are there any tips that I need to follow. How to know if load balancer is configured and working properly?

Load balancer is on apache and site is built using PHP.

UPDATE: Load balancing is done through LVS and the algorithm used is Round-Robin scheduling. I am not sure what other details are required, but the problem is, when I access the site directly using any one server's IP address, it comes fine and pretty fast, but, when I use load balancer IP address, some resources like css/images don't load at all and site keeps loading for long time and then eventually fails. I tried with all IP addresses of all servers and all work fine, seems like there is a problem with LB, just not sure how to know. Let me know if I am missing any crucial info again to know the problem exactly.

Any help is greatly appreciated.

Thanks

Upvotes: 2

Views: 2615

Answers (1)

Harsha
Harsha

Reputation: 737

I guess I found out the reason here.

It is nothing to do with load balancer. I pinged the nameservers and found out many packets were getting lost.

Now have increased the ttl, hoping it will resolve the issue else going to have own nameservers.

Thanks

Upvotes: 1

Related Questions