> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-parallel-read-in-order-multi-part.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> ZooKeeper が構成されている場合にのみ存在するシステムテーブルです。現在の ZooKeeper への接続（補助的な ZooKeeper を含む）を表示します。

# system.zookeeper_connection

<Info>
  **ClickHouse Cloud でのクエリ**

  このシステムテーブルのデータは、ClickHouse Cloud の各ノードにローカルに保持されています。したがって、すべてのデータを完全に把握するには、`clusterAllReplicas` 関数を使用する必要があります。詳細については、[こちら](/ja/reference/system-tables/overview#system-tables-in-clickhouse-cloud)を参照してください。
</Info>

## 説明

ZooKeeper が設定されていない場合、このテーブルは存在しません。`system.zookeeper_connection` テーブルには、現在の ZooKeeper への接続 (補助的な ZooKeeper を含む) が表示されます。各行には、1 つの接続に関する情報が含まれます。

## カラム

* `name` ([String](/ja/reference/data-types/string)) — ZooKeeper クラスターの名前。
* `host` ([String](/ja/reference/data-types/string)) — ClickHouse が接続している ZooKeeper ノードのホスト名/IP アドレス。
* `port` ([UInt16](/ja/reference/data-types/int-uint)) — ClickHouse が接続している ZooKeeper ノードのポート。
* `index` ([Nullable(UInt8)](/ja/reference/data-types/nullable)) — ClickHouse が接続している ZooKeeper ノードのインデックス。このインデックスは ZooKeeper の設定に基づきます。接続されていない場合、このカラムは NULL です。
* `connected_time` ([DateTime](/ja/reference/data-types/datetime)) — 接続が確立された日時。
* `session_uptime_elapsed_seconds` ([UInt64](/ja/reference/data-types/int-uint)) — 接続が確立されてからの経過秒数。
* `is_expired` ([UInt8](/ja/reference/data-types/int-uint)) — 現在の接続が期限切れかどうか。
* `keeper_api_version` ([UInt8](/ja/reference/data-types/int-uint)) — Keeper API のバージョン。
* `client_id` ([Int64](/ja/reference/data-types/int-uint)) — 接続のセッション ID。
* `xid` ([Int64](/ja/reference/data-types/int-uint)) — 現在のセッションの XID。
* `enabled_feature_flags` ([Array(Enum16('FILTERED\_LIST' = 0, 'MULTI\_READ' = 1, 'CHECK\_NOT\_EXISTS' = 2, 'CREATE\_IF\_NOT\_EXISTS' = 3, 'REMOVE\_RECURSIVE' = 4, 'MULTI\_WATCHES' = 5, 'CHECK\_STAT' = 6, 'PERSISTENT\_WATCHES' = 7, 'CREATE\_WITH\_STATS' = 8, 'TRY\_REMOVE' = 9, 'LIST\_WITH\_STAT\_AND\_DATA' = 10, 'GET\_CHILDREN\_RECURSIVE' = 11, 'CREATE\_TTL' = 12, 'CREATE\_CONTAINER' = 13, 'MAX\_REQUEST\_SIZE' = 14))](/ja/reference/data-types/array)) — 有効な feature flags。ClickHouse Keeper にのみ適用されます。
* `availability_zone` ([String](/ja/reference/data-types/string)) — アベイラビリティゾーン
* `session_timeout_ms` ([UInt64](/ja/reference/data-types/int-uint)) — セッションの timeout (ミリ秒単位)
* `last_zxid_seen` ([Int64](/ja/reference/data-types/int-uint)) — 現在のセッションで最後に確認された zxid。

## 例

```sql theme={null}
SELECT
    name,
    host,
    port,
    index,
    connected_time,
    session_uptime_elapsed_seconds,
    is_expired,
    keeper_api_version,
    client_id,
    xid,
    enabled_feature_flags,
    availability_zone
FROM system.zookeeper_connection;
```

```text theme={null}
┌─name────┬─host──────┬─port─┬─index─┬──────connected_time─┬─session_uptime_elapsed_seconds─┬─is_expired─┬─keeper_api_version─┬─client_id─┬─xid─┬─enabled_feature_flags────────────────────────────────────────────────────┬─availability_zone─┐
│ default │ 127.0.0.1 │ 2181 │     0 │ 2025-04-10 14:30:00 │                            943 │          0 │                  0 │       420 │  69 │ ['FILTERED_LIST','MULTI_READ','CHECK_NOT_EXISTS','CREATE_IF_NOT_EXISTS'] │ eu-west-1b        │
└─────────┴───────────┴──────┴───────┴─────────────────────┴────────────────────────────────┴────────────┴────────────────────┴───────────┴─────┴──────────────────────────────────────────────────────────────────────────┴───────────────────┘
```
