3

We had a AWS Aurora MySQL RDS DB Cluster (say my-dbcluster) & DB Instance (say my-instance) setup. However due to some issue the DB instance got deleted. We do have backup at the cluster level and I could see those in AWS Console under my-dbcluster -> Maintenance & backups tab -> Snapshots section.

Based on the AWS documentation to Restore from DB snapshot, it should allow to create the DB instance by restoring from the DB snapshot. So on the AWS Console I went on to select the latest snapshot and try to Restore by providing the original DB Instance Identifier and other details. My expectation was that it will create the DB instance under the same DB Cluster (i.e. my-dbcluster) but it created altogether a new DB Cluster and created the DB instance under that. I tried to look for ways to move the DB Instance under the original DB cluster but could not find anything.

My question is, why it does not create/restore the DB Instance under the original DB Cluster, if this is not the default behavior, it should at least give an option to restore the DB instance under the DB Cluster of our choice. How can I achieve that.

1 Answer 1

4

Restoring to existing DB is not supported. From docs:

You can't restore from a DB cluster snapshot to an existing DB cluster; a new DB cluster is created when you restore.

You could use mysqldump to get data from your new cluster and import to existing one.

Sign up to request clarification or add additional context in comments.

6 Comments

Thanks Marcin. so a new DB instance is fine, I don’t even have the old one but can it not create new DB instance under existing DB cluster?
@KuldeepJain Sorry. I quoted wrong docs, for RDS, not aurora. fixed. So in aurora you get new cluster as a whole.
thanks. So for connecting to this DB, we had earlier used the Endpoint name (of Writer instance) from the DB Cluster which still shows on the old DB cluster now. And even though the new DB instance is created under new DB cluster, our connectivity is still working fine without changing anything on the application side. How is that?
@KuldeepJain I don't know. To restore you had to provide dbname. Maybe you provided same one?
yes, I had provided same db instance id, but db name and db instance endpoint are also same as previous one. What’s intriguing is that even when cluster level instance endpoint is used to connect to the db. It is working fine, hence I was wondering where is the linking between new db instance and old db cluster.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.