赞
踩
docker pull yandex/clickhouse-server
docker pull yandex/clickhouse-client
docker run -d -p 8123:8123 -p 9000:9000 --name clickhouse yandex/clickhouse-server
# 默认直接启动即可
docker run -d --name [启动之后的名称] --ulimit nofile=262144:262144 yandex/clickhouse-server
# 如果想指定目录启动,这里以clickhouse-test-server命令为例,可以随意写
mkdir /work/clickhouse/clickhouse-test-db ## 创建数据文件目录
# 使用以下路径启动,在外只能访问clickhouse提供的默认9000端口,只能通过clickhouse-client连接server
docker run -d --name clickhouse-test-server --ulimit nofile=262144:262144 --volume=/work/clickhouse/clickhouse_test_db:/var/lib/clickhouse yandex/clickhouse-server
docker run -it --rm --link clickhouse-test-server:clickhouse-server yandex/clickhouse-client --host clickhouse-server
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。