docker - 为Druid构建Docker镜像时出错

标签 docker hadoop curl druid

我正在执行此tutorial以使用Apache Hadoop加载批处理数据,并且尝试运行此命令来构建名为“druid-hadoop-demo”的Docker镜像,其版本标签为“2.8.5”:docker build -t druid-hadoop-demo:2.8.5 .
但这给了我这个错误

Step 14/53 : RUN curl -s https://archive.apache.org/dist/hadoop/core/hadoop-2.8.3/hadoop-2.8.3.tar.gz | tar -xz -C /usr/local/ ---> Running in 7baa699ccc29

gzip: stdin: unexpected end of file tar: Child returned status 1 tar: Error is not recoverable: exiting now The command '/bin/sh -c curl -s https://archive.apache.org/dist/hadoop/core/hadoop-2.8.3/hadoop-2.8.3.tar.gz | tar -xz -C /usr/local/' returned a non-zero code: 2



任何帮助表示赞赏。

最佳答案

这是网络错误,表明您下载的文件在传输过程中已损坏(对我而言下载正确,因此不太可能是源文件),或者在完成curl命令之前已断开连接。检查网络代理,间歇性网络故障或任何其他可能中断连接的情况。您也可以尝试从容器内手动运行curl以查看它是否成功,例如

curl -o hadoop.tgz https://archive.apache.org/dist/hadoop/core/hadoop-2.8.3/hadoop-2.8.3.tar.gz
tar -tvzf hadoop.tgz

关于docker - 为Druid构建Docker镜像时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59937614/

相关文章:

docker - 当 docker 容器 pod 出现 Error 或 CarshLoopBackOff kubernetes 时发出警报

linux - CoreOS - 通过 PID 获取 docker 容器名称?

hadoop - CustomWritable 对象导致测试用例失败

javascript - 理解 curl 和 axios react 之间差异的问题

docker - 如何修复类型 "bind": source path must be a directory in Windows docker Container? 的无效挂载配置

docker - 在本地 Docker 容器和 K8S 中运行 Azure Function Service Bus Trigger

apache-spark - 将文本文件数据过滤为pyspark rdd和dataframe中的列

java - hadoop 中用于映射器和组合器的不同上下文类型

ssl - curl SSL 证书错误 : verifcation failed

javascript - 有没有办法从一个别名下的所有索引中获得一个统一的映射?