This topic describes how to modify and query parameters and system variables in OceanBase Database, and highlights the differences between parameters and system variables. For more information, see Parameters and system variables.
Parameters
You can set parameters to control features such as load balancing, major compactions, resource allocation, and module switching in a cluster. OceanBase Database supports cluster-level and tenant-level parameters.
Cluster-level parameters: These are configuration options that apply to the entire OceanBase cluster. They are global in nature and are used to configure basic information, performance parameters, and security options for the entire cluster. These parameters typically include options for data backup and restore, load balancing, etc. Cluster-level parameters are usually configured when the cluster is started, and they are not changed easily.
Tenant-level parameters: These are configuration options that apply to individual tenants or multiple tenants. They are used to configure and optimize individual tenants or multiple tenants. These parameters typically include options for storage engine parameters, SQL execution strategies, and access control. Tenant-level parameters can be configured when tenants are created and managed, and they can be changed as needed.
System variables
OceanBase Database supports global variables and session variables.
Global variables: These are variables that apply to the entire database. Different users within the same tenant share global variables. Changes to global variables do not take effect on currently open sessions until a new session is established.
Session variables: These are variables that apply to the current session. After a client connects to the database, the database automatically generates session variables based on global variables. Changes to session variables only take effect on the current session.