clickhouse外部词典加载错误
clickhouse external dictionary loading error
我打算升级 clickhouse cluster.From v19.14.6。到 v21.3.10.But 当我在 v21.3.10 上加载 mysql 外部词典时,出现错误:
Query:
SYSTEM RELOAD DICTIONARY dim_subject_movie
Received exception from server:
Poco::Exception. Code: 1000, e.code() = 0, e.displayText() = Exception: Connections to all replicas failed: frodo@mysql1:3306 as user test, frodo@mysql1:3306 as user test (version 21.3.10.1 (official build))
配置如下
<dictionary>
<name>dim_subject_movie</name>
<source>
<mysql>
<port>3306</port>
<user>test</user>
<password>test1</password>
<replica>
<host>mysql1</host>
<priority>1</priority>
</replica>
<db>frodo</db>
<table>subject_movie_collection</table>
<where>date=subdate(current_date, 1)</where>
</mysql>
</source>
<lifetime>
<min>300</min>
<max>360</max>
</lifetime>
<layout><hashed /></layout>
<structure>
<id>
<name>movie_id</name>
</id>
<attribute>
<name>movie_title</name>
<type>String</type>
<null_value></null_value>
</attribute>
</structure>
</dictionary>
有人遇到过同样的问题吗?谢谢!
找到原因是因为dic源(mysql5.1)太旧,无法兼容高版本的clickhouse。最后我把clickhouse的版本改回19.14.6.
我打算升级 clickhouse cluster.From v19.14.6。到 v21.3.10.But 当我在 v21.3.10 上加载 mysql 外部词典时,出现错误:
Query:
SYSTEM RELOAD DICTIONARY dim_subject_movie
Received exception from server:
Poco::Exception. Code: 1000, e.code() = 0, e.displayText() = Exception: Connections to all replicas failed: frodo@mysql1:3306 as user test, frodo@mysql1:3306 as user test (version 21.3.10.1 (official build))
配置如下
<dictionary>
<name>dim_subject_movie</name>
<source>
<mysql>
<port>3306</port>
<user>test</user>
<password>test1</password>
<replica>
<host>mysql1</host>
<priority>1</priority>
</replica>
<db>frodo</db>
<table>subject_movie_collection</table>
<where>date=subdate(current_date, 1)</where>
</mysql>
</source>
<lifetime>
<min>300</min>
<max>360</max>
</lifetime>
<layout><hashed /></layout>
<structure>
<id>
<name>movie_id</name>
</id>
<attribute>
<name>movie_title</name>
<type>String</type>
<null_value></null_value>
</attribute>
</structure>
</dictionary>
有人遇到过同样的问题吗?谢谢!
找到原因是因为dic源(mysql5.1)太旧,无法兼容高版本的clickhouse。最后我把clickhouse的版本改回19.14.6.