mysql table 복구 예

리눅스/MySQL|2015. 1. 16. 10:47
반응형

mysql> check table myboard;

+---------------------+-------+----------+--------------------------------------
| Table               | Op    | Msg_type | Msg_text
+---------------------+-------+----------+--------------------------------------
| sysdocu.myboard | check | warning  | Table is marked as crashed
sysdocu.myboard | check | warning  | 1 client is using or hasn't closed th
| sysdocu.myboard | check | error    | Size of datafile is: 8323072
| sysdocu.myboard | check | error    | Corrupt

+---------------------+-------+----------+--------------------------------------
4 rows in set (0.02 sec)



mysql> repair table myboard;
+---------------------+--------+----------+-------------------------------------------------------+
| Table               | Op     | Msg_type | Msg_text                                              |
+---------------------+--------+----------+-------------------------------------------------------+
sysdocu.myboard | repair | info     | Found block that points outside data file at 8322744  |
sysdocu.myboard | repair | info     | Found block with too small length at 8322772; Skipped |
sysdocu.myboard | repair | status   | OK                                                    |
+---------------------+--------+----------+-------------------------------------------------------+
3 rows in set (0.50 sec)



mysql> check table myboard;
+---------------------+-------+----------+----------+
| Table               | Op    | Msg_type | Msg_text |
+---------------------+-------+----------+----------+
sysdocu.myboard | check | status   | OK       |
+---------------------+-------+----------+----------+
1 row in set (0.10 sec)


반응형

댓글()