在RHEL 6.5上使用yum更新/安装软件的操作方法
1)首先,需要移除系统注册相关软件
∘ 查看相关软件:rpm -qa | grep subscription-manager
∘ 移除相关软件:yum remove subscription-manager
2)为了使用centos提供的yum源,需要删除系统自带的yum
∘ rpm -aq | grep yum | xargs rpm -e --nodeps
3)从centos上下载安装yum
∘ wget http://vault.centos.org/6.0/os/x86_64/packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm
∘ wget http://vault.centos.org/6.0/os/x86_64/packages/yum-metadata-parser-1.1.2-14.1.el6.x86_64.rpm
∘ wget http://vault.centos.org/6.0/os/x86_64/packages/yum-3.2.27-14.el6.centos.noarch.rpm
∘ wget http://vault.centos.org/6.0/os/x86_64/packages/yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm
∘ rpm -ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm
∘ rpm -ivh yum-metadata-parser-1.1.2-14.1.el6.x86_64.rpm
∘ rpm -ivh yum-3.2.27-14.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm
∘ 注意: yum-3.2.27-14.el6.centos.noarch.rpm和yum-plugin-fastestmirror-1.1.26-11.el6.noarch.rpm相互依赖,需要同时安装
4) 使用centos的yum源更新
∘ cd /etc/yum.repos.d/
∘ wget http://mirrors.163.com/.help/centos6-base-163.repo
∘ 编辑centos6-base-163.repo,将$releasever字段全部替换为6
∘ yum makecache
∘ yum vim* ===> 仅用作测试,观察yum是否可用
5)示例:安装virtualbox-4.3
∘ 从virtualbox官网下载virtualbox-4.3-4.3.30_101610_el6-1.x86_64.rpm和oracle_vm_virtualbox_extension_pack-4.3.30-101610.vbox-extpack
∘ rpm -ivh virtualbox-4.3-4.3.30_101610_el6-1.x86_64.rpm,发现依赖libsdl
∘ yum install sdl
∘ rpm -ivh virtualbox-4.3-4.3.30_101610_el6-1.x86_64.rpm,安装成功
∘ 双击运行oracle_vm_virtualbox_extension_pack-4.3.30-101610.vbox-extpack,安装扩展包
∘ 打开virtualbox,开始自己的工作
以上就是小编为大家带来的在rhel 6.5上使用yum更新/安装软件的操作方法全部内容了,希望大家多多支持~