MySQL sync settings
MySQL sync settings affect the database cluster operability and performance. When creating a cluster, the settings are set to default values. Default values are selected to ensure high cluster performance and vary depending on the cluster configuration and the version of MySQL sync.
You can:
- view default settings and change them when creating a cluster;
- or view settings and edit them in an existing cluster.
We recommend changing setting values only when necessary—incorrect values can make the cluster inoperable or reduce its performance.
When scaling a cluster, the values of some settings are automatically replaced with default values. You can view the list of such settings in the Automatic change of settings when scaling a cluster subsection.
View settings
You can view the list of settings available for editing when creating a cluster or editing settings.
If you have changed the settings, you can separately view a list of settings whose values differ from the defaults.
You can find a detailed description of all settings in the The MySQL Server section of the MySQL documentation.
- In the control panel, in the top menu, click Products and select Cloud Databases.
- Open the Active tab.
- Open the cluster page → Settings tab.
- In the DBMS settings block, click Edit.
- Optional: to view only the settings where you changed the default value, select the Show modified parameters checkbox.
- View settings.
Change settings
We recommend changing setting values only when necessary—incorrect values can make the cluster inoperable or reduce its performance.
After changing some settings, the cluster will automatically reboot and will be unavailable during the reboot. The reboot will begin immediately after saving the changes. You can view the list of such settings in the List of settings that require reboot subsection.
- In the control panel, in the top menu, click Products and select Cloud Databases.
- Open the Active tab.
- Open the cluster page → Settings tab.
- In the DBMS settings block, click Edit.
- Specify new values.
- Click Save.
List of settings that require a restart
default_time_zone;innodb_adaptive_hash_index_parts;innodb_autoinc_lock_mode;innodb_buffer_pool_instances;innodb_buffer_pool_load_at_startup;innodb_commit_concurrency;innodb_flush_method;innodb_ft_cache_size;innodb_ft_max_token_size;innodb_ft_min_token_size;innodb_ft_total_cache_size;innodb_ft_sort_pll_degree;innodb_log_buffer_size(only for MySQL semi-sync 5.7);innodb_log_file_size;innodb_page_cleaners;innodb_purge_threads;innodb_read_io_threads;innodb_rollback_on_timeout;innodb_sort_buffer_size;innodb_sync_array_size;innodb_write_io_threads;max_digest_length;table_open_cache_instances;thread_pool_size;thread_stack.
Automatic setting changes during cluster scaling
DBMS settings have limits of allowable values. If, when scaling a cluster, setting values exceed the allowable value limits, such values are automatically replaced with default values so that the cluster can operate.
Once the cluster is scaled and switches to the ACTIVE status, you can change the settings and set new values.
List of settings whose values revert to default during cluster scaling:
innodb_buffer_pool_instances;innodb_buffer_pool_size;innodb_log_file_size(only for MySQL semi-sync 5.7);max_connections;max_heap_table_size;temptable_max_ram;thread_pool_size;tmp_table_size.
Character set and collation settings
The character set (CHARACTER SET or CHARSET) and collation (COLLATION) for the DBMS are defined in the loose_character_set_server and collation_server settings. Default values vary depending on the DBMS version.
You can change the settings when creating a cluster or change the settings in an existing cluster. The character set must be compatible with the collation. You can view compatible values using the command mysql> SHOW COLLATION WHERE Charset = '<charset>', where <charset> is the character set for which you are viewing compatible collations.
For more information about settings and their compatibility, see the Character Sets and Collations in MySQL article in the MySQL documentation.