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 8169967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T21:01:07+00:00 2026-06-06T21:01:07+00:00

The setup: EC2 servers autoscaling behind ELB, connecting to RDS mysql database, all static

  • 0

The setup: EC2 servers autoscaling behind ELB, connecting to RDS mysql database, all static files served from cloudfront.

I’m running nginx as the web server on the EC2 servers, keepalive set to 20, worker processes 4, . Codeigniter is the backend and using codeigniter sessions.

I’ve been running lots of benchmarks to attempt to test the performance, siege, apache benchmark, blitz.io.

I’m testing two particular pages, the first performance is extremely good, it uses codeigniter sessions so hits the database to read and update the ci_sessions database. The second page is the one I’m having trouble with, it runs a query with several joins which complete in roughly 0.4 seconds with a single user. This query is optimised, and I’m using InnoDB tables. Under apache benchmark with c10 and n1000 100% of requests come back within 634 ms.

When I run concurrent users > 200 I start running into problems. Adding more EC2 servers doesn’t help, the CPU’s are around 50% utilised. The RDS database monitoring shows also the CPU and memory usage is less than 70%, and the average DB connections is < 35.

Performance has been improved by moving to a large RDS instance and large EC2 instances, this makes me wonder whether I/O is coming into play here.

If I boot up a server outside of the ELB during load tests and hit this page it comes back in less than a second, but if I fire up another server within the ELB it remains up to 4 or 5 seconds. This suggests that I’m not overloading the RDS.

I tried ramping up the ELB slowly with 5 minute bursts and this didn’t seem to help.

I’m wondering where to look next for this problem, whether it’s some kind of I/O issue or something else because the RDS, and EC2 servers don’t seem pushed to their capabilities. Any suggestions or ideas where to look next would be much appreciated

  • 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-06-06T21:01:08+00:00Added an answer on June 6, 2026 at 9:01 pm

    Okay. Well this is a very broad subject as you know. But I will try and help.

    1. The ELB is generally not very good at burst scaling. After speaking with Amazon engineers about this, I figured out they actually won’t scale the ELB on bursts because it is not possible. You need to have consistent load over time to get the ELB scaled up. Because of this, I switched to haproxy. In addition to the ELB not scaling on burst load, it also uses a CNAME for the DNS lookup which is going to affect your performance as well. So if you are planning on having burst load often, or demanding DNS lookup, probably best to get off the ELB.

    2. RDS is a black box. Well that is not totally true, but in general I avoid RDS unless I know the backend is a simple setup that is easy to scale. Having said that, RDS does help with scaling, but I would dumb down the backend and ensure your query runs quickly. Run it on a regular MySQL instance and see if it is subsecond. In my experience, when you say the query is “optimized” that doesn’t really mean there is not another way to make it more “optimized” if you catch my drift.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have about ten amazon ec2 servers all constantly writing to my mysql database
I have setup a mysql database on a linux server on Amazon's EC2. This
I have set up my EC2 infrastructure behind an ELB instance and by using
I have been tasked with porting data from a MongoDB database to a MySQL
I want to setup seperate amazon ec2 instance where i store all my images
I trying to navigate my new EC2 setup and was hoping to find an
setup.py from distutils.core import setup import py2exe setup(console=['program.py']) The error Traceback (most recent call
Setup I am using custom Forms Authentication - all standard stuff. In the Login
I have previously setup a EC2 instance on Ubuntu 10.04 and setup the necessary
I have successfully setup my MySQL server to support SSL connections I'm just wondering

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.