redhat5.4-yum-安装
最近正在研究nfs+heartbeat+drbd简历高可用nfs服务器,其中我yum安装heartbeat的时候提示我yum安装错误,后来改为本地yum作为源。但是redhat5.4光盘镜像没有自带heartbeat于是想借用centos的网络yum源。
查看本地是否安装yum包
rpm -qa | grep yum
如果已经安装卸载
rpm -qa | grep yum | xargs rpm -e --nodeps
下载一下安装包
wget -b http://centos.ustc.edu.cn/centos/5/os/i386/CentOS/yum-3.2.22-39.el5.centos.noarch.rpm
wget -b http://centos.ustc.edu.cn/centos/5/os/i386/CentOS/yum-metadata-parser-1.1.2-3.el5.centos.i386.rpm
wget -b http://centos.ustc.edu.cn/centos/5/os/i386/CentOS/yum-updatesd-0.9-2.el5.noarch.rpm
wget -b http://centos.ustc.edu.cn/centos/5/os/i386/CentOS/yum-fastestmirror-1.1.16-21.el5.centos.noarch.rpm
安装 rpm -ivh yum-*
3.cd /etc/yum.repos.d/
wget -b http://docs.linuxtone.org/soft/lemp/CentOS-Base.repo
4. 导入KEY文件,注意大小写
rpm --import http://centos.ustc.edu.cn/centos/RPM-GPG-KEY-CentOS-5
5.测试 yum