Install Docker
Download and launch the docker image
shdocker pull druidio/example-cluster docker run --rm -i -p 3000:8082 -p 3001:8081 druidio/example-cluster
Wait a minute or so for Druid to start up and download the sample.
On OS X
curl http://$(docker-machine ip default):3000/druid/v2/datasources
open http://$(docker-machine ip default):3001/
On Linux
curl http://localhost:3000/druid/v2/datasources
To build the docker image yourself
shgit clone https://github.com/druid-io/docker-druid.git docker build -t example-cluster docker-druid
You might want to look into the logs when debugging the Druid processes. This can be done by logging into the container using docker ps:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 9e73cbfc5612 druidio/example-cluster "/bin/sh -c 'export H" 7 seconds ago Up 6 seconds 2181/tcp, 2888/tcp, 3306/tcp, 3888/tcp, 8083/tcp, 0.0.0.0:3001->8081/tcp, 0.0.0.0:3000->8082/tcp sick_lamport
And attaching to the container using docker exec -ti 9e73cbfc5612 bash logs are written to /tmp/:
root@d59a3d4a68c3:/tmp# ls -lah total 224K drwxrwxrwt 8 root root 4.0K Jan 18 20:38 . drwxr-xr-x 61 root root 4.0K Jan 18 20:38 .. -rw------- 1 root root 0 Jan 18 20:38 druid-broker-stderr---supervisor-az6WwP.log -rw------- 1 root root 18K Jan 18 20:39 druid-broker-stdout---supervisor-D28zOC.log -rw------- 1 root root 0 Jan 18 20:38 druid-coordinator-stderr---supervisor-RYMt5L.log -rw------- 1 root root 100K Jan 18 21:14 druid-coordinator-stdout---supervisor-Jq4WCi.log -rw------- 1 root root 0 Jan 18 20:38 druid-historical-stderr---supervisor-rmMHmF.log -rw------- 1 root root 18K Jan 18 20:39 druid-historical-stdout---supervisor-AJ0SZX.log -rw------- 1 root root 7.9K Jan 18 21:09 druid-indexing-service-stderr---supervisor-x3YNlo.log -rw------- 1 root root 28K Jan 18 21:14 druid-indexing-service-stdout---supervisor-5uyV7u.log -rw------- 1 root root 155 Jan 18 20:38 mysql-stderr---supervisor-NqN9nY.log -rw------- 1 root root 153 Jan 18 20:38 mysql-stdout---supervisor-23izTf.log -rw------- 1 root root 78 Jan 18 20:38 zookeeper-stderr---supervisor-Rm33j8.log -rw------- 1 root root 7.4K Jan 18 20:39 zookeeper-stdout---supervisor-6AFVOR.log
This section will help you troubleshoot problems related to the Dockerized Druid.
When using Docker on OSX, the Docker environment will be executed within the https://github.com/docker/hyperkit hypervisor, a lightweight visualization framework for running the Docker containers:
docker-druid foobar$ ps -ax | grep docker.hyperkit 71175 ?? 0:04.02 /Applications/Docker.app/Contents/MacOS/com.docker.hyperkit -A -m 2048M -c 4 -u -s ...
The allocated resources are limited by default to 2 cpu's and 2gb of memory. Although 2gb is sufficient in most application, the Druid container is rather heavyweight because of the Mysql, Zookeeper and the JVM's. When start spawning additional JVM's, for example an indexing job, this might cause issues:
2017-01-20T15:59:58,445 INFO [forking-task-runner-0-[index_transactions_2017-01-20T15:59:50.637Z]] io.druid.indexing.overlord.ForkingTaskRunner - Process exited with status[137] for task: index_transactions_2017-01-20T15:59:50.637Z
From the log we observe that the process receives an 137 (=128+9) SIGKILL signal. Because it hit the memory limit, the application is killed instantly. To avoid this you might want to give more resources to the Docker hypervisor under Docker > Preferences.

探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式
通过 Docker 登录认证访问私有仓库
无需登录使用专属域名
Kubernetes 集群配置 Containerd
K3s 轻量级 Kubernetes 镜像加速
VS Code Dev Containers 配置
Podman 容器引擎配置
HPC 科学计算容器配置
ghcr、Quay、nvcr 等镜像仓库
Harbor Proxy Repository 对接专属域名
Portainer Registries 加速拉取
Nexus3 Docker Proxy 内网缓存
需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单
manifest unknown
no matching manifest(架构)
invalid tar header(解压)
TLS 证书失败
DNS 超时
410 Gone 排查
402 与流量用尽
401 认证失败
429 限流
D-Bus 凭证提示
413 与超大单层
来自真实用户的反馈,见证轩辕镜像的优质服务