Skip to main content

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

  1. Open the NineData Registration Page. registration

  2. Enter your phone number and click Get Verification Code, then enter the verification code sent by the NineData system after receiving it.

    tip

    Only 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.

  3. Enter your username and password.

    tip

    The 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).

  4. Enter your email and company name, read the Terms of Service and Privacy Policy carefully, then check the box in front of , and click .

    tip

    If you have already entered your email in the above steps, you do not need to enter it again.

Step Two: Log in to NineData

  1. Open the NineData Login Page. login

  2. 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.

Step Three: Apply for Two Test Data Sources

  1. In the NineData console, click on the left navigation bar , and click on the page.

    tip

    New 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.

  2. On the page, select the number of data sources under , up to 2.

  3. 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 .

    tip

    You can also click the download 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

  1. In the NineData console, click on the left navigation bar .

  2. On the page, click in the upper right corner.

  3. 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.

    backup_step1

  4. On the tab, select the object to be backed up (in this example, sample_employees_4375), and then click .

    backup_step2

  5. On the tab, click .

    tip

    If 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.

    backup_step3

  6. On the page, you will be prompted with , click to perform a backup immediately.

    backup_step4

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.

  1. In the NineData console, click on the left navigation bar .

  2. Under the tab, select the data source and backup set that was completed in Step Four, and click .

    backup_query_step1

  3. 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.

    backup_query_step2

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.

  1. In the NineData console, click on the left navigation bar .

  2. Find the backup set created in Step Four, and click in the column on the right.

  3. The browser automatically jumps to the page, add Task Name, select 02-ninedata-sample-datasource in , and click .

    restore_step1

  4. On the tab, click .

  5. On the tab, configure the database name after recovery to the target data source as needed, and click .

  6. On the tab, click , wait for the recovery to complete, and you can click to view the progress of the task.

    tip

    If 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.