Backup mysql database to a sql file.
$ mysqldump -u root -p[root_password] [database_name] > filename.sql
Restore from sql file to database.
$ mysql -u root -p[root_password] [database_name] < filename.sql
$ mysqldump -u root -p[root_password] [database_name] > filename.sql
$ mysql -u root -p[root_password] [database_name] < filename.sql
0 comments:
Post a Comment