NGINX as load balancer question

May 27, 2018 655 views
Nginx Load Balancing Ubuntu

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!

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 ?

Have another answer? Share your knowledge.