-
Type:
Patch request
-
Resolution: Unresolved
-
Priority:
Trivial
-
None
-
Affects Version/s: 8.0.0rc2
-
Component/s: Frontend (F), Server (S)
-
Environment:Zabbix server 8.0.0rc2 (revision f3e1632e2ec), upgraded from 8.0.0rc1 (revision 66ca63baedf)
ClickHouse 26.4.5.143, Ubuntu 26.04 arm64
ClickHouse cluster: 2 shards × 2 replicas (cluster_2S_2R), embedded ClickHouse Keeper on 3 nodes
Database zabbix created with ENGINE = Replicated(...)
History schema created with history_all.sh --engine "ReplicatedMergeTree()", then each table renamed to <table>_local and a Distributed table created with the original name, exactly as described in ClickHouse setup > Configuring ClickHouse clusters
HistoryProvider points to a load balancer in front of the clusterZabbix server 8.0.0rc2 (revision f3e1632e2ec), upgraded from 8.0.0rc1 (revision 66ca63baedf) ClickHouse 26.4.5.143, Ubuntu 26.04 arm64 ClickHouse cluster: 2 shards × 2 replicas (cluster_2S_2R), embedded ClickHouse Keeper on 3 nodes Database zabbix created with ENGINE = Replicated(...) History schema created with history_all.sh --engine "ReplicatedMergeTree()", then each table renamed to <table>_local and a Distributed table created with the original name, exactly as described in ClickHouse setup > Configuring ClickHouse clusters HistoryProvider points to a load balancer in front of the cluster
Steps to reproduce
- Set up a ClickHouse cluster following Configuring ClickHouse clusters in the 8.0 documentation (ReplicatedMergeTree _local tables + Distributed tables with the original names).
- Configure HistoryProvider=clickhouse;... on Zabbix server.
- Start (or restart) Zabbix server.
Actual result
For every history table, the server logs a warning at startup:
{{retrieving history provider "clickhouse" information
cannot parse TTL information from ClickHouse schema: CREATE TABLE zabbix.history\n(\n `itemid` UInt64,\n `clock_ns` DateTime64(9),\n `value` Float64\n)\nENGINE = Distributed(\'cluster_2S_2R\', \'zabbix\', \'history_local\', itemid)}}
The same message appears for history_str, history_log, history_uint, history_text and history_json. The server then continues normally (history provider "clickhouse" version "26.4.5.143") and history is written and read correctly.
As a result, Administration > Housekeeping shows the ClickHouse data storage period as Unknown for all value types:
{{ClickHouse data storage period
Numeric (float) Unknown
Character Unknown
Log Unknown
Numeric (unsigned) Unknown
Text Unknown
JSON Unknown}}
The actual TTL is defined on the _local tables (365 days in this setup) and is enforced correctly by ClickHouse; only the value shown in the frontend is affected.
Expected result
The server should read the TTL from the underlying local table referenced by the Distributed engine (zabbix.<table>local), where the TTL is actually defined, and display it in _Administration > Housekeeping without warnings.
Notes / possible fix
- A Distributed table never has a TTL clause; the TTL is on the local ReplicatedMergeTree table. The actual TTL can be checked with:
SELECT name, create_table_query FROM system.tables WHERE database='zabbix' AND name LIKE '%_local' - When the history table engine is Distributed, the server could resolve the local table from the engine arguments (database and table) and parse the TTL there.
- Since the cluster procedure in the official documentation produces this exact schema, every user following it will hit this warning.