12

AWS provides guidelines as to how to upgrade a MySQL 5.5 instance to MySQL 5.6 using read replicas. However, its final step is to point your application to the new database, but EBS provides no mechanism through the web console to point your application to a different database. What is the recommended path to upgrading EBS-based RDS instances?

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Ed Wolb
  • 198
  • 9
  • Here is what I've attempted and what hasn't worked: - Attempted to create a read replica, to upgrade the read replica, and to start a new instance of my application without an RDS component. I then added a new RDS component and used a snapshot taken from the read replica. This failed indicating that it cannot upgrade my MySQL 5.6 instance to MySQL 5.5. - I attempted to update RDS_HOSTNAME, etc environment variables to point to my read replica to test it out. The connections always failed. – Ed Wolb May 08 '14 at 15:20
  • sounds like you wanted to restore a snapshot of a 5.6 onto a 5.5 instance. Check which engine you selected for the new RDS instance you created from the snapshot – at0mzk May 22 '15 at 07:30
  • @EdWolb I have the same question as you. Unfortunately, at the bottom of this [link](https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/using-features.managing.db.html?icmpid=docs_elasticbeanstalk_console) it states the following: *Do not modify settings on the DB instance outside of the functionality provided by Elastic Beanstalk (for example, in the Amazon RDS console).* – MatayoshiMariano Aug 28 '17 at 18:30
  • You would not typically use the AWS console to point your application to a different database. That is typically done in property files or by some other mechanism in your application. Maybe you can clarify what you mean by "EBS provides no mechanism through the web console to point your application to a different database." ? – Glenn Bech Jan 09 '18 at 09:43

1 Answers1

1

I generally advise users to provision the Database outside of Beanstalk, this issue being one of them.

Also

For a production environment, you may want to launch a database instance outside of your environment and configure your application to connect to it outside of the functionality provided by Elastic Beanstalk.

AWS RDS does support the 5.5 to 5.6 upgrade.

MySQL 5.5 to MySQL 5.6

https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBInstance.MySQL.html

But in your current setup.

  1. Create a snapshot of the RDS database.
  2. Provision an RDS Database outside of Beanstalk based on that snapshot
  3. Provision a new Elastic Beanstalk environment and set these environment properties.

In the Environment Properties section, define the variables that your application reads to construct a connection string. For compatibility with environments that have an integrated RDS DB instance, use the following:

RDS_HOSTNAME – The hostname of the DB instance.

Amazon RDS console label – Endpoint is the hostname.

RDS_PORT – The port on which the DB instance accepts connections. The default value varies between DB engines.

. Amazon RDS console label – Port

RDS_DB_NAME – The database name, ebdb.

Amazon RDS console label – DB Name

RDS_USERNAME – The user name that you configured for your database.

Amazon RDS console label – Username

RDS_PASSWORD – The password that you configured for your database.

https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/AWSHowTo.RDS.html

Community
  • 1
  • 1
strongjz
  • 4,271
  • 1
  • 17
  • 27