2021-07-22linux运维yum下载老报错,尝试其他镜像网络不可达

简介: 2021-07-22linux运维yum下载老报错,尝试其他镜像网络不可达

最近遇到了一个很头痛的事,就是在装完zabbix后,有墙访问不了对应的库,导致软件无法通过yum下载

报错如下

http://repo.zabbix.com/zabbix/4.0/rhel/7/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2604:a880:2:d0::2062:d001: 网络不可达"
正在尝试其它镜像。
http://repo.zabbix.com/zabbix/4.0/rhel/7/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2604:a880:2:d0::2062:d001: 网络不可达"
正在尝试其它镜像。
http://repo.zabbix.com/zabbix/4.0/rhel/7/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2604:a880:2:d0::2062:d001: 网络不可达"
正在尝试其它镜像。
http://repo.zabbix.com/zabbix/4.0/rhel/7/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2604:a880:2:d0::2062:d001: 网络不可达"
正在尝试其它镜像。
http://repo.zabbix.com/zabbix/4.0/rhel/7/x86_64/repodata/repomd.xml: [Errno 14] curl#7 - "Failed to connect to 2604:a880:2:d0::2062:d001: 网络不可达"

我汉化过了可能有的报错和我的不一致不过看具体报错信息即可,这个主要是因为zabbix是国外的,国内访问不了国外的网络,有墙挡住,这个时候我们可以选择更换阿里云的镜像,即可访问

修改方法如下复制粘贴即可

[root@bogon ~]# cat /etc/yum.repos.d/zabbix.repo
[zabbix]
name=Zabbix Official Repository - $basearch
#baseurl=http://repo.zabbix.com/zabbix/4.0/rhel/7/$basearch/
baseurl=https://mirrors.aliyun.com/zabbix/zabbix/4.0/rhel/7/$basearch/    # 换成阿里云的yum源
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX-A14FE591
[zabbix-non-supported]
name=Zabbix Official Repository non-supported - $basearch
#baseurl=http://repo.zabbix.com/non-supported/rhel/7/$basearch/
baseurl=https://mirrors.aliyun.com/zabbix/non-supported/rhel/7/$basearch/  #换成阿里云的yum源
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX
gpgcheck=1

最后

[root@bogon ~] yum clean all
[root@bogon ~] yum -y install zabbix-server-mysql zabbix-web-mysql zabbix-agent

我们会发现可以继续下载了,然后就可以安心搞我的ansible了,如果没搞好可以给我留个言,看到会回复帮着处理


目录
相关文章
|
运维 监控 网络协议
|
分布式计算 网络协议 Hadoop
Linux服务器运维基本操作 - 网络管理
一、主机名配置 二、IP地址配置 三、域名映射 四、网络端口监听
Linux服务器运维基本操作 - 网络管理
|
运维 监控
2021-07-22linux运维yum下载老报错,尝试其他镜像网络不可达
2021-07-22linux运维yum下载老报错,尝试其他镜像网络不可达
1204 0
|
运维 Linux 虚拟化
【Linux运维】安装——配置网络
【Linux运维】安装——配置网络
406 0
|
存储 缓存 运维
Linux运维:网络管理
Linux运维:网络管理
757 0
|
运维 Linux
跟老男孩学linux运维 -- 摘要,虚拟机网络,分区等
跟老男孩学linux运维 -- 摘要,虚拟机网络,分区等
282 0
跟老男孩学linux运维 -- 摘要,虚拟机网络,分区等