Recently, one of our customers contacted us to Restore Data from an Amazon RDS Database Snapshot
Here, at Bobcares, we assist our customers with several AWS queries as part of our AWS Support Services.
Today, let us see how we do that.
Restore Data from an Amazon RDS Database Snapshot
There are three ways we can use to restore data from a DB snapshot, Amazon RDS console, AWS CLI, or the Amazon RDS API.
It is possible for us to restore from both manual and automatic DB snapshots.
To do so, we select a DB snapshot to restore from. Then, we provide a name for the new DB instance that is created from the restore.
We must always make sure to create a new DB instance while we restore data from a DB snapshot. Because it is not possible to restore data from a DB snapshot to an existing DB instance.
Moving ahead, our Support Techs recommend the steps below to restore:
- Initially, we sign in to the AWS Management Console and open the Amazon RDS console.
- Then we select Snapshots from the navigation pane.
- We then select the DB snapshot to restore from.
- After that for Actions, we select Restore snapshot.
- In there, for the DB instance identifier, we enter the name for the restored DB instance.
- Finally, we select the Restore DB instance.
Restore using AWS CLI
To restore a DB instance from a DB snapshot, using AWS CLI we use the command, restore-db-instance-from-db-snapshot.
Below is an example where we restore from an existing DB snapshot, mydbsnapshot. We restore it to a new DB instance, mynewdbinstance.
For Linux, macOS, or Unix:
aws rds restore-db-instance-from-db-snapshot \ --db-instance-identifier mynewdbinstance \ --db-snapshot-identifier mydbsnapshot
aws rds restore-db-instance-from-db-snapshot ^ --db-instance-identifier mynewdbinstance ^ --db-snapshot-identifier mydbsnapshot
The output of this command may look like this:
DBINSTANCE mynewdbinstance db.m3.large MySQL 50 sa creating 3 n 5.6.40 general-public-license
[Need help with the restoration? We’d be happy to assist]
In short, we saw how our Support Techs restore data from an Amazon RDS Database Snapshot.