Backup of MySQL Database

Source: Internet
Author: User

MySQL Tutorial Database Tutorial Backup

Using the MySQL database, the most common and most important is the database backup, so we first introduced the database backup. For database backup, also very formal database backup method, with other database servers have the same concept, but have you ever thought that MySQL will have a simpler use of the file directory backup method, but also quick to have good (this method has not been the official official document verification, we tentatively called the Test bar).

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,php Tutorial MyAdmin 2.1.0;
Install MySQL database in hosta and establish Testa database;
HOSTB machine installed MySQL database, no testa database.

Method steps:

1, start phpMyAdmin to see the list of databases in Hosta and HostB, there is no Testa database in HostB;

2, find the hosta MySQL installation directory, and find the database directory data;

3, in my test environment, this directory is c:mysqldata;

4, find the corresponding database name subdirectory C:mysqldatatesta;

5, paste copy to the HOSTB of the data directory, is hosta with the HostB MySQL directory of the same files;

6, refresh HostB phpmyadmin look at the list of databases, we see that Testa has appeared, and make query modifications and other operations are normal, backup restore success.

Test conclusion: MySQL database can be saved, backed up, restored by file, as long as the corresponding file directory restore, no need to use other tools to back up.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.