redhat7.2修改yum源
redhat企业版7.2安装软件,需要操作系统注册才行。
但是redhat的软件跟centos软件的源都是一样的。所以可以用centos软件的源替换。
下面介绍redhat企业版7.2修改配置yum源的方法。
redhat7.2配置yum源_百度经验
http://jingyan.baidu.com/article/6dad50751f4912a123e36e38.html
最后使用下述命令验证一下:
yum install redhat-lsb -y
lsb_release -a
另外,介绍一个yum安装技巧。
yum list根据package名称关键词,进行搜索确认
因为yum后面是package的名称,跟linux命令名称是不一样的。
为了安装合适的package,可以使用下述命令查找确认。
yum list | grep lsb
再说一个相关技巧
yum install去掉下载确认的步骤
一般yum install xxxxxxxx
安装的时候,会提示软件占用空间大小。每次都得输入y确认。
如果不想确认,那就改为
yum install xxxxxxxx -y
yum provide 命令(特别推荐)
适合.so文件缺失或者程序名称
举2个例子:
[qilei@localhost 2.5.2]$ cdnshelp
Cadence Help v02.10-p001
Copyright (c) 2006-2013 Cadence Design Systems, Inc. All rights reserved
Launching gui.../home/qilei/cadence/INCISIV14/tools.lnx86/cdnshelp/bin/cdnshelp.exe /home/qilei/cadence/INCISIV14/doc/xmlreg/library.lbr
/home/qilei/cadence/INCISIV14/tools.lnx86/cdnshelp/bin/32bit/cdnshelp.exe: error while loading shared libraries: libz.so.1: cannot open shared object file: No such file or directory
[qilei@localhost 2.5.2]$ su
Password:
[root@localhost 2.5.2]# yum provides libz.so.1
Loaded plugins: fastestmirror, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Loading mirror speeds from cached hostfile
zlib-1.2.7-17.el7.i686 : The compression and decompression library
Repo : base
Matched from:
Provides : libz.so.1
[root@localhost 2.5.2]# yum install zlib-1.2.7-17.el7.i686 -y
[root@localhost 2.5.2]# yum provides emacs
Loaded plugins: fastestmirror, product-id, search-disabled-repos, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Loading mirror speeds from cached hostfile
1:emacs-24.3-18.el7.x86_64 : GNU Emacs text editor
Repo : base
总结
有了上述yum源和yum操作技巧,redhat系统下安装软件的方法就简单多了。
参考文档:
注意:
1. redhat6.3配置yum源,使之来自centos;
2. redhat6.3除了下述操作外,还要修改centos源的版本号为最新。否则会提示网址请求无应答的错误。
3. 下载http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6;放在目录:/etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6
4. 命令执行:rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-6
rehat 安装软件源”Unable to read consumer identity”解决:使用非注册的软件源 - 河西无名式 - 博客频道 - CSDN.NET
http://blog.csdn.net/trochiluses/article/details/17027045