Description
Contains information of each Replicated database replicas.
Columns
database (String) — The name of the Replicated database is in.
is_readonly (UInt8) — Whether the database replica is in read-only mode.
max_log_ptr (Int32) — Maximum entry number in the log of general activity.
replica_name (String) — Replica name in ClickHouse Keeper.
replica_path (String) — Path to replica data in ClickHouse Keeper.
zookeeper_path (String) — Path to database data in ClickHouse Keeper.
shard_name (String) — The name of the shard in the cluster.
log_ptr (Int32) — Maximum entry number in the log of general activity that the replica copied to its execution queue, plus one.
total_replicas (UInt32) — The total number of known replicas of this database.
zookeeper_exception (String) — The last exception message, got if the error happened when fetching the info from ClickHouse Keeper.
is_session_expired (UInt8) — The session with ClickHouse Keeper has expired. Basically the same as is_readonly.
Example
SELECT * FROM system.database_replicas FORMAT Vertical;
Row 1:
──────
database: db_2
is_readonly: 0
max_log_ptr: 2
replica_name: replica1
replica_path: /test/db_2/replicas/shard1|replica1
zookeeper_path: /test/db_2
shard_name: shard1
log_ptr: 2
total_replicas: 1
zookeeper_exception:
is_session_expired: 0
Last modified on June 8, 2026