Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6674061
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:42:05+00:00 2026-05-26T03:42:05+00:00

I have a cloud of server instances running at Amazon using their load balancer

  • 0

I have a cloud of server instances running at Amazon using their load balancer to distribute the traffic. Now I am looking for a good way to gracefully scale the network down, without causing connection errors on the browser’s side.

As far as I know, any connections of an instance will be rudely terminated when removed from the load balancer.

I would like to have a way to inform my instance like one minute before it gets shut down or to have the load balancer stop sending traffic to the dying instance, but without terminating existing connections to it.

My app is node.js based running on Ubuntu. I also have some special software running on it, so I prefer not to use the many PAAS offering node.js hosting.

Thanks for any hints.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T03:42:06+00:00Added an answer on May 26, 2026 at 3:42 am

    This idea uses the ELB’s capability to detect an unhealthy node and remove it from the pool BUT it relies upon the ELB behaving as expected in the assumptions below. This is something I’ve been meaning to test for myself but haven’t had the time yet. I’ll update the answer when I do.

    Process Overview

    The following logic could be wrapped and run at the time the node needs to be shut down.

    1. Block new HTTP connections to nodeX but continue to allow existing connections
    2. Wait for existing connections to drain, either by monitoring existing connections to your application or by allowing a “safe” amount of time.
    3. Initiate a shutdown on the nodeX EC2 instance using the EC2 API directly or Abstracted scripts.

    “safe” according to your application, which may not be possible to determine for some applications.

    Assumptions that need to be tested

    We know that ELB removes unhealthy instances from it’s pool I would expect this to be graceful, so that:

    1. A new connection to a recently closed port will be gracefully redirected to the next node in the pool
    2. When a node is marked Bad, the already established connections to that node are unaffected.

    possible test cases:

    • Fire HTTP connections at ELB (E.g. from a curl script) logging the
      results during scripted opening an closing of one of the nodes
      HTTP ports. You would need to experiment to find an
      acceptable amount of time that allows ELB to always determine a state
      change.
    • Maintain a long HTTP session, (E.g. file download) while blocking new
      HTTP connections, the long session should hopefully continue.

    1. How to block HTTP Connections

    Use a local firewall on nodeX to block new sessions but continue to allow established sessions.

    For example IP tables:

    iptables -A INPUT -j DROP -p tcp --syn --destination-port <web service port>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If I am running more than two instances of a server (using rackspace-cloud's ip
I have a website running on a Windows 2008 R2 server, using a SQL
In their pricing they list iis/sql server only possible under large instances: http://aws.amazon.com/windows/ which
So I have been running the numbers for Azure and RackSpace Cloud Servers and
I have ubuntu instance on Ec2 cloud server and on same instance I have
In a cloud hosting environment (amazon, rackspace,) you can create multiple instances. Let's say
So, I have been playing around with Amazon Cloud (AWS) and I am trying
I have a system that has N servers on the Amazon AWS cloud. They
I have a Rackspace Cloud Server, where I host my site, the problem is
I'm considering migrating from Heroku to Rackspace Cloud Server, but I have few questions.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.