0

I am ready to implement an autoscale server farm for 'webapps' to handle traffic spikes and had a question.

The plan is to create an ELB which will forward traffic across multiple availability zones. Right now I am specifying servers individually in the upstream section of my nginx vhost confs, but I was thinking it may be better to create a CNAME record which points to the DNS record of the internal ELB which will dole out the requests to the servers in the autoscale farm, this way I don't have mess with updating the nginx+ config file, so instead of:

upstream mothership {

    zone heartbeat_mothership 64k;

    server app-a-1:51000 slow_start=20s;
    server app-a-2:51000 slow_start=20s;
    server app-a-3:51000 slow_start=20s;
}

I can do:

upstream mothership {

    zone heartbeat_mothership 64k;

    internal-lb1:51000; # CNAME to AWS ELB which monitors port 51000 of servers in autoscale farm spread across multiple AZ
}

Or do I have to go into weeds in setting up a script via AWS SDK as mentioned in other online articles?

1 Answer 1

0

Yes, that's what internal CNAMEs are for.

2
  • Prophetic. Guess I was looking for confirmation that this would be a viable solution (for AWS), as all the other articles involved having to write scripts to update and register new nodes with N+, but this seems way easier. Oct 24, 2015 at 0:13
  • There is a lot of wrong (or at least outdated) information on the Internet. Perhaps this is some of it. (grin)
    – womble
    Oct 24, 2015 at 0:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .