I accidentally deleted my Amazon RDS for MySQL instance
Last updated: 2021-08-27
What do I do if I accidentally delete my Amazon Relational Database Service (Amazon RDS) for MySQL instance? How can I prevent this from happening again?
Resolution
If you've accidentally deleted your Amazon RDS for MySQL instance, you can use an earlier snapshot of the DB instance to restore the instance.
To restore a DB instance from a snapshot in Amazon RDS, perform the following steps:
1. Open the Amazon RDS console.
2. In the navigation pane, choose Snapshots.
3. Choose the DB snapshot that you want to restore from.
4. For Actions, choose Restore snapshot.
5. On the Restore snapshot page, for DB instance identifier, enter the name of your restored DB instance.
6. Choose Restore DB instance.
Additionally, consider the following best practices to prevent any future incidents where your instance is accidentally deleted:
- Enable delete protection. When a DB instance or cluster is configured with deletion protection, the database can't be deleted by any user.
- Enable cross-Region replication for automated backups. Automated backups that are replicated to another AWS Region are retained even if you choose not to retain automated backups.
Note: Backup replication is available for Amazon RDS DB instances that are running the following database engines: Oracle Database version 12.1.0.2.v10 and higher, PostgreSQL version 9.6 and higher and unencrypted Microsoft SQL Server version 2012 and higher. - Automate manual snapshots of the Amazon RDS instance.
- Create a final snapshot and retain any automated backups.
Related information
Did this article help?
Do you need billing or technical support?