Remember RDS database table data accidentally deleted recovery

 

1. Log Ali cloud RDS background, find the "backup" entry, as shown below:

2, download the most recent backup data, as shown below:

3, decompression, find the table mistakenly deleted the data, as shown herein take sys_role :( example)

4, in this machine (Windows systems),

  a. installed MySQL (note, it is best to keep a consistent database version)

  b. Create a consistent database, the database name and database name to be restored

  . C downloaded backup data corresponding to the table (the third step in box selected files) to the local copy of the directory database, as shown below:

 

PS: If the local library table the same name already exists, it needs to be stopped before deleting the MySQL service, otherwise not afford to delete, stop service, as follows :( right stop, start)

 

 5, cover, start MySQL, then, in Navicat or SQLyog and other client tools, execute the following SQL statement: 

  TABLE the ALTER sys_role (you want to restore the table name) DISCARD TABLESPACE;

  TABLE the ALTER sys_role (you want to restore the table name) IMPORT TABLESPACE;

6, and then use the select statement to query the corresponding table will find a data recovery

Key: The above data in this way can only be restored to the point before the RDS backup, data backup before if no misuse can not be restored (of course, can be restored by binlog Kazakhstan)

 Mark it!

 

Guess you like

Origin www.cnblogs.com/swugogo/p/10951292.html