All Products
Search
Document Center

Database Backup:Performance tests on backup and restoration

Last Updated:Dec 11, 2023

This topic describes the performance tests on the backup and restoration feature of Database Backup (DBS) backup schedules to help you better understand the performance of each DBS instance type.

Note
  • The test outcomes are intended to serve as a guide for your instance type selection and should not be used to assess the accomplishments of service-level agreements.

  • The test outcomes may vary based on different business scenarios.

Logical backup and restoration

Test procedure

  1. Prepare an ApsaraDB RDS for MySQL instance.

  2. Create a logical backup schedule in the DBS console and start full backup and incremental backup tasks to back up data from the ApsaraDB RDS for MySQL instance to DBS.

  3. Then, restore the backup data to the ApsaraDB RDS for MySQL instance. Check the performance of data backup and restoration during this period.

Test environment

Item

Configuration

Database type

General-purpose ApsaraDB RDS for MySQL

Memory

2,400M

CPU

8 vCPUs

IOPS

1,200

Test data

Test data

Description

Example

Database size

The total size of the test database. Unit: GB.

102 GB

Total number of entries

The total number of entries in all tables in the test database.

0.15 billion

Single record size

The size of one record in the test database. Unit: KB.

1 to 100 KB

Number of fields

The number of fields or columns in a record in the test database.

3 to 22 columns

Field types

The field types in a record in the test database. Basic MySQL field types such as INT, VARCHAR, and DATATIME are included.

Overrides basic MySQL field types.

Test outcomes

Full data backup

Instance type

RPS

Mbit/s

large

42,855.7

15.3

medium

33,122.2

11.8

small

9,569.3

3.4

micro

6,756.2

1.9

Note
  • If the source database contains a large number of tables, a lot of time is taken to initialize the tables during backup and restoration. We recommend that you specify a source database that contains no more than 10,000 tables.

  • The backup process also takes a long time if a table in the source database does not have a primary key, if the primary key of the table is of the String type, or if the table uses a composite primary key.

Incremental backup

Instance type

Mbit/s

large

46.1

medium

29.8

small

14.9

micro

5.0

Full restoration

Instance type

RPS

large

34,190.5

medium

19,740.9

small

9,949.4

micro

4,320.2

Incremental restoration

Instance type

Instance type

large

35,546.9

medium

21,331.4

small

10,061.5

micro

4,972.1

Physical backup and restoration

Test procedure

  1. Prepare a self-managed MySQL database.

  2. Create a physical backup schedule in the DBS console and start full backup tasks to back up data from the database to DBS.

  3. Then, restore the backup data to a specified directory. Check the performance of data backup and restoration during this period.

Note

DBS reads physical files of MySQL databases in streaming mode, and uses multiple streams to concurrently write backup data to the built-in storage. DBS allows you to adjust the number of concurrent backup streams based on DBS specifications. Higher specifications provide a faster backup speed. Compression algorithms gzip and LZ4 are supported. gzip provides a higher compression ratio and LZ4 provides a faster backup speed.

Test data

Test data

Description

Example

Database size

The total size of the test database. Unit: GB.

40.3 GB

Total number of entries

The total number of entries in all tables in the test database.

2 billion

Number of tables

The number of tables in the test database.

160

Single record size

The size of one record in the test database. Unit: KB.

0.2 KB

Test outcomes

Full data backup

Instance type and compression format

Time consumed

Backup speed

Size of compressed file

small (4 threads) gzip

636s

63 MB/s

21.1 GB

large (8 threads) gzip

341s

118 MB/s

21.1 GB

xlarge (16 threads) gzip

204s

197 MB/s

21.1 GB

small (4 threads) LZ4

268s

150 MB/s

31.1 GB

large (8 threads) LZ4

119s

338 MB/s

31.1 GB

xlarge (16 threads) LZ4

104s

387 MB/s

31.1 GB

Full restoration

Instance type and compression format

Amount of compressed data

Time consumed

Restoration speed (relative to the original data amount)

small (4 threads) gzip

21.1 GB

320s

126 MB/s

large (8 threads) gzip

21.1 GB

161s

250 MB/s

xlarge (16 threads) gzip

21.1 GB

86s

468 MB/s

small (4 threads) LZ4

31.1 GB

408s

99 MB/s

large (8 threads) LZ4

31.1 GB

208s

194 MB/s

xlarge (16 threads) LZ4

31.1 GB

108s

373 MB/s