Monday, February 5, 2024

MySQL: Updating the Configuration of a MySQL DB System on OCI

 

- Overview:

  • A MySQL configuration is a collection of variables that define the operation of a MySQL DB system. It is analogous to the my.ini or my.cnf files that you use in on-premises MySQL server installation.
  • Each configuration is linked to a shape of the MySQL DB system.
  • There are two types of configuration:
    • Default Configuration are defined in MySQL Database service and designed for a specific shape and contains a default set of configuration variables.
    • Custom Configuration are user defined.
  • Types of Configuration Variables:
    • System variables are not user configurable. For the same shape, there are different configurations for standalone and HA.
    • User variables are those variables that you can edit when create or copy a configuration.
    • Initialization variables apply for the life span of the MySQL instance and, once you apply it, you cannot change it later. There is currently only one initialization variable lower_case_table_name 
    • Service-specific variables are those variables that are specific only to MySQL database OCI service. Currently there are two variables:
      • thread_pool_dedicated_listeners
      • thread_pool_max_transactions_limit
  • Updating DB system configuration to a new config that contains only dynamic user variables does not require DB system restart. 

In this blog, I'll demonstrate the steps to update the configuration of an existing MySQL DB system to use another MySQL configuration (MyConfig3) from the OCI console. 

 - Prerequisites:


 - Limitations:
  • You cannot update/select a configuration that change initialization variables of a DB system.

Steps to Update a MySQL DB System Configuration

1. Sign in to the OCI console.
2. Open the navigation menu and navigate to "Databases -> DB Systems".


















3. Choose your compartment. The list of MySQL DB system is displayed. Click your DB system name.














4. In DB system details page and under DB system configuration section, click Edit next to Configuration option.





















5. In "Edit DB system" window and under Configuration section, click "change configuration" button.













6. In the Browse configurations window, select MyConfig3 from the list.




















Note: in my example selecting MyConfig2 is not an option because it attempts to change the initialization variables of the DB system.



















7. Once you select the new config, Edit DB system window will show the name of new config and a compare configurations table that shows variables compares. Click "save changes" buttons. 














8. DB system status will be UPDATING, but the database will NOT restart because all changed variables are dynamic.
















9. Once update finishes, the configuration name will be changed to new config.



No comments:

Post a Comment

Oracle 23ai: Quick Overview

  Oracle Database 23ai Oracle database 23ai is the next long-term support release of Oracle database. It brings AI to your data with the ad...