Overview
Displays the progress information of tablet-level compaction for the current tenant on the current node.
Columns
Field Name |
Type |
Whether can be NULL |
Description |
|---|---|---|---|
| SVR_IP | varchar(46) | NO | Server IP Address |
| SVR_PORT | bigint(20) | NO | Server Port Number |
| TENANT_ID | bigint(20) | NO | Tenant ID |
| TYPE | varchar(64) | NO | Compaction type:
|
| TABLE_ID | bigint(20) | NO | Primary Table ID |
| LS_ID | bigint(20) | NO | Log Stream ID |
| TABLET_ID | bigint(20) | NO | Data Shard ID |
| COMPACTION_SCN | bigint(20) unsigned | NO | Major compaction version information |
| TASK_ID | varchar(64) | NO | Executed Trace |
| STATUS | varchar(15) | NO | Task Status |
| DATA_SIZE | bigint(20) | NO | Total data volume requiring compaction, in bytes |
| UNFINISHED_DATA_SIZE | bigint(20) | NO | Data volume of unfinished major compaction, in bytes |
| PROGRESSIVE_COMPACTION_ROUND | bigint(20) | NO | Asymptotic Major Compaction Round |
| CREATE_TIME | timestamp(6) | NO | Task Creation Time |
| START_TIME | timestamp(6) | NO | Start Time |
| ESTIMATED_FINISH_TIME | timestamp(6) | NO | Estimated Completion Time |
| START_CG_ID | bigint(20) | NO | Start ID of Column Group |
| END_CG_ID | bigint(20) | NO | End ID of Column Group |
Sample query
You can query the progress information of major compactions for the current tenant on the current node.
obclient [oceanbase]> SELECT * FROM oceanbase.V$OB_TABLET_COMPACTION_PROGRESS WHERE TYPE='MAJOR_MERGE'\G
The query result is as follows:
+----------------+----------+-----------+-------------+-------+-----------+---------------------+-----------------------------------+--------------+-----------+----------------------+------------------------------+----------------------------+----------------------------+----------------------------+-------------+-----------+
| SVR_IP | SVR_PORT | TENANT_ID | TYPE | LS_ID | TABLET_ID | COMPACTION_SCN | TASK_ID | STATUS | DATA_SIZE | UNFINISHED_DATA_SIZE | PROGRESSIVE_COMPACTION_ROUND | CREATE_TIME | START_TIME | ESTIMATED_FINISH_TIME | START_CG_ID | END_CG_ID |
+----------------+----------+-----------+-------------+-------+-----------+---------------------+-----------------------------------+--------------+-----------+----------------------+------------------------------+----------------------------+----------------------------+----------------------------+-------------+-----------+
| 172.xx.xxx.xxx | 2882 | 1002 | MAJOR_MERGE | 1 | 101067 | 1751867181650640000 | YB42AC1E87D9-00063837DA7854C4-0-0 | NODE_RUNNING | 21475 | 21475 | 1 | 2025-07-07 13:49:33.233901 | 2025-07-07 13:49:33.233998 | 2025-07-07 13:49:50.234508 | 0 | 0 |
+----------------+----------+-----------+-------------+-------+-----------+---------------------+-----------------------------------+--------------+-----------+----------------------+------------------------------+----------------------------+----------------------------+----------------------------+-------------+-----------+
1 row in set