|
|
Backup and recovery in MySQL - Mysql
|
Views : 1660
|
|
Tagged in : Mysql
|
|
|
Report This Scrap as Inappropriate We request you to choose the appropriate categroy and subcategory that suits your
objectionable concern about the scrap, So that our team can review and find out whether it violates our Guidelines or the
scrap is not suitable for all viewers.
|
MySQL is packed with many of utilities which simplifies the back-up and recovey.
BACK-UP:
The Utility used for Back-up any of database in mysql is ---'mysqldump'.We can make back-up even for single table
The following command is used for back-up:
> mysqldump -u [username] -p -h [hostname] [database-name (or) database-name.table-name] > [backup-file].sql
eg: > mysqldump -u root -p -h localhost db1.ta1 > db1.sql
RECOVERY:
The following command is used for Recovery:
> mysql -u [username] -p -h [hostname] [database-name (or) database-name.table-name] < [backup-file].sql
eg: > mysql -u root -p -h localhost db1.ta1 < db1.sql
|
|
By Selva, On - 2008-03-12 |
|
|
|