Step-by-Step Guide to Quickly Back Up and Restore MySQL Data
This article will introduce you from scratch on how to back up MySQL databases, query backup sets, and restore backup sets to another MySQL database through NineData's backup and recovery features.
Please select your scenario to jump to the operation steps that suit you:
Step One: Register for a NineData Account
Open the NineData Registration Page.
Enter your phone number and click Get Verification Code, then enter the verification code sent by the NineData system after receiving it.
tipOnly phone numbers from Mainland China are currently supported. If you are using a phone number outside the +86 area, you can only receive the verification code via email.
Enter your username and password.
tipThe password strength requirements are as follows:
The password can contain English letters, numbers, and special characters.
Length is 8~16 characters.
Must contain both English letters and numbers.
Cannot contain empty characters (spaces).
Enter your email and company name, read the Terms of Service and Privacy Policy carefully, then check the box in front of , and click .
tipIf you have already entered your email in the above steps, you do not need to enter it again.
Step Two: Log in to NineData
Open the NineData Login Page.
You can choose to log in through , , , or .
- : Enter the phone number or email used during registration, and enter the password, then click .tip
- If you are using a phone number outside the +86 area, you cannot log in through the phone number. Please use the email used during registration to log in.
- If you have forgotten your login password, you can click in the lower right corner to .
- Click , enter the phone number used during registration, click , and enter the verification code sent by the NineData system, then click .tip
If you are using a phone number outside the +86 area, please enter the email used during registration to receive the verification code.
: Log in to NineData through SSO. For more information, please refer to Log in to NineData via SSO.
- : Log in to NineData by scanning the WeChat QR code.
- : Enter the phone number or email used during registration, and enter the password, then click .
Step Three: Apply for Two Test Data Sources
In the NineData console, click on the left navigation bar , and click on the page.
tipNew users can also click on the page after logging in. This entry is only displayed when the current user or organization has not added any data sources.
On the page, select the number of data sources under , up to 2.
Click to complete the application for a free data source, and you will be redirected to the page of the data source. The system will start importing the test dataset, which will take about 30 seconds. After the import is complete, the SQL Console will prompt .
tipYou can also click the icon in the upper right corner of the SQL Console page, and click to manually import the test dataset.
Step Four: Create a Backup Task
In the NineData console, click on the left navigation bar .
On the page, click in the upper right corner.
On the page, configure according to the table below and click .
Parameter Description Enter the name of the backup task. To facilitate subsequent searching and management, please use a meaningful name. Up to 64 characters are supported. Select 01-ninedata-sample-datasource. Select . Choose the storage location for the backup data. Please select according to the location of the data source. On the tab, select the object to be backed up (in this example,
sample_employees_4375
), and then click .On the tab, click .
tipIf the check does not pass, you need to manually investigate the items that did not pass, and then reconfigure the backup task according to this operation step.
On the page, you will be prompted with , click to perform a backup immediately.
Step Five: Query Backup Data
After the data backup is completed, you can directly use SQL statements to query the content in the backup set.
In the NineData console, click on the left navigation bar .
Under the tab, select the data source and backup set that was completed in Step Four, and click .
On the visual query page, right-click the target table, click , and the query statement will be automatically generated, with the query results displayed in the results below. You can also manually enter a query SQL statement to perform more complex queries as needed.
Step Six: Create a Recovery Task
Now, we will restore the backup file of the 01-ninedata-sample-datasource
data source to another data source 02-ninedata-sample-datasource
.
In the NineData console, click on the left navigation bar .
Find the backup set created in Step Four, and click in the column on the right.
The browser automatically jumps to the page, add Task Name, select
02-ninedata-sample-datasource
in , and click .On the tab, click .
On the tab, configure the database name after recovery to the target data source as needed, and click .
On the tab, click , wait for the recovery to complete, and you can click to view the progress of the task.
tipIf the check does not pass, you need to manually investigate the items that did not pass, and then reconfigure the backup task according to this operation step.