首页 > 其他分享 >No macro ‘uuid‘ in config while processing substitutions in

No macro ‘uuid‘ in config while processing substitutions in

时间:2023-01-13 22:35:59浏览次数:45  
标签:uuid No macro shard config clickhouse


clickhouse建表时出现以下异常:

DB::Exception: No macro 'uuid' in config while processing substitutions in '/clickhouse/tables/{uuid}/{shard}' at '20' or macro is not supported here (version 20.8.3.18)

DB::Exception: No macro ‘uuid’ in config while processing substitutions in ‘/clickhouse/tables/{uuid}/{shard}’ at ‘20’ or macro is not supported here (version 20.8.3.18)

在替换/clickhouse/tables/{uuid}/{shard}中的uuid时未找到定义的uuid的宏变量,或者宏变量不支持。
使用大括号表示会从配置文件中获取宏定义的变量,若未添加该标签会报错。

在clickhouse的配置文件中,在每个节点服务器的文件/etc/clickhouse-server/metrika.xml或者/etc/clickhouse-server/config.xml中添加

<macros>
<shard_name>01</shard_name>
<replica>clickhouse01</replica>
</macros>


标签:uuid,No,macro,shard,config,clickhouse
From: https://blog.51cto.com/u_15936016/6006751

相关文章