本文介绍了如何使用SHOW BINARY STREAMS语句查看PolarDB-X多流服务的binlog stream列表。

语法

SHOW BINARY STREAMS;

说明:

执行上述SQL需要有SUPERREPLICATION CLIENT权限,权限操作请参见账号权限管理

示例

执行以下语句,查看binlog stream列表:

SHOW BINARY STREAMS;

返回结果如下:

+--------+-----------------+-------------------------------+----------+
| GROUP  | STREAM          | FILE                          | POSITION |
+--------+-----------------+-------------------------------+----------+
| group1 | group1_stream_0 | group1_stream_0#binlog.000001 |  3625148 |
| group1 | group1_stream_1 | group1_stream_1#binlog.000001 |  3625148 |
| group1 | group1_stream_2 | group1_stream_2#binlog.000001 |  3625148 |
| group1 | group1_stream_3 | group1_stream_3#binlog.000001 |  3625148 |
+--------+-----------------+-------------------------------+----------+