docker拉取镜像遇见的问题

问题一:

CentOS报错:Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock32 error was 14: curl#6 - "Could not resolve host: mirrorlist.centos.org; Unknown error"

  1. 切换至root用户
  2. 找到 cat /etc/sysconfig/network-scripts/ifcfg-ens33 文件,查看ONBOOT是否为yes
  3. 重启网络 service network restart
  4. ping www.baidu.com查看网络连接是否正常
  5. 如果还是报错 则输入
  • wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
  • wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo
  • yum clean all
  • yum makecache

问题二:

error pulling image configuration: download failed after attempts=6: dial tcp 59.188.250.54:443: i/o timeout,镜像源太差,拉取镜像失败

  1. 查看下防火墙的状态:systemctl status firewalld
  2. 关闭防火墙:systemctl stop firewalld
  3. 禁止开机自动启动防火墙:systemctl disable firewalld.service 
  4. 更换镜像源
  5. sudo mkdir -p /etc/docker
    sudo tee /etc/docker/daemon.json <<-'EOF'
    {
      "registry-mirrors": [
        //配置阿里云加速器
        "https://registry.docker-cn.com",
        "https://docker.mirrors.ustc.edu.cn",
        "https://hub-mirror.c.163.com",
        "https://mirror.baidubce.com",
        "https://dockerhub.icu/",
        "https://docker.m.daocloud.io"
      ]
    }
    EOF
    sudo systemctl daemon-reload
    sudo systemctl restart docker

Linux镜像拉取失败_error pulling image configuration: download failed-CSDN博客

如何完美解决 “error pulling image configuration: download failed after attempts=6: dial tcp 59.188.250.54-CSDN博客

Docker入门安装、镜像与容器下载 —— 基本操作_docker下载教程-CSDN博客

Docker下载镜像(配置阿里云加速器)和容器的基本使用(有指令解释哦~)_docker镜像下载-CSDN博客

CentOS报错:Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock32 error was 14: curl#6 - "Could not resolve host: mirrorlist.centos.org; Unknown error" - Mr.毛小毛 - 博客园 (cnblogs.com)

linux gcc安装报错【Loading mirror speeds from cached hostfile \n There are no enabled repos】解决办法_loading mirror speeds from cached hostfile there a-CSDN博客

Centos7下关闭防火墙_centos7下关闭防护墙-CSDN博客

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值