首页 > 其他分享 >Error: Failed to download metadata for repo 'appstream': Cannot prepare internal mirrorlis

Error: Failed to download metadata for repo 'appstream': Cannot prepare internal mirrorlis

时间:2022-08-17 23:26:27浏览次数:68  
标签:sed centos CentOS repos prepare mirrorlist appstream http

报错:Error: Failed to download metadata for repo 'appstream': Cannot prepare internal mirrorlist: No URLs in mirrorlist

原因: CentOS 已经停止维护的问题

官方:https://blog.centos.org/2020/12/future-is-centos-stream/?spm=a2c4g.11186623.0.0.3b005eb35dW2Kg

解决:

# sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-*
# sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-*

或者

sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Linux-*

sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.epel.cloud|g' /etc/yum.repos.d/CentOS-Linux-*

标签:sed,centos,CentOS,repos,prepare,mirrorlist,appstream,http
From: https://www.cnblogs.com/yu121/p/16597175.html

相关文章