4

I'm planning to run a PHP/MySQL application using Amazon Elastic Beanstalk. In the settings I can define when it should launch new instances automatically (Auto-Scaling).

However, as I understand this, this only creates new EC2-Instances and does not touch the RDS-Data-Layer (which I also configured in the settings).

Is there any way to auto-scale this RDS, with automated Read-Replicas or database size upgrade, or do I have to do this manually in some way?

David
  • 51
  • 1
  • 3

2 Answers2

2

Today we faced that problem.

We launched a mobile app that report continuously data to be saved in RDS MySQL, this resulted in a high performance impact, we were using db.t2.micro to take advantage the free tier.

I can confirm, Elastic Beanstalk does not autoscale RDS. However, the environment were re-configured and set other server for RDS, db.m3.medium, the process was smooth from the users, the database was able to continue serving read/write queries and the server was upgraded without downtime.

So, There is a way to perform a manual, but fast and easy scale, but there is not auto-scale.

Programatically, I think you can make some script to monitor your databases and do:

aws elasticbeanstalk --update-environment --environment-name <your-env-name> --option-settings Namespace=aws:rds:dbinstance,OptionName=DBInstanceClass,Value=db.m1.small
Jose Nobile
  • 451
  • 1
  • 5
  • 14
1

No, Elastic Beanstalk can only create new RDS instances (and I think that even this can only be done through the web interface). Elastic Beanstalk really only manages EC2 instances and does not directly manage RDS.

Note that RDS "scaling" is not seamless; an instance size change will result in some downtime as the underlying EC2 instance that the RDS DB is running on is basically being shut down and restarted.

Ken Liu
  • 155
  • 1
  • 9