Report this

What is the reason for this report?

Load Balancing with auto scaling up and down

Posted on May 27, 2015

I am interested to know whether it is possible on digital ocean to do a setup where just the load balancer and the one node runs and only if the one node is experiencing a high demand then the other node is started up.

Basically so there is not a need to pay for both nodes all the time when one will be fine, but then when its gets busy the other one helps out.

Not sure if this is possible

Any advice will be appreciated.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

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.

you can simply use DO API. we have some example configs here: https://github.com/magenx/Digitalocean-Auto-Scaling-Droplets-Auto-Scale-DIY

the idea is to check the load on master droplet and start new droplet if load is too high. configure it, rsync files and inject ip into load balancer.

This tutorial might be what you are looking for, this way your not paying for unused resources.

Hi there,

Quick update here, Droplet autoscale pools are now available. Autoscale pools enable automatic horizontal autoscaling based on resource utilization.

In the Autoscale Pool Configuration section, you can choose the configuration of the pool:

  • Autoscale dynamically manages the number of Droplets in the pool based on their aggregate resource utilization. You choose:

    • Pool Size, which controls the minimum and maximum number of Droplets in the pool.

    • Target Utilization, which control which metrics (CPU, memory, or both) to monitor and at what thresholds to scale.

      Autoscale pools set to autoscale determine how many Droplets the pool should have by multiplying the utilization ratio by the current number of Droplets in the pool and taking the ceiling of the result. With multiple metrics set, the pool uses the largest result of this calculation across all metrics.

      For example, an autoscale pool with 2 Droplets, a target utilization of 80% CPU, and a current utilization of 95% CPU would scale to 3 Droplets: ceil(2 Droplets * (80% target CPU / 95% current CPU)) = ceil(2.375) = 3.

    • Cooldown Duration, which is the minimum amount of time the autoscale pool waits between making modifications to the Droplets in the pool. This cooldown prevents thrashing during scaling and prevents downtime during configuration changes by giving new Droplets time to boot before destroying the old ones.

      Choose a cooldown duration at least as long as it takes your Droplets to boot.

  • Fixed Size maintains a fixed number of Droplets in the pool. Autoscale pools set to fixed size have a cooldown duration of 10 minutes which you cannot change. You choose:

    • Number of Droplets. The quantity of Droplets you want in the pool.

- Bobby

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.