Use MySQL for database backup, there is a very formal method of database backup, and other database servers have the same concept, but have not thought that MySQL will have a simpler use of the file directory backup method, but also quick to have good.
One, the data backup shortcut
Since this method has not been validated by official documents, we are tentatively called experiments.
Objective: To backup a MySQL database in the Hosta host Testa and revert to the HOSTB machine
Test environment:
Operating system: Winnt4.0,mysql3.22.34,phpmyadmin 2.1.0 Chinaz
Install MySQL database in hosta and build Testa database
HOSTB machine installs MySQL database, no testa database
Method steps:
Start phpMyAdmin View the list of databases in Hosta and HostB, and there are no Testa databases in HostB
Locate the MySQL installation directory in Hosta and locate the database directory data
In my experimental environment, this directory is
C:\MySQL\data
Find a subdirectory of the corresponding database name
C:\MySQL\data\TestA
Paste copy into HostB's data directory, which is the same as the Hosta file in the HostB MySQL directory
Refresh HostB phpMyAdmin Look at the list of databases, we see that Testa has already appeared, and make a query to modify the operation is normal, backup restore success
Test conclusion: MySQL database can be saved by file, backup, restore as long as the corresponding file directory restore, no need to use other tools to back up.
Current 1/2 page
12 Next read the full text