Repository navigation
Zookeeper to ClickHouse Keeper Migration. #125824
Replies: 1 comment
|
Straight from the official Keeper guide (migration section): "Seamless migration from ZooKeeper to ClickHouse Keeper isn't possible. You have to stop your ZooKeeper cluster, convert data, and start ClickHouse Keeper." And a mixed ZK/Keeper cluster is impossible too — the interserver protocols are incompatible even though the client protocol is shared. So true zero-downtime isn't a supported outcome today; what you can get is a short, well-rehearsed write-maintenance window. On your two specific questions: Why the zxid keeps creeping despite everything stopped. Live ClickHouse servers hold ZooKeeper sessions — ephemeral znodes, heartbeats, replica registration, occasional touches of coordination paths that aren't covered by Is the leader-only live snapshot safe? Not as safe as it looks, for a concrete reason: ephemeral nodes baked into a snapshot taken while CH was still running become orphans in Keeper. Keeper has no knowledge of the ZK sessions that owned them, so they never get cleaned up, and things like replica-registration/leader-election ephemerals from the old world linger exactly where the new world expects fresh ones. The documented procedure avoids this by construction:
Minimizing the window in practice — the part that makes this feel near-zero-downtime:
The one thing I'd not do is the live-leader-snapshot-with-CH-running variant: even when it appears to work, the orphaned-ephemeral risk bites later in ways that are expensive to diagnose (stale leader-election nodes, replicas that think someone else holds locks). |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Is it possible to do ZK to ClickHouse Keeper Migration without bringing down ClickHouse. We tried stopping merges, distributed sends, fetches, moves, ttl merges, cleanup , replication queues, replication log etc and we stopped all writers to clickhouse. We still could see zxid keeps incrementing sometimes after 15 mins to 1 hour (approximately).
Is it safe to take a zk snapshot (with only leader zk up and running and clickhouse being operational)and push to clickhouse-keeper if zxid does not change for 15 mins continuously.
Whats the best way to achieve zero downtime migration.
All reactions