Skip to content

Instantly share code, notes, and snippets.

@sakthivelsekar33
Last active October 13, 2015 01:28
Show Gist options
  • Save sakthivelsekar33/4117721 to your computer and use it in GitHub Desktop.
Save sakthivelsekar33/4117721 to your computer and use it in GitHub Desktop.
Database dump and restore command
backup:
mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql
restore:
mysql -u root -p[root_password] [database_name] < dumpfilename.sql
Fastest way to restore:
go to mysql i.e., mysql -u root -p password
select the database i.e., use my_database;
then source it,
source /home/revlap/Projects/revlogic_cms/db/revlogic_cms_development_20130501.sql
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment