CPU parameters

2025-11-13 06:13:17  Updated
Parameter Description Recommended value/range
work_thread_num The number of OceanBase Database Proxy (ODP) worker threads, which has a significant impact on CPU utilization. The default value is 128. The parameter takes effect upon ODP restart after modification. You can adjust the value dynamically based on the environment. work_thread_num specifies the maximum CPU utilization allowed for ODP.
task_thread_num The number of threads for some background tasks, such as pulling rslist information. The default value is 2. The parameter takes effect upon ODP restart after modification. We recommend that you use the default value.
block_thread_num The number of block threads. The default value is 1. The parameter takes effect upon ODP restart after modification. We recommend that you use the default value.
grpc_thread_num The number of grpc threads. The default value is 8. The parameter takes effect upon ODP restart after modification. We recommend that you use the default value.
net_accept_threads The number of threads that run accept tasks. The default value is 2. The parameter takes effect upon ODP restart after modification. We recommend that you use the default value.
automatic_match_work_thread Specifies whether to ignore the specified work_thread_num and to automatically adjust the number of threads based on the number of CPUs. If this parameter is set to true, the value of work_thread_num is used as the maximum number of threads. The default value is true. The parameter takes effect upon ODP restart after modification. If an ODP and an OBServer node are deployed together, CPU contention may occur. In this case, we recommend that you disable this feature. If the ODP is deployed separately, we recommend that you enable this feature.
enable_compression_protocol Specifies whether to enable compression. If compression is disabled, the CPU utilization of ODP can be reduced. The parameter takes effect upon ODP server restart after modification. We recommend that you set it to False.

Note

This parameter is deprecated starting from V4.3.4 of ODP.

You can connect to an OceanBase cluster through port 2883 of ODP under the sys tenant and use the ALTER PROXYCONFIG SET and SHOW PROXYCONFIG LIKE statements to modify and view the preceding parameters.

Here is an example:

obclient> ALTER PROXYCONFIG SET automatic_match_work_thread = False;
obclient> SHOW PROXYCONFIG LIKE 'work_thread_num';

Contact Us