690 shaares
3 liens privés
3 liens privés
Single base
# backup
mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql
# restore
mysql -u root -p[root_password] [database_name] < dumpfilename.sql
All bases :
# backup
mysqldump -u root -ptmppassword --all-databases > /tmp/all-database.sql
# restore
mysql -u root -p[root_password] < dumpfilename.sql
!!! Les schémas doivent être vides avant le restore !!!