rhel 7.0 配置centos yum源(2016/12/8),成功!
1.首先查看redhat 7.0系统本身所安装的那些yum 软件包:
rpm -qa | grep yum #列出所有已安装的yum包
2.删除这些包:
rpm -e *.rpm --nodeps #删除所有以前的yum包
3.下载新的yum rpm包:(2016/12/8 最新版本rpm,如果404 NOT FOUND错误,自己进去网址,换成最新的rpm包的名字)
wget http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-3.4.3-132.el7.centos.0.1.noarch.rpm
wget http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-metadata-parser-1.1.4-10.el7.x86_64.rpm
wget http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-utils-1.1.31-34.el7.noarch.rpm
wget http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-updateonboot-1.1.31-34.el7.noarch.rpm
wget http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.31-34.el7.noarch.rpm
4.安装下载的rpm包:
rpm -ivh yum-*
5.配置CentOS-Base.repo:(2016/12/8 最新源网址配置)
vim /etc/yum.repos.d/CentOS-Base.repo
[base]
name=CentOS-7-Base
baseurl=http://mirrors.sohu.com/centos/7/os/x86_64/
gpgcheck=1
#released updates
[updates]
name=CentOS-7- Updates
baseurl=http://mirrors.163.com/centos/7/updates/x86_64/
gpgcheck=1
gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7
#packages used/produced in the build but not released
[addons]
name=CentOS-7- Addons
baseurl=http://mirrors.163.com/centos/7/sclo/x86_64/sclo/
gpgcheck=1
gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7
#additional packages that may be useful
[extras]
name=CentOS-7- Extras
baseurl=http://mirrors.163.com/centos/7/extras/x86_64/
gpgcheck=1
gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-7
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-7- Plus
baseurl=http://mirrors.163.com/centos/7/centosplus/x86_64/
gpgcheck=1
enabled=0
6.yum源配置完成:
yum clean all
7.测试yum是否成功:
yum update python
报错:You have enabled checking of packages via GPG keys. This is a good thing. However, you do not have any GPG public keys installed. You need to download the keys for packages you wish to install and install them. You can do that by running the command.
rpm --import public.gpg.key
.........
经查,是key的错误,解决方法是:
cd /etc/pki/rpm-gpg/
ls #列出所有密钥
导入以 release 结尾的密钥
rpm --import RPM-GPG-KEY-redhat-legacy-release
8.经测试,yum成功:
yum update python #顺利使用yum
rhel 7.0 配置centos yum源(2016/12/8),成功!的更多相关文章
- RHEL 6.0使用CentOS yum源
引言:由于RHEL的yum在线更新是收费的,如果没有注册的话是不能使用的,即不能在线安装软件.在这种情况下,想使用RHEL系统,还想用yum源来在线安装软件,有没有办法?答案是有办法,请往下看! 1. ...
- RHEL6配置CentOS yum源
RHEL6配置CentOS yum源
- RHEL 6.3使用CentOS yum源 (redhat yum安装失败)
由于Redhat的yum在线更新是收费的,如果没有注册的话是不能使用的,即不能在线安装软件.所以yum install 命令每次都安装失败 下面介绍一种更改yum源的方式: 系统说明: 系统:Red ...
- rhel7.0替换centos yum源
1:卸载原先的yum 2:安装centos的yum 有以下的yum yum-utils-1.1.31-24.el7.noarch yum-langpacks-0.4.2-3.el7.noarch yu ...
- RHEL6.×配置Centos YUM源
Step1: 清除原有的yum源rpm -aq|grep yum|xargs rpm -e --nodeps Step2:下载新的yum()源进行安装,注意操作系统支持64位还是32位wget htt ...
- Rhel5.5配置Centos yum源
ruiy哥,抛砖引玉 当你使用rhel系统时,[大部分数据库中心及政府企业选择linux服务器时通常考虑采购的版本一般不外乎是Rhel红帽及Suse,理由你懂的EcoSystem!]你没有一个红帽网络 ...
- RedHat 更新CentOS Yum源(转)
经测试,可用.转自:https://www.cnblogs.com/tangsen/p/5151994.html 一.随笔引言 1.1随笔内容: 1.RedHat 配置Centos yum源 2.yu ...
- 使用 ISO镜像配置 本地yum 源(RHEL, CentOS, Fedora等适用)
使用 ISO镜像配置 本地yum 源(RHEL, CentOS, Fedora等适用) 1.上传ISO镜像和挂载 1) 上传Centos7.2 ISO镜像到 /usr/local/src目录 2) ...
- (转载)centos yum源的配置和使用
原文地址:http://www.cnblogs.com/mchina/archive/2013/01/04/2842275.html 一.yum 简介 yum,是Yellow dog Updater, ...
随机推荐
- 详解ASP.NET MVC的请求生命周期
本文的目的旨在详细描述asp.net mvc请求从开始到结束的每一个过程. 我希望能理解在浏览器输入url并敲击回车来请求一个asp.net mvc网站的页面之后发生的任何事情. 为什么需要关心这些? ...
- Oracle 取随机数
1.从表中随机取记录 select * from (select * from staff order by dbms_random.random) where rownum < 4 ...
- Unity Standard Assets 简介之 其他资源
还有一些其他资源包,要不就是已经有Unity官方的介绍了,要不就是以资源为主没有多少脚本,最后集中说明一下. Effects资源包:包含各种图像特效,Unity官方文档地址 http://docs.u ...
- js的三种继承方式及其优缺点
[转] 第一种,prototype的方式: //父类 function person(){ this.hair = 'black'; this.eye = 'black'; this.skin = ' ...
- pushState与ajax实现无刷新加载
一.JS代码: $(document).ready(function() { getContent();//初始化页面 $("nav a").click(function() { ...
- js入门篇之正则表达式基础
定义:正则用于规定在文本中检索的内容,它是对字符串执行模式匹配的强大工具 RegExp(正则表达式) 对象的语法: new RegExp(pattern, attributes); pattern为一 ...
- jQuery文本段落展开和折叠效果
<!DOCTYPE html> <head> <meta http-equiv="Content-Type" content="text/h ...
- MVC原理
C代表Controller,负责用户界面和业务逻辑层的通信控制,一方面解释来自用户界面的输入,识别用户动作(如点击按钮等),调用相应Model中的方法, 另一方面处理来自Model的事件和返回的 ...
- mysql大表myisam的导入
在my.cnf中增大以下参数 myisam_sort_buffer_size = 1024Mtmp_table_size = 256M tmpdir = /home/tmpmyisam_max_sor ...
- completionService
我们现在在Java中使用多线程通常不会直接用Thread对象了,而是会用到java.util.concurrent包下的ExecutorService类来初始化一个线程池供我们使用. 当我们使用Exe ...