Questions tagged [load-balancing]

The term load balancing is used to describe technology that is used to evenly distribute work across multiple nodes within a network.

Load balancing is a computer networking method for distributing workloads across multiple computers or a computer cluster, network links, central processing units, disk drives, or other resources. Successful load balancing optimizes resource use, maximizes throughput, minimizes response time, and avoids overload. Using multiple components with load balancing instead of a single component may increase reliability through redundancy. Load balancing is usually provided by dedicated software or hardware, such as a multilayer switch or a Domain Name System server Process.

5217 questions
25
votes
1 answer

How to force node.js/express.js to HTTPS when it is running behind an AWS load balancer

I'm running a node/express service on AWS and have deployed an ELB in front of it. When I spin up an ELB instance with SSL enabled, it works for the first page I hit, but then switches over to HTTP for every server access after that. The routing…
Greg
  • 2,559
  • 4
  • 28
  • 46
25
votes
1 answer

How do networking and load balancer work in docker swarm mode?

I am new to Dockers and containers. I was going through the tutorials for docker and came across this information. https://docs.docker.com/get-started/part3/#docker-composeyml networks: - webnet networks: webnet: What is webnet? The…
SunilS
  • 2,030
  • 5
  • 34
  • 62
25
votes
1 answer

Nginx proxy buffering - changing buffer's number vs size ?

I was wondering and trying to figure out how these two settings: proxy_buffers [number] [size]; may affect (improve / degrade) proxy server performance, and whether to change buffers' size, or the number, or both...? In my particular case, we're…
Less
  • 3,047
  • 3
  • 35
  • 46
25
votes
4 answers

AWS load balancer and maintenance page

I'm using AWS Load Balancer with 3 EC2 servers, and I'm trying to serve a Maintenance page when site is under maintenance. This page need to return 503 HTTP code, because it is a proper code for a maintenance mode and will prevent possible problems…
25
votes
10 answers

504 Gateway Timeout - Two EC2 instances with load balancer

This might be the impossible issue. I've tried everything. I feel like there's a guy at a switchboard somewhere, twirling his mustache. The problem: I have Amazon EC2 running an application. It functions without issue when there is only one…
user3035649
  • 472
  • 1
  • 4
  • 12
24
votes
3 answers

Scaling a postgres server to multiple servers

Our postgres server is about hitting its capacity and we're looking into adding a second database server. Are there any scaling solutions that are particularly good for a postgres setup?
24
votes
1 answer

How to tell AWS application load balancer to not forward the path pattern?

I have configured my AWS application load balancer to have the following rules: /images/* forward to server A (https://servera.com) /videos/* forward to server B (https://serverb.com) And this is correctly forwarding to the respective servers.…
jobin
  • 2,600
  • 7
  • 32
  • 59
24
votes
4 answers

Azure - Get Current Status of the Load Balancer Probe

We have a load balanced set in Azure for our web application, which load balances port 80 and 443 between two VMs. We have used the default tcp probe. Is there a way to get the current status of the probe for the load balancer from Azure? I know I…
madaboutcode
  • 2,137
  • 1
  • 16
  • 23
24
votes
3 answers

How to redirect to HTTPS with .htaccess on Heroku Cedar stack

I'm new to cloud hosting... I'm working on a PHP web app that's hosted on Heroku as a "Cedar" app. Heroku offers "piggy back" SSL to all their subdomains, so I can load https://myapp.herokuapp.com just fine. But I can also load…
emersonthis
  • 32,822
  • 59
  • 210
  • 375
23
votes
1 answer

How do you load balance TCP traffic?

I'm trying to determine how to load balance TCP traffic. I understand how HTTP load balancing works because it is a simple Request / Response architecture. However, I'm unsure of how you load balance TCP traffic when your servers are trying to write…
Brian DiCasa
  • 9,369
  • 18
  • 65
  • 97
23
votes
5 answers

Elastic Load Balancing in EC2

It's been on the cards for a while, but now that Amazon have released Elastic Load balancing (ELB), what are your thoughts on deploying this solution for a high-traffic web application? Should we replace HAProxy or consider ELB as a complimentary…
Dom
  • 1,486
  • 2
  • 14
  • 22
23
votes
3 answers

understanding load balancing in asp.net

I'm writing a website that is going to start using a load balancer and I'm trying to wrap my head around it. Does IIS just do all the balancing for you? Do you have a separate web layer that sits on the distributed server that does some work before…
dbarnes
  • 1,803
  • 3
  • 17
  • 31
22
votes
4 answers

What is the best way to handle sessions for a PHP site on multiple hosts?

PHP stores its session information on the file system of the host of the server establishing that session. In a multiple-host PHP environment, where load is unintelligently distributed amongst each host, PHP session variables are not available to…
Simon Young
  • 281
  • 2
  • 9
21
votes
1 answer

How to use Session Affinity on requests to Kubernetes service?

I could not find a documentation that specifies how Kubernetes service behaves when the affiliated deployment is scaled with multiple replicas. I'm assuming there's some sort of load balancing. Is it related to the service type? Also, I would want…
21
votes
9 answers

A(Host) Records with AWS Load Balancer

I have a question regarding AWS Load Balancers. I can point my CNAME www to my load balancer's DNS perfectly and i know it will always work, BUT I also need to point the @ record to the load balancer so people can access mysite.com instead of…
albertosh
  • 2,416
  • 7
  • 25
  • 32