This topic describes monitoring metrics related to the time consumed by I/O operations within an OceanBase Database tenant. You can specify a statistical period to query statistics about the time consumed by I/O operations in a single zone or on a single OBServer of an OceanBase Database tenant.
read
Definition
The average time consumed by each SSStore read within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| read | io_read_rt | Microseconds |
Calculation expression
sum(rate(ob_sysstat{stat_id="60001",@LABELS}[@INTERVAL])) by (@GBLABELS) / sum(rate(ob_sysstat{stat_id="60000",@LABELS}[@INTERVAL])) by (@GBLABELS)
SQL statements for metric collection
If you use OceanBase Database of a version earlier than V4.0, execute the following statement:
select /*+ MONITOR_AGENT READ_CONSISTENCY(WEAK) */ con_id tenant_id, stat_id, value from v$sysstat where stat_id IN (60000, 60001) and (con_id > 1000 or con_id = 1) and class < 1000If you use OceanBase Database V4.0 or later, execute the following statement:
select /* MONITOR_AGENT */ con_id tenant_id, stat_id, value from v$sysstat where stat_id IN (60000, 60001) and (con_id > 1000 or con_id = 1) and class < 1000
write
Definition
The average time consumed by each SSStore write within a tenant in the specified statistical period.
Description
| Metric | Metric field name | Unit |
|---|---|---|
| write | io_write_rt | Microseconds |
Calculation expression
sum(rate(ob_sysstat{stat_id="60004",@LABELS}[@INTERVAL])) by (@GBLABELS) / sum(rate(ob_sysstat{stat_id="60003",@LABELS}[@INTERVAL])) by (@GBLABELS)
SQL statements for metric collection
If you use OceanBase Database of a version earlier than V4.0, execute the following statement:
select /*+ MONITOR_AGENT READ_CONSISTENCY(WEAK) */ con_id tenant_id, stat_id, value from v$sysstat where stat_id IN (60003, 60004) and (con_id > 1000 or con_id = 1) and class < 1000If you use OceanBase Database V4.0 or later, execute the following statement:
select /* MONITOR_AGENT */ con_id tenant_id, stat_id, value from v$sysstat where stat_id IN (60003, 60004) and (con_id > 1000 or con_id = 1) and class < 1000