转:

E: Some index files failed to download. They have been**

问题描述:

当使用Dockerfile从包含cuda的镜像建立新的image的时候,显示以下bug:

Step 7/8 : RUN apt-get update && DEBIAN_FRONTEND="noninteractive" apt-get install -y -q     libcudnn6=$CUDNN_VERSION-1+cuda8.0     libcudnn6-dev=$CUDNN_VERSION-1+cuda8.0  && rm -rf /var/lib/apt/lists/*
---> Running in 94b890e74e5a
Get:1 http://security.ubuntu.com/ubuntu xenial-security InRelease [102 kB]
Ign:2 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 InRelease
Get:3 http://archive.ubuntu.com/ubuntu xenial InRelease [247 kB]
Ign:4 http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 InRelease
Get:5 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 Release [564 B]
Get:6 http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 Release [564 B]
Get:7 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 Release.gpg [801 B]
Get:8 http://security.ubuntu.com/ubuntu xenial-security/universe Sources [73.2 kB]
Get:9 http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 Release.gpg [801 B]
Get:10 http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 Packages [98.4 kB]
Get:11 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages [589 kB]
Get:12 http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 Packages [17.9 kB]
Err:12 http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64 Packages
Hash Sum mismatch
Get:13 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [102 kB] Get:14 http://archive.ubuntu.com/ubuntu xenial-backports InRelease [102 kB] Get:15 http://archive.ubuntu.com/ubuntu xenial/universe Sources [9,802 kB]
Get:16 http://security.ubuntu.com/ubuntu xenial-security/restricted amd64 Packages [12.7 kB]
Get:17 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 Packages [406 kB]
Get:18 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 Packages [3,486 B] Get:19 http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages [1,558 kB]
Get:20 http://archive.ubuntu.com/ubuntu xenial/restricted amd64 Packages [14.1 kB] Get:21 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages [9,827 kB] Get:22 http://archive.ubuntu.com/ubuntu xenial/multiverse amd64 Packages [176 kB]
Get:23 http://archive.ubuntu.com/ubuntu xenial-updates/universe Sources [242 kB]
Get:24 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [957 kB]
Get:25 http://archive.ubuntu.com/ubuntu xenial-updates/restricted amd64 Packages [13.1 kB]
Get:26 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [766 kB]
Get:27 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 Packages [18.5 kB]
Get:28 http://archive.ubuntu.com/ubuntu xenial-backports/main amd64 Packages [5,153 B]
Get:29 http://archive.ubuntu.com/ubuntu xenial-backports/universe amd64 Packages [7,705 B]
Fetched 25.1 MB in 9s (2,576 kB/s) Reading package lists...
E: Failed to fetch http://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1604/x86_64/Packages.gz Hash Sum mismatch
E: Some index files failed to download. They have been ignored, or old ones used instead.

解决方案

在Dockerfile 运行这行代码

 RUN apt-get -qq -y update &&
DEBIAN_FRONTEND=noninteractive apt-get -qq -y install
gcc
...

之前加入以下代码

 RUN rm /etc/apt/sources.list.d/cuda.list && rm /etc/apt/sources.list.d/nvidia-ml.list

成功解决!

转:

E: Some index files failed to download. They have been**

E: Some index files failed to download. They have been**的更多相关文章

  1. Some index files failed to download. They have …… or old ones used instead

    问题: 平台:Ubuntu12.04 W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/precise/universe/bin ...

  2. 在ubuntu更新时,出现错误E: Some index files failed to download, they have been ignored, or old ones used inst

    原文:https://blog.csdn.net/tian_ciomp/article/details/51339635 在ubuntu更新时,出现错误E: Some index files fail ...

  3. Linux - Ubuntu下执行apt-get update报错:Some index files failed to download. They have been ignored, or old ones used instead.

    报错命令 root@ubuntu:/etc/apt# apt-get update Err: http://mirrors.aliyun.com/ubuntu trusty InRelease Cou ...

  4. vue-cli · Failed to download repo vuejs-templates/webpack: self signed certificate in certificate chain

    vue init webpack <Project name> 报错: vue-cli · Failed to download repo vuejs-templates/webpack: ...

  5. Unity3D发布WebPlayer时Failed to download data file解决方案

    今天发布WebPlayer时, 发现直接打开html是可以正常运行的, 但是通过iis访问的话就会报错: Failed to download data file. 一开始以为是防火墙, 后来发现不是 ...

  6. vue-cli · Failed to download repo vuejs-templates/webpack: connect ETIMEDOUT 13.229.188.59:443

    初始化vue项目 vue init webpack vue-demo 之后 一直报vue-cli · Failed to download repo vuejs-templates/webpack: ...

  7. vue-cli 安装失败Failed to download repo vuejs-templates/vuedemo: Response code 404 (Not Found)

    还原问题现场: 第一次使用vue init webpack projectName的时候,由于操作失误,执行了两次npm install -g vue-cli,然后再使用vue init webpac ...

  8. Unity 3D本地公布WebPlayer版时&quot;Failed to download data file&quot;解决方式

    watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvbGlzZW55YW5n/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA ...

  9. vue-cli · Failed to download repo vuejs-templates/webpack-simple: tunneling socket could not be established, cause=connect ECONNREFUSED 127.0.0.1:8086 && vue init webpack-simple xxx

    vue init webpack-simple mywork报错如下: vue-cli · Failed to download repo vuejs-templates/webpack-simple ...

随机推荐

  1. CF1313C2 Skyscrapers (hard version)

    思路: 使用单调栈. 实现: 1 #include <bits/stdc++.h> 2 using namespace std; 3 typedef long long ll; 4 con ...

  2. 【hdu 1576】A/B(数论--拓展欧几里德 求逆元 模版题)

    题意:给出 A%9973 和 B,求(A/B)%9973的值. 解法:拓展欧几里德求逆元.由于同余的性质只有在 * 和 + 的情况下一直成立,我们要把 /B 转化为 *B-1,也就是求逆元. 对于 B ...

  3. 【noi 2.2_1751】分解因数(递归)

    题意:问一个给定正整数的分解因数的方式数.N=a1*a2*...*ak(a1<=a2<=...<=ak). 解法:一步步分解该数,总方式数为一个个因数被分解的方案数之和. 可用大括号 ...

  4. 2020ICPC&#183;小米 网络选拔赛第一场 J.Matrix Subtraction (贪心,二维差分)

    题意:给一个\(nXm\)的矩阵,可以选取\(aXb\)的子矩阵,使子矩阵中的所有元素减一,问最后是否能使矩阵中所有元素变为\(0\). 题解:首先贪心,我们看最左上角的元素,如果\(g[1][1]\ ...

  5. Relatives POJ - 2407 欧拉函数

    题意: 给你一个正整数n,问你在区间[1,n)中有多少数与n互质 题解: 1既不是合数也不是质数(1不是素数) 互质是公约数只有1的两个整数,叫做互质整数.公约数只有1的两个自然数,叫做互质自然数 所 ...

  6. 【ybt金牌导航1-2-5】【luogu P3287】优美玉米 / 方伯伯的玉米田

    优美玉米 / 方伯伯的玉米田 题目链接:ybt金牌导航1-2-5 / luogu P3287 题目大意 有一个数组,你可以每次给一个区间里面的值加一,要你使得最后剩下的最长单调不下降子序列最长. 思路 ...

  7. 揭秘井井有条的流水线(ZooKeeper 原理篇)

    本文作者:HelloGitHub-老荀 Hi,这里是 HelloGitHub 推出的 HelloZooKeeper 系列,免费开源.有趣.入门级的 ZooKeeper 教程,面向有编程基础的新手. Z ...

  8. word2vector论文笔记

    背景 很多当前的NLP系统和技术都把单词像ont-hot一样当做原子性的一个概念去对待,单纯就是一个索引,无法表示词之间的相似性.原因就是往往一个简单的.鲁棒的.可观测的模型在海量数据集上的学习效果要 ...

  9. Linux下的C语言编程

    一.在Linux下的C语言编程所需工具(下面所列举的都是我编程所用的工具) 1.文本编辑器 Vim 2.编译链接工具 gcc 3.调试器 gdb 4.项目管理工具 make和makefile 二.VI ...

  10. C# 类 (6) -继承

    继承 定义类的时候,public class Dog:Animal 表示 Dog 这个类是 继承自 Animal,冒号后面的是它的基类 继承后 的Dog 类,当调用Dog.Great() 的时候输出的 ...