OceanBase logo

OceanBase

A unified distributed database ready for your transactional, analytical, and AI workloads.

DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Resources

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS

OceanBase Cloud

OceanBase Database

Tools

Connectors and Middleware

QUICK START

OceanBase Cloud

OceanBase Database

BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Company

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

International - English
中国站 - 简体中文
日本 - 日本語
Sign In
Start on Cloud

A unified distributed database ready for your transactional, analytical, and AI workloads.

DEPLOY YOUR WAY

OceanBase Cloud

The best way to deploy and scale OceanBase

OceanBase Enterprise

Run and manage OceanBase on your infra

TRY OPEN SOURCE

OceanBase Community Edition

The free, open-source distributed database

OceanBase seekdb

Open source AI native search database

Customer Stories

Real-world success stories from enterprises across diverse industries.

View All
BY USE CASES

Mission-Critical Transactions

Global & Multicloud Application

Elastic Scaling for Peak Traffic

Real-time Analytics

Active Geo-redundancy

Database Consolidation

Comprehensive knowledge hub for OceanBase.

Blog

Live Demos

Training & Certification

Documentation

Official technical guides, tutorials, API references, and manuals for all OceanBase products.

View All
PRODUCTS
OceanBase CloudOceanBase Database
ToolsConnectors and Middleware
QUICK START
OceanBase CloudOceanBase Database
BEST PRACTICES

Practical guides for utilizing OceanBase more effectively and conveniently

Learn more about OceanBase – our company, partnerships, and trust and security initiatives.

About OceanBase

Partner

Trust Center

Contact Us

Start on Cloud
编组
All Products
    • Databases
    • iconOceanBase Database
    • iconOceanBase Cloud
    • iconOceanBase Tugraph
    • iconInteractive Tutorials
    • iconOceanBase Best Practices
    • Tools
    • iconOceanBase Cloud Platform
    • iconOceanBase Migration Service
    • iconOceanBase Developer Center
    • iconOceanBase Migration Assessment
    • iconOceanBase Admin Tool
    • iconOceanBase Loader and Dumper
    • iconOceanBase Deployer
    • iconKubernetes operator for OceanBase
    • iconOceanBase Diagnostic Tool
    • iconOceanBase Binlog Service
    • Connectors and Middleware
    • iconOceanBase Database Proxy
    • iconEmbedded SQL in C for OceanBase
    • iconOceanBase Call Interface
    • iconOceanBase Connector/C
    • iconOceanBase Connector/J
    • iconOceanBase Connector/ODBC
    • iconOceanBase Connector/NET
icon

OceanBase Database

SQL - V4.2.0

    Download PDF

    OceanBase logo

    The Unified Distributed Database for the AI Era.

    Follow Us
    Products
    OceanBase CloudOceanBase EnterpriseOceanBase Community EditionOceanBase seekdb
    Resources
    DocsBlogLive DemosTraining & Certification
    Company
    About OceanBaseTrust CenterLegalPartnerContact Us
    Follow Us

    © OceanBase 2026. All rights reserved

    Cloud Service AgreementPrivacy PolicySecurity
    Contact Us
    Document Feedback
    1. Documentation Center
    2. OceanBase Database
    3. SQL
    4. V4.2.0
    iconOceanBase Database
    SQL - V 4.2.0
    SQL
    KV
    • V 4.4.2
    • V 4.3.5
    • V 4.3.3
    • V 4.3.1
    • V 4.3.0
    • V 4.2.5
    • V 4.2.2
    • V 4.2.1
    • V 4.2.0
    • V 4.1.0
    • V 4.0.0
    • V 3.1.4 and earlier

    Default production parameters

    Last Updated:2023-12-08 07:13:36  Updated
    share
    What is on this page
    Typical hardware configuration
    TP-based scenarios
    Cluster parameters
    Tenant parameters
    System variables
    AP-based scenarios
    Cluster parameters
    Tenant parameters
    System variables

    folded

    share

    This topic provides recommended configurations of default production parameters for hardware configurations, transaction processing (TP) scenarios, and analytical processing (AP) scenarios.

    Typical hardware configuration

    The server configurations vary by users based on different production standards. This topic mainly uses the hardware configurations listed in the following table as the typical configuration.

    Server configuration item Description
    Server quantity 3
    Processor Intel
    CPU 52 cores
    Memory 512 GB
    Disk
    • Data disk: 3.84 TB NVME x 6
    • System disk: 240 GB M.2
    NIC 10 Gbit/s NIC
    Operating system CentOS 7.6

    TP-based scenarios

    Cluster parameters

    • system_memory: specifies the size of the system memory space reserved for the sys500 tenant.

      • Recommended value: 30G

      • Value range: [0M, +∞)

      • Example:

        obclient> ALTER SYSTEM SET system_memory='30G';
        
    • major_compact_trigger: specifies the number of minor compactions for triggering a global major compaction.

      • Recommended value: 50

      • Value range: [0, 65535]

      • Example:

        obclient> ALTER SYSTEM SET major_compact_trigger=50;
        
    • memstore_limit_percentage: specifies the percentage of the memory occupied by the MemStore among the total available memory of a tenant.

      • Recommended value: 80

      • Value range: (0, 100)

      • Example:

        obclient> ALTER SYSTEM SET memstore_limit_percentage=80;
        
    • trace_log_slow_query_watermark: specifies the query execution time threshold. A query whose execution time exceeds this threshold is considered a slow query. Trace logs of slow queries are written to system logs.

      • Recommended value: 100ms

      • Value range: [1ms, +∞)

      • Example:

        obclient> ALTER SYSTEM SET trace_log_slow_query_watermark='100ms';
        
    • enable_syslog_recycle: specifies whether to enable system log recycling.

      • Recommended value: True

      • Valid values: True and False

      • Example:

        obclient> ALTER SYSTEM SET enable_syslog_recycle=True;
        
    • max_syslog_file_count: specifies the maximum number of log files that can be retained.

      • Recommended value: 500

      • Value range: [0, +∞)

      • Example:

        obclient> ALTER SYSTEM SET max_syslog_file_count=500;
        
    • enable_rebalance: specifies whether to enable automatic load balancing. In the sys tenant, it specifies whether to enable load balancing across tenants, and in a user tenant, it specifies whether to enable load balancing within the tenant.

      • Recommended value: True

      • Valid values: True and False

      • Example:

        obclient> ALTER SYSTEM SET enable_rebalance=True;
        

    Tenant parameters

    • freeze_trigger_percentage: specifies the threshold of memory used by tenants for triggering a global freeze.

      • Recommended value: 20

      • Value range: (0, 100)

      • Example:

        obclient> ALTER SYSTEM SET freeze_trigger_percentage=20;
        
    • writing_throttling_trigger_percentage: specifies the upper limit of the write speed. If the value of this parameter is set to 100, write throttling is disabled.

      • Recommended value: 80

      • Value range: [0, 100]

      • Example:

        obclient> ALTER SYSTEM SET writing_throttling_trigger_percentage=80;
        
    • undo_retention: specifies the time range in seconds of data versions to be retained by the system. This variable is used to control the collection of data of multiple versions in minor compactions.

      • Recommended value: 1800

      • Value range: [0, 4294967295]

      • Example:

        obclient> ALTER SYSTEM SET undo_retention=1800;
        
    • cpu_quota_concurrency: specifies the maximum concurrency allowed for each CPU quota of a tenant.

      • Recommended value: 4

      • Value range: [1, 20]

      • Example:

        obclient> ALTER SYSTEM SET cpu_quota_concurrency=4;
        

    System variables

    • recyclebin: specifies whether to enable the recycle bin.

      • Recommended value: OFF

      • Valid values: ON and OFF

      • Example:

        obclient> SET GLOBAL recyclebin=OFF;
        
    • ob_query_timeout: specifies the query timeout duration in microseconds.

      • Recommended value: 10000000

      • Value range: N/A

      • Example:

        obclient> SET GLOBAL ob_query_timeout=10000000;
        
    • ob_trx_idle_timeout: specifies the idle timeout duration in microseconds in which no transactions are executed. A timeout occurs when the execution interval between two statements exceeds the value of this parameter.

      • Recommended value: 86400000000

      • Value range: [100000000, +∞)

      • Example:

        obclient> SET GLOBAL ob_trx_idle_timeout=120000000;
        
    • ob_trx_timeout: specifies the transaction timeout duration in microseconds.

      • Recommended value: 86400000000

      • Value range: N/A

      • Example:

        obclient> SET GLOBAL ob_trx_timeout=100000000;
        
    • ob_sql_work_area_percentage: specifies the maximum percentage of tenant memory for SQL execution.

      • Recommended value: 5

      • Value range: [0, 100]

      • Example:

        obclient> SET GLOBAL ob_sql_work_area_percentage=5;
        
    • parallel_servers_target: specifies the queue condition for parallel queries on each server. When the number of threads taken by Parallel eXecution (PX) of multiple SQL queries exceeds the specified queue condition, subsequent SQL queries for PX must wait in a queue.

      • Recommended value: Number of tenant CPU cores × 10

      • Value range: [0, 9223372036854775807]

      • Example:

        obclient> SET GLOBAL parallel_servers_target=30;
        
    • max_allowed_packet: specifies the maximum size in bytes of a network packet.

      • Recommended value: 4194304

      • Value range: [1024, 1073741824]

      • Example:

        obclient> SET GLOBAL max_allowed_packet=4194304;
        
    • nls_date_format: specifies the format of converting a date value to a string and the format of implicitly converting a string to a date value.

      Note

      This parameter applies only to the Oracle mode of OceanBase Database.

      • Recommended value: DD-MON-RR

      • Value range: N/A

      • Example:

        obclient> SET GLOBAL nls_date_format='DD-MON-RR';
        

    AP-based scenarios

    Cluster parameters

    • trace_log_slow_query_watermark: specifies the query execution time threshold. A query whose execution time exceeds this threshold is considered a slow query. Trace logs of slow queries are written to system logs.

      • Recommended value: 10s

      • Value range: [1ms, +∞)

      • Example:

        obclient> ALTER SYSTEM SET trace_log_slow_query_watermark='10s';
        
    • memstore_limit_percentage: specifies the percentage of the memory occupied by the MemStore among the total available memory of a tenant.

      • Recommended value: 50

      • Value range: (0, 100)

      • Example:

        obclient> ALTER SYSTEM SET memstore_limit_percentage=50;
        
    • large_query_worker_percentage: specifies the percentage of worker threads reserved for large queries.

      • Recommended value: 10

      • Value range: [0, 100]

      • Example:

        obclient> ALTER SYSTEM SET large_query_worker_percentage=10;
        
    • net_thread_count: specifies the number of network I/O threads.

      • Recommended value: 24

      • Value range: [1, 64]

      • Example:

        obclient> ALTER SYSTEM SET net_thread_count=24;
        
    • rpc_timeout: specifies the timeout duration of internal requests of the cluster in microseconds.

      • Recommended value: 1000000000

      • Value range: [0, +∞)

      • Example:

        obclient> ALTER SYSTEM SET rpc_timeout=1000000000;
        
    • micro_block_merge_verify_level: specifies the validation level of macro blocks in a major compaction.

      • Recommended value: 0

      • Valid values:

        • 0: No verification is performed.

        • 1: The encoding algorithm is verified, and the encoded microblocks are read to ensure data accuracy.

        • 2: The encoding and compression algorithms are verified. In addition, the compressed blocks are decompressed to ensure data accuracy.

        • 3: The encoding and compression algorithms are verified, and lost write protection is implemented.

      • Example:

        obclient> ALTER SYSTEM SET micro_block_merge_verify_level=0;
        
    • enable_sql_audit: specifies whether to enable SQL Audit.

      • Recommended value: False

      • Valid values: True and False

      • Example:

        obclient> ALTER SYSTEM SET enable_sql_audit=False;
        
    • enable_perf_event: specifies whether to enable the information collection feature for performance events.

      • Recommended value: False

      • Valid values: True and False

      • Example:

        obclient> ALTER SYSTEM SET enable_perf_event=False;
        
    • cache_wash_threshold: specifies the threshold that triggers cache clean-up. If the available memory is less than the specified value, the memory will be cleared.

      • Recommended value: 30GB

      • Value range: [0, +∞)

      • Example:

        obclient> ALTER SYSTEM SET cache_wash_threshold='30GB';
        

    Tenant parameters

    • undo_retention: specifies the time range in seconds of data versions to be retained by the system. This variable is used to control the collection of data of multiple versions in minor compactions.

      • Recommended value: 900

      • Value range: [0, 4294967295]

      • Example:

        obclient> ALTER SYSTEM SET undo_retention=900;
        

    System variables

    You may configure the basic variables for the sys tenant based on the following description:

    • ob_query_timeout: specifies the query timeout duration in microseconds.

      • Recommended value: 10000000000

      • Value range: N/A

      • Example:

        obclient> SET GLOBAL ob_query_timeout=10000000000;
        
    • ob_trx_timeout: specifies the transaction timeout duration in microseconds.

      • Recommended value: 86400000000

      • Value range: N/A

      • Example:

        obclient> SET GLOBAL ob_trx_timeout=100000000000;
        

    You may configure the general variables for a user tenant based on the following description:

    • ob_sql_work_area_percentage: specifies the maximum percentage of tenant memory for SQL execution.

      • Recommended value: 70

      • Value range: [0, 100]

      • Example:

        obclient> SET GLOBAL ob_sql_work_area_percentage=70;
        
    • parallel_servers_target: specifies the queue condition for parallel queries on each server. When the number of threads taken by PX of multiple SQL queries exceeds the specified queue condition, subsequent SQL queries for PX must wait in a queue.

      • Recommended value: Number of tenant CPU cores × 30

      • Value range: [0, 9223372036854775807]

      • Example:

        obclient> SET GLOBAL parallel_servers_target=90;
        
    • max_allowed_packet: specifies the maximum size in bytes of a network packet.

      • Recommended value: 67108864

      • Value range: [1024, 1073741824]

      • Example:

        obclient> SET GLOBAL max_allowed_packet=67108864;
        

    Previous topic

    General system parameters
    Last

    Next topic

    Minimum resource configurations
    Next
    What is on this page
    Typical hardware configuration
    TP-based scenarios
    Cluster parameters
    Tenant parameters
    System variables
    AP-based scenarios
    Cluster parameters
    Tenant parameters
    System variables