OceanBase logo

OceanBase

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

Product Overview
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

OceanBase

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

Product Overview
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 Diagnostic Tool

V1.4.0

  • Overview
  • Install obdiag
  • Configure obdiag
  • Use `obdiag gather` commands to collect diagnostic information of OceanBase Database
  • Use `obdiag analyze` commands to analyze diagnostic information of OceanBase Database
  • Use `obdiag check` commands to inspect an OceanBase cluster
  • FAQ

Download PDF

Overview Install obdiag Configure obdiag Use `obdiag gather` commands to collect diagnostic information of OceanBase Database Use `obdiag analyze` commands to analyze diagnostic information of OceanBase Database Use `obdiag check` commands to inspect an OceanBase cluster FAQ
OceanBase logo

The Unified Distributed Database for the AI Era.

Follow Us
Products
OceanBase CloudOceanBase EnterpriseOceanBase Community EditionOceanBase seekdb
Resources
DocsBlogLive DemosTraining & CertificationTicket
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 Diagnostic Tool
  3. V1.4.0
iconOceanBase Diagnostic Tool
V 1.4.0
Databases
  • OceanBase Database
  • OceanBase Cloud
  • OceanBase Tugraph
  • Interactive Tutorials
  • OceanBase Best Practices
Tools
  • OceanBase Cloud Platform
  • OceanBase Migration Service
  • OceanBase Developer Center
  • OceanBase Migration Assessment
  • OceanBase Admin Tool
  • OceanBase Loader and Dumper
  • OceanBase Deployer
  • Kubernetes operator for OceanBase
  • OceanBase Diagnostic Tool
  • OceanBase Binlog Service
Connectors and Middleware
  • OceanBase Database Proxy
  • Embedded SQL in C for OceanBase
  • OceanBase Call Interface
  • OceanBase Connector/C
  • OceanBase Connector/J
  • OceanBase Connector/ODBC
  • OceanBase Connector/NET
  • V 3.3.0
  • V 3.2.0
  • V 3.1.0
  • V 3.0.0
  • V 2.6.0
  • V 2.5.0
  • V 2.4.0
  • V 2.3.0
  • V 1.5.0
  • V 1.4.0

Configure obdiag

Last Updated:2026-04-13 12:22:17  Updated
Share
What is on this page
Prerequisites
Configuration description

folded

Share

This topic describes the configuration file of OceanBase Diagnostic Tool (obdiag).

Prerequisites

You have installed obdiag. For more information, see Install obdiag.

Configuration description

All configurations are saved in the config.yml file under the {obdiag_install_path}/conf/ directory. The default path of the configuration file is /usr/local/oceanbase-diagnostic-tool/conf/config.yml. Modify the configuration file directly.

The configurations can be divided into four sections.

# Configuration section 1: Configure obdiag information in this section, including logs and external variables of obdiag.
OBDIAG:
  BASIC:
    config_backup_dir: /tmp/oceanbase-diagnostic-tool/conf # The directory where historical configuration files are located. The config.yml file is overwritten when a configuration file is quickly generated. A copy of the configuration file is saved each time the configurations are updated so that you can query earlier configurations.
    file_number_limit: 20 # The maximum number of files allowed to be returned by a single OBServer node during the collection of logs of OceanBase Database.
    file_size_limit: 2G # The maximum size of files allowed to be returned in a batch during the collection of logs of OceanBase Database.
  LOGGER: # The logging configuration of obdiag.
    file_handler_log_level: DEBUG # The level of logs recorded in log files.
    log_dir: /tmp/oceanbase-diagnostic-tool/log # The path where obdiag logs are stored.
    log_filename: odt.log # The name of the log file of obdiag.
    log_level: INFO # The log printing level of obdiag.
    mode: obdiag
    stdout_handler_log_level: DEBUG

# Configuration section 2: Configure OCP information in this section if your OceanBase cluster is managed by an OCP cluster. Otherwise, skip this step.
OCP:
  LOGIN: # The logon information of OCP.
    password: xxxx
    url: http://xxx.xxx.xxx.xxx:xxxx
    user: xxx
  METADB:
    dbname: xxx
    ip: xxx.xxx.xxx.xxx
    password: xxxx
    port: xxx
    user: xxx

# Configuration section 3: Configure the connection information of the OceanBase cluster whose information is to be collected. If you do not need to use the gather plan_monitor command, skip this step.
OBCLUSTER:
  cluster_name: xxx
  host: xxx.xxx.xxx.xxx
  password: xxx
  port: xxx
  user: xxx

# Configuration section 4: Configure the logon information of the node whose information is to be collected.
NODES:
- ip: xxx.xxx.xxx.xxx
  port: xxx
  user: xxx
  password: xxx
  private_key: xxx
  home_path: xxx # The installation directory of OceanBase Database.
CHECK: # The configurations required for inspection. In general scenarios, you do not need to change the configurations.
  ignore_obversion: false
  report:
    report_path: "./check_report/" # The output path of the inspection report.
    export_type: table # The output type of the inspection report.
  package_file: "~/.obdiag/check_package.yaml" # The path of the inspection package file.
  tasks_base_path: "~/.obdiag/tasks/" # The base directory of the inspection task.

Configure relevant information in the preceding configuration sections based on the actual situation. The configurations of obdiag are seldom modified, and those of other configuration sections can be modified as needed.

If your OceanBase cluster is managed by an OCP cluster and you want to collect the information of all OBServer nodes in the cluster, you can run the obdiag config command to quickly generate the configurations of these nodes. The syntax is as follows:

obdiag config --cluster_name cluster_name --cluster_id cluster_id

Example: obdiag config --cluster_name demo1 --cluster_id 1

The following table describes the options.

Option
Required?
Description
-h No The help information.
--cluster_name Yes The name of the OceanBase cluster displayed on the GUI of the OCP console.
--cluster_id Yes The ID of the OceanBase cluster displayed on the GUI of the OCP console.

Note

  • Before you use the ./obdiag config command, make sure that you have completed the configurations in configuration section 2.
  • After you execute the ./obdiag config --cluster_name cluster_name --cluster_id cluster_id command, an interaction page appears for you to select nodes whose information is to be collected. You can press the Up or Down key to move the asterisk (*) to the node whose information you want to collect, press the Space key to select the node, and press Enter to quickly obtain configurations.
  • You must select at least one node.
press SPACE to mark, ENTER to continue
   xxx.xxx.xxx.11
   xxx.xxx.xxx.12
 * xxx.xxx.xxx.13
   xxx.xxx.xxx.14

After the command is executed, the configurations of the NODES section in the config.yml file located in the conf directory are updated, and the list of nodes whose information is to be collected is displayed.

Previous topic

Install obdiag
Last

Next topic

Use `obdiag gather` commands to collect diagnostic information of OceanBase Database
Next
What is on this page
Prerequisites
Configuration description