clickhouse-数据副本踩坑
副本之间没有主从关系 互为副本,没有主从
https://blog.csdn.net/qq_21383435/article/details/122813971
数据副本--失败,看日志
vim /var/log/clickhouse-server/clickhouse-server.err.log
select * from system.replication_queue;
hostname -f
目的:数据备份,防止丢失 + 高可用
操作:
建表需要ReplicatedMergeTree引擎
ENGINE = ReplicatedMergeTree('/clickhouse/tables/t_stock', 'suiyi')
'/clickhouse/tables/t_stock' zk节点
config.xml添加zk节点信息,
报错解决1
Code: 198. DB::Exception: Not found address of host: p-96b7-ducg-0001.novalocal. (DNS_ERROR), Stack trace (when copying this message, always include the lines b
添加interserver_http_host
报错解决1
删除了err日志文件,/var/log/clickhouse-server/clickhouse-server.err.log,但是属组是root,需要改
参考:
https://blog.csdn.net/weixin_41984330/article/details/126561417