Backup your Wordpress Database!!!
By default, mysqldump writes information as
SQL statements to the standard output. You can save the output
in a file:
To dump all databases, invoke mysqldump with
the
To dump only specific databases, name them on the command line
and use the
Alternatively, from within mysql, use a
If the file is a single-database dump not containing
Then specify the database name when you load the dump file:
shell> mysqldump [arguments] > file_name
--all-databases option:
shell> mysqldump --all-databases > dump.sql
--databases
option:
shell> mysqldump --databases db1 db2 db3 > dump.sql
To reload a dump file written by mysqldump
that consists of SQL statements, use it as input to the
mysql client. If the dump file was created by
mysqldump with the
--all-databases or
--databases option, it
contains CREATE DATABASE and
USE statements and it is not
necessary to specify a default database into which to load the
data:
shell> mysql < dump.sql
source command:
mysql> source dump.sql
CREATE DATABASE and
USE statements, create the
database first (if necessary):
shell> mysqladmin create db1
shell> mysql db1 < dump.sql
Comments
Post a Comment