yum install git

问题:

[root@hcss-ecs-2a6a maven]# yum install git
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
base                                                                                                                                                         | 3.6 kB  00:00:00     
https://download.docker.com/linux/centos/7/x86_64/stable/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2a03:2880:f117:83:face:b00c:0:25de: Network is unreachable"
Trying other mirror.
https://download.docker.com/linux/centos/7/x86_64/stable/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2a03:2880:f117:83:face:b00c:0:25de: Network is unreachable"
Trying other mirror.

更换镜像源

你可以尝试使用阿里云的 Docker 仓库镜像源。编辑 /etc/yum.repos.d/docker-ce.repo 文件,将内容替换为:

[docker-ce-stable]
name=Docker CE Stable - $basearch
baseurl=https://mirrors.aliyun.com/docker-ce/linux/centos/7/$basearch/stable
enabled=1
gpgcheck=1
gpgkey=https://mirrors.aliyun.com/docker-ce/linux/centos/gpg

然后运行以下命令更新仓库缓存并安装 Docker:

sudo yum makecache fast
sudo yum install docker-ce

通过这些步骤,你应该能够解决网络连接问题并成功安装 Docker。

  • 2
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值