Pages

Bài đăng phổ biến

Showing posts with label backup database mysql. Show all posts
Showing posts with label backup database mysql. Show all posts

Sunday, November 13, 2011

How to restore or backup database mysql by cmd (command)


Restore
mysql -u user_name -p your_password database_name < file_name.sql
 gzip -dc <database.sql.gz |mysql -u root -p databasename

Backup
mysqldump -u user_name -p your_password databasename > file_name.sql
mysqldump -u user_name -p databasename | gzip > database.sql.gz

Nguyen Si Nhan