找回密码
 注册
查看: 3481|回复: 0

yum源报错

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2018-7-19 23:50:20 | 显示全部楼层 |阅读模式
# yum install -y chrony.x86_64 % ?$ W/ B5 P: g; ^( s7 B# f
Loaded plugins: fastestmirror
1 r- E  ]0 \: k- `! ALoading mirror speeds from cached hostfile
# |0 Q* f" a3 M, o" `9 k4 U* o * base: ftp.sjtu.edu.cn
, k9 H: s8 I; _# ~ * extras: mirrors.huaweicloud.com
5 ?: |. o9 O, S7 d$ n' J: ?' ] * updates: ftp.sjtu.edu.cn
4 {3 G2 V8 X; _0 J: lbase                                                                                                     | 3.6 kB  00:00:00     ) |5 L" S- B$ |. J4 r" w% C
centos-ceph-jewel                                                                                        | 2.9 kB  00:00:00     7 d, K6 R5 L; Z. v2 H
centos-openstack-pike                                                                                    | 2.9 kB  00:00:00     
7 Q7 J3 @2 c# s1 l& z+ ihttp://mirror.centos.org/altarch/7/virt/x86_64/kvm-common/repodata/repomd.xml: [Errno 14] HTTP Error 404 - Not Found) T& t! R! a# y" e, u- }! N- F
Trying other mirror.
$ n' y( Q5 q# Q1 K( N7 E$ c3 R; l7 @To address this issue please refer to the below wiki article
! |- w6 ~: ~. g7 ihttps://wiki.centos.org/yum-errors
, ~& f2 U- ]' U1 Z  q8 _If above article doesn't help to resolve this issue please use https://bugs.centos.org/.  B0 B) K" }" [7 Z7 j
" A4 {) q9 |2 C1 Y) l+ x9 W0 B
One of the configured repositories failed (CentOS-7 - QEMU EV),
" G. _, I$ S& s and yum doesn't have enough cached data to continue. At this point the only
3 y  E* ]+ I) b* y- h$ G0 v6 j) Y8 ] safe thing yum can do is fail. There are a few ways to work "fix" this:
- f4 s. D; V) A7 ?8 Z     1. Contact the upstream for the repository and get them to fix the problem.
# P9 L1 [, o2 M     2. Reconfigure the baseurl/etc. for the repository, to point to a working
9 K5 E+ s% m- Q/ j4 E        upstream. This is most often useful if you are using a newer
9 b  u0 l" x5 I# S8 p1 m+ @        distribution release than is supported by the repository (and the$ _$ @8 X# _# X8 S  @
        packages for the previous distribution release still work).; g7 H" o! Z: l$ u, n
     3. Run the command with the repository temporarily disabled
& d- S0 i5 p+ @2 O0 K& u            yum --disablerepo=centos-qemu-ev ...% ^' |  v! n7 b4 g2 H# b# J3 k$ K8 b
     4. Disable the repository permanently, so yum won't use it by default. Yum; _0 s+ A, k3 d- m- N9 |! U
        will then just ignore the repository until you permanently enable it4 }% d1 \, Q" U. w  G
        again or use --enablerepo for temporary usage:
* Q4 |6 R( v5 g7 g4 ^. f            yum-config-manager --disable centos-qemu-ev
! ]) I% u& }* M) r3 ?* f        or8 k& t7 _0 n4 i, S- Y: N
            subscription-manager repos --disable=centos-qemu-ev
( f, ]6 r- P, S( d* C, P- u0 J     5. Configure the failing repository to be skipped, if it is unavailable.
8 y& b( E8 \! Q4 L) R+ P        Note that yum will try to contact the repo. when it runs most commands,
% ?* v& |& B8 t        so will have to try and fail each time (and thus. yum will be be much
/ p0 C( w1 G; Z# W! }' j& k        slower). If it is a very temporary problem though, this is often a nice
! I$ N3 Q+ _8 W. B        compromise:" }2 P% k$ i, K- ^+ `( ?* q2 M
            yum-config-manager --save --setopt=centos-qemu-ev.skip_if_unavailable=true( P2 v, i+ X4 _  t
failure: repodata/repomd.xml from centos-qemu-ev: [Errno 256] No more mirrors to try.* c+ X5 D/ I; V3 }; B: G1 F& v2 g  J
http://mirror.centos.org/altarch/7/virt/x86_64/kvm-common/repodata/repomd.xml: [Errno 14] HTTP Error 404 - Not Found: |4 ^) f, d9 w* J+ z

7 G! i% ]# x) M3 @: E) ]报错原因是因为yum源配置文件CentOS-QEMU-EV.repo有问题,需要验证所以会报错。
3 U4 ^- t9 u8 m5 u# vim /etc/yum.repos.d/CentOS-QEMU-EV.repo 6 {: w% O* [! [. t. N
将默认状态的
. R# A% o4 u4 I1 T8 K6 vgpgcheck=1( t, C& v+ ?0 o4 [- L
enabled=1
9 k" h! a+ a" y/ E& e; J5 P* R修改为:. M0 h/ C6 m% e- V' s# W6 G  V
+ e: @5 k2 ]: C9 W( x
gpgcheck=0
! F9 N9 B" x# C! ~/ |enabled=0
9 v9 A. y% d8 a: W! o- u
9 G8 e7 f" g4 l) P' w再次安装就不会出现问题了。
) ^7 p% T+ G' z* B& x& }: L
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 01:23 , Processed in 0.016401 second(s), 22 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表