Centos 7 yum执行问题
来源:互联网 发布:php中单引号和双引号 编辑:程序博客网 时间:2024/06/15 15:51
今天安装InfluxDB的时候一直无法顺利安装,后来发现yum -y update都无法执行了。
看异常:
[root@iZ8vb8r420ejxfron03cj7Z ~]# sudo yum install influxdbLoaded plugins: fastestmirrorbase | 3.6 kB 00:00:00 epel | 4.3 kB 00:00:00 extras | 3.4 kB 00:00:00 https://packagecloud.io/grafana/stable/el/6/x86_64/repodata/repomd.xml: [Errno 14] HTTPS Error 302 - FoundTrying other mirror. One of the configured repositories failed (grafana), 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 grafana 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=grafana.skip_if_unavailable=truefailure: repodata/repomd.xml from grafana: [Errno 256] No more mirrors to try.https://packagecloud.io/grafana/stable/el/6/x86_64/repodata/repomd.xml: [Errno 14] HTTPS Error 302 - Found
我这里比较有针对性,但是在网上搜了之后总算找到解决方案。
修改/etc/resolv.conf文件,添加nameserver 8.8.8.8,如果是国内的话添加nameserver 114.114.114.114。
执行:
[root@iZ8vb8r420ejxfron03cj7Z yum.repos.d]# cat /etc/resolv.conf #options timeout:1 attempts:1 rotate single-request-reopen#nameserver 114.114.114.114nameserver 8.8.8.8
注意,这里只能保留一个,我要用到的是8.8.8.8的。
之后执行:
service network restart
重试之后一切OK了。
阅读全文
0 0
- Centos 7 yum执行问题
- centos yum问题
- 关于旧版CentOS(5.0以下)无法执行yum install的问题
- centos 5.5 yum 的问题
- centos yum 源 问题解析
- centos 7 pip yum
- Centos 7 安装yum
- RedHat5.7 yum更换为CentOS yum
- Centos 4 yum 无法使用的问题
- CentOs yum遇到的小问题
- centos的yum更新源问题
- centos本地yum源错误引起问题
- centos中yum相关问题梳理(一)
- 解决CentOS-5 yum无法更新问题
- centos更新yum时遇到的问题
- CentOS 7 yum 安装 MongoDB
- centos 7 yum源配置
- CentOS 7 yum install mysql
- Sim 卡运营商获取
- Tomcat8安装说明
- E
- Android 性能优化之Loading Big Bitmaps
- hdu-2842(矩阵快速幂+推导)
- Centos 7 yum执行问题
- linux(二)之linux常用命令一
- 数据库设计原则(不错)
- logback logback.xml常用配置详解(三) <filter>
- MVC的各个部分都有那些技术来实现?如何实现?
- xml面试题
- 索引结构(正向索引结构)--tvx,tvf,tvd
- css学习笔记2
- Java多线程系列--“JUC集合”04之 ConcurrentHashMap