Help Center> GaussDB(for MySQL)> User Guide> Instance Modifications> Changing vCPUs and Memory of a DB Instance
Updated on 2024-03-01 GMT+08:00

Changing vCPUs and Memory of a DB Instance

Scenarios

You can change the vCPUs and memory of a yearly/monthly or pay-per-use DB instance if needed. If the status of a DB instance changes from Changing instance specifications to Available, the change was successful.

You can scale up or down your instance specifications.

Constraints

  • A DB instance cannot be deleted when its specifications are being changed.
  • The vCPUs and memory can be changed only at the instance level. It means that the specifications of the primary node or read replicas cannot be changed separately for a given instance.
  • Instance specifications can only be changed from the general-purpose edition to the dedicated edition.
  • You can change the specifications of yearly/monthly or pay-per-use DB instances immediately or during a maintenance window. Serverless DB instances do not support specification changes.
  • If you want to change instance specifications during a maintenance window, you can cancel the task before it starts. Once started, the task cannot be canceled.
  • Changing instance specifications will cause a primary/standby switchover. To prevent service interruptions, change the instance specifications during off-peak hours.
  • The time required for modifying specifications depends on factors such as the number of nodes, database load, and number of database tables.
  • Changing instance specifications will change the private IP addresses for read of the primary node and read replicas. The connection addresses in your application need to be changed to prevent your services from being affected. You are advised to use the private IP address of a DB instance to connect your application.

Procedure

  1. Log in to the management console.
  2. Click in the upper left corner and select a region and a project.
  3. Click in the upper left corner of the page, choose Databases > GaussDB(for MySQL).
  4. Change the instance specifications in either of the following ways:

    • On the Instances page, locate the instance for which you want to change specifications and choose More > Change Instance Specifications in the Operation column.
    • Alternatively, click the instance name to go to the Basic Information page. In the DB Instance Information area, click Change next to the Instance Specifications field.

  5. On the displayed page, select new specifications as required and the scheduled time, and click Next.

    Choose either of the following scheduled time:

    • Upon submission: The instance specifications will be changed immediately after the task is submitted.
    • In maintenance window: The instance specifications will be changed during the maintenance window you specify.

  6. On the displayed page, confirm the instance specifications.

    • If you need to modify your settings, click Previous to go back to the page where you specify details.
    • For pay-per-use instances, click Submit.

      To view the cost incurred by the instance specifications change, choose Billing Center > Billing Dashboard in the upper right corner.

    • For yearly/monthly instances:
      • Scaling down the instance specifications: click Submit.

        The refund is automatically returned to your account. You can click Billing Center in the upper right corner and then choose Orders > My Orders in the navigation pane on the left to view the details.

      • Scaling up the instance specifications: click Submit. The scaling starts only after the payment is successful.

  7. View the results.

    Changing the instance specifications takes 5–15 minutes. During this period, the status of the instance on the Instances page is Changing instance specifications. After a few minutes, you can click the instance name to view the new instance specifications on the displayed Basic Information page.

    • After the instance specifications of GaussDB(for MySQL) 8.0 are changed, the system will change the values of the following parameters accordingly: innodb_buffer_pool_size, innodb_log_buffer_size, max_connections, innodb_buffer_pool_instances, innodb_page_cleaners, innodb_parallel_read_threads, innodb_read_io_threads, innodb_write_io_threads, and threadpool_size.
    • The default value of innodb_parallel_select_count is OFF for instance with 16 vCPUs or less and ON for instances with more than 16 vCPUs.

      If you have modified value of the parameter, the parameter value remains unchanged after the specifications are changed, or the default value is used.