developing elasticity based on network load

I have a couple of Linode servers to handle the base load. How can I implement a functionality to spin up more Linode instances based on a spike in the load, e.g. network load?

For example, if the incoming/outgoing network traffic goes beyond 70% for more than 30 minutes, create another Linode instance from a saved image. (Linode provides Network traffic rate in (two hour average) which is not quick enough for my scenario)

I'm guessing it's a combination of developing/nagios/linode-API. I just want to know what is the best practice.

1 Reply

Step 1) Automate deploying a new server. Puppet/Chef/Ansible/Salt/etc, there are all kinds of tools out there, pick your poison. When you're done, you should be able to take a fresh Linode and run a command to get your stuff set up on it. Whether that's a stackscript or something else, have at it.

Step 2) Teach Nagios or whatever does your monitoring to monitor whatever metric you want to use for deciding when to scale. I'd highly recommend not using network bandwidth, given that in almost all cases that's a super indirect way to detect this. You'd probably be way better off tracking your app server's response times or how many requests it's queuing up or the length of time a request sits between coming in and being handled or some such. But whatever you pick, teach nagios to monitor it.

Step 3) Tell Nagios to run the command from step 1 when it detects the condition from step 2

  • Les

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct