NGINX as load balancer question

Posted May 27, 2018 2.7k views
NginxUbuntuLoad Balancing

Hello all,

I am thinking about splitting my single machine setup into multiple machines. I am thinking of using a NGINX as a load balancer in front of my main PHP+NGINX machines. However, I am not sure how many cores and ram to put on my load balancing node. When my NGINX with PHP is processing the requests, it uses the cpu a lot but I am not sure if this is the same case when NGINX is as a load balancer. My question is, how power hungry is NGINX when the only job it does is load balancing ?

Thanks in advance!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

Nginx running as a load balancer will use a lot less resources than a LEMP stack serving a site. In most cases, because network throughput is the same for all plans you can safely go with the smallest droplet (1GB RAM) for your load balancer. Should you see resource use increasing as your site scales you can resize to a larger plan in the time it takes to reboot your droplet.

  • Hi Ryan,

    I am not really worried about the network throughput but more about the CPU usage of the NGINX when it is a proxy. Also does internal traffic (via private ips) count towards the montly droplet usage ?