Query information about the binlog server
You can query information about the node where the primary binlog instance of the specified tenant resides. If no primary binlog instance is available, an error message is returned.
Syntax
SHOW BINLOG SERVER FOR TENANT cluster.tenant;
cluster.tenant specifies the name of the tenant to query and the name of the cluster to which the tenant belongs. Here is an example:
SHOW BINLOG SERVER FOR TENANT obdemo.test1;
The output is as follows:
+---------+--------+------------+------+--------+-------+
| cluster | tenant | ip | port | status | cause |
+---------+--------+------------+------+--------+-------+
| obdemo | test1 | 10.10.10.1 | 8103 | OK | NULL |
+---------+--------+------------+------+--------+-------+
The following table describes the columns in the result set.
| Column | Description |
|---|---|
| cluster | The name of the OceanBase cluster. |
| tenant | The name of a tenant in the OceanBase cluster. |
| ip | The IP address of the node where the primary binlog instance resides. |
| port | The port number of the node where the primary binlog instance resides. The value 0 indicates that no service port has been allocated. |
| status | The status of the primary binlog instance, which is fixed to OK now. |
| cause | A reserved column. |