今まで問題なかった環境で yum update
を実行してエラーが発生した場合の対処法について。
yum update でエラー
yum update
出力例
読み込んだプラグイン:fastestmirror
base | 3.6 kB 00:00:00
epel/x86_64/metalink | 5.4 kB 00:00:00
epel | 4.3 kB 00: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
他のミラーを試します。
epel | 4.3 kB 00:00:00
http://epel.mirror.net.in/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
https://repo.fedoralinux.ir/pub/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
https://epel.mirror.angkasa.id/pub/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
http://kartolo.sby.datautama.net.id/EPEL/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
http://epel.scopesky.iq/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
http://ftp.cuhk.edu.hk/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:00
http://mirror01.idc.hinet.net/EPEL/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
http://mirror.rise.ph/fedora-epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00: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: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:00
https://mirror.lzu.edu.cn/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
epel | 4.3 kB 00:00:00
https://mirror.pregi.net/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
他のミラーを試します。
One of the configured repositories failed (Extra Packages for Enterprise Linux 7 - x86_64),
and yum doesn't have enough cached data to continue. At this point the only
safe thing yum can do is fail. There are a few ways to work "fix" this:
1. Contact the upstream for the repository and get them to fix the problem.
2. Reconfigure the baseurl/etc. for the repository, to point to a working
upstream. This is most often useful if you are using a newer
distribution release than is supported by the repository (and the
packages for the previous distribution release still work).
3. Disable the repository, so yum won't use it by default. Yum will then
just ignore the repository until you permanently enable it again or use
--enablerepo for temporary usage:
yum-config-manager --disable epel
4. Configure the failing repository to be skipped, if it is unavailable.
Note that yum will try to contact the repo. when it runs most commands,
so will have to try and fail each time (and thus. yum will be be much
slower). If it is a very temporary problem though, this is often a nice
compromise:
yum-config-manager --save --setopt=epel.skip_if_unavailable=true
failure: repodata/repomd.xml from epel: [Errno 256] No more mirrors to try.
https://mirrors.tuna.tsinghua.edu.cn/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://epel.mirror.net.in/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
https://repo.fedoralinux.ir/pub/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
https://epel.mirror.angkasa.id/pub/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://kartolo.sby.datautama.net.id/EPEL/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://epel.scopesky.iq/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://ftp.cuhk.edu.hk/pub/linux/fedora-epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://mirror01.idc.hinet.net/EPEL/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://mirror.rise.ph/fedora-epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
http://ftp.riken.jp/Linux/fedora/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
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
https://mirror.lzu.edu.cn/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
https://mirror.pregi.net/epel/7/x86_64/repodata/repomd.xml: [Errno -1] repomd.xml does not match metalink for epel
原因と対策
yum update epel-release --disablerepo=epel
インストールされている epel-release のバージョンが古いのが原因。
これを解消するために epel リポジトリを --disablerepo
オプションで無効にしてアップデートする。
出力例
読み込んだプラグイン:fastestmirror
base | 3.6 kB 00:00:00
extras | 3.4 kB 00:00:00
updates | 3.4 kB 00:00:00
(1/4): extras/7/x86_64/primary_db | 98 kB 00:00:00
(2/4): base/7/x86_64/group_gz | 155 kB 00:00:00
(3/4): updates/7/x86_64/primary_db | 1.3 MB 00:00:01
(4/4): base/7/x86_64/primary_db | 5.6 MB 00:00:02
Determining fastest mirrors
* base: ftp.yz.yamagata-u.ac.jp
* extras: ftp.yz.yamagata-u.ac.jp
* updates: ftp.yz.yamagata-u.ac.jp
依存性の解決をしています
--> トランザクションの確認を実行しています。
---> パッケージ epel-release.noarch 0:7-8 を 更新
---> パッケージ epel-release.noarch 0:7-9 を アップデート
--> 依存性解決を終了しました。
依存性を解決しました
=================================================================
Package アーキテクチャー バージョン リポジトリー 容量
=================================================================
更新します:
epel-release noarch 7-9 extras 14 k
トランザクションの要約
=================================================================
更新 1 パッケージ
総ダウンロード容量: 14 k
Is this ok [y/d/N]: y
Downloading packages:
Delta RPMs disabled because /usr/bin/applydeltarpm not installed.
epel-release-7-9.noarch.rpm| 14 kB 00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
更新します : epel-release-7-9.noarch 1/2
整理中 : epel-release-7-8.noarch 2/2
検証中 : epel-release-7-9.noarch 1/2
検証中 : epel-release-7-8.noarch 2/2
更新:
epel-release.noarch 0:7-9
完了しました!