Help Center> Distributed Database Middleware> Best Practices> Determining the Number of RDS DB Instances

Determining the Number of RDS DB Instances

  1. Evaluate the database performance metrics required, for example, storage capacity, database throughput, and maximum number of database connections.
  2. Select appropriate RDS DB instance specifications. The following example assumes that the RDS DB instance specifications are 8 vCPUs and 32 GB.
  3. Calculate the minimum number of RDS DB instances required by each metric, which is the minimum value of Number of RDS DB Instances for a Single Metric (Example) in Table 1.
    Table 1 Calculation of metrics

    Single Metric

    General Baseline (Example)

    Baseline for a Single RDS DB Instance (Example)

    Number of RDS DB Instances for a Single Metric (Example)

    Reference Calculation Method

    {Total storage capacity}

    2000 GB

    500 GB

    4

    {Total number of records} x {Number of bytes occupied by a single record}

    {Throughput or QPS}

    40,000

    23,000

    2

    {Maximum number of supported requests per second} x {Number of database attempts of a single request}

    ...

    ...

    ...

    ...

    ...

  4. Calculate the number of RDS DB instances.

    Calculate the maximum number of RDS DB instances required by each metric, which is the maximum value of Number of RDS DB Instances for a Single Metric (Example) in Table 1. The upper limit is 100.

    • If the data volume in an unsharded table is greater than 10 million entries, you are advised to split the data. Otherwise, query efficiency may be negatively affected.
    • When planning the RDS DB instance storage capacity, you are advised to base your decisions on the expected data volume for the next one or two years.
    • If the query concurrency pressure is high, you can add read replicas to RDS DB instances.

      Select an RDS DB instance on Cloud Eye and view its CPU and memory usage to determine the concurrency pressure.

    • If the overall service throughput or the RDS DB instance resource usage is high, you can add RDS DB instances to improve the parallel computing capabilities of databases.