Altinity / clickhouse-operator

Altinity Kubernetes Operator for ClickHouse creates, configures and manages ClickHouse® clusters running on Kubernetes
https://altinity.com
Apache License 2.0
1.93k stars 463 forks source link

Question: Select to Distributed Table sometimes fails if one replica is offline #1072

Closed derbauer97 closed 1 year ago

derbauer97 commented 1 year ago

Hi,

I have an issue that my select queries to an distributed table fails when one Replica is unavailable (e.g because of an rolling update):

Code: 198. DB::Exception: Received from localhost:9000. DB::Exception: Not found address of host: chi-instana-clickhouse-instana-1-0: While executing Remote. (DNS_ERROR)

I already tried to use skip_unavailable_shards = 1 for this query but I still get this error.

I am relatively new to clickhouse therefore i do not know if this is even indented to work?

https://clickhouse.com/docs/en/engines/table-engines/special/distributed/ if i read that correct clickhouse should select the next replica if one of the replicas failes.

i am Using an 4 Node Cluster with 2 shards and 2 replicas each

derbauer97 commented 1 year ago

Seems to be related to https://github.com/ClickHouse/ClickHouse/pull/43179. Downgrade to Version 22.8.12.45 fixed it in my case.