LoginSignup
5
11

More than 5 years have passed since last update.

yumがepelのmirrorにつながんねーよと怒ってる時の対処法

Last updated at Posted at 2016-12-16

事象

新しくインスタンスを建てたので、yumでパッケージをアプデしようとしたところ

# yum -y update && yum -y groupinstall "Development Tools"
読み込んだプラグイン:fastestmirror, langpacks
base                                                     | 3.6 kB     00:00     
epel/x86_64/metalink                                     | 5.2 kB     00:00     
epel                                                     | 4.3 kB     00:00     
http://ftp.jaist.ac.jp/pub/Linux/Fedora/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel                                                     | 4.3 kB     00:00     
http://ftp.riken.jp/Linux/fedora/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel                                                     | 4.3 kB     00:00     
https://mirrors.tuna.tsinghua.edu.cn/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。

という表示になった。
最初はNWの問題かと思い応答を確認したが特に問題はなく、
よくエラーを見たら repomd.xml does not match metalink for epel と書かれているため、
どうやらサーバには繋がっているもののメタリンクの整合性が取れないということでエラーが出ているようだった。

対処

にかかれていた方法を使い解決。

/etc/yum.repos.d/epel.repoについて以下のように変更

[epel]
name=Extra Packages for Enterprise Linux 7 - $basearch
baseurl=http://download.fedoraproject.org/pub/epel/7/$basearch
#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch
failovermethod=priority
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7
5
11
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
11