1. 无法找到rpm包
当用yum进行install时出现下述错误
- [root@localhost repodata]# yum install php
- Loading "rhnplugin" plugin
- Loading "installonlyn" plugin
- This system is not registered with RHN.
- RHN support will be disabled.
- Setting up Install Process
- Setting up repositories
- Reading repository metadata in from local files
- Parsing package install arguments
- Resolving Dependencies
- --> Populating transaction set with selected packages. Please wait.
- ---> Downloading header for php to pack into transaction set.
- media://1170972069.396645%232/php-5.1.6-5.el5.i386.rpm: [Errno 4] IOError:
- Trying other mirror.
- Error: failed to retrieve php-5.1.6-5.el5.i386.rpm from dvd
- error was [Errno 4] IOError: <urlopen error unknown url type: media>
YUM配置如下
- echo /etc/yum.repos.d/dvd.repo
- [dvd]
- name=install dvd
- baseurl=file:///mnt/cdrom/Server
- enabled=1
- gpgcheck=0
错误原因:
2.X版本的yum是没有问题的。
3.X版本的yum就有问题了。
编辑/usr/lib/python2.4/site-packages/yum/yumRepo.py文件。
找到remote = url + '/' + relative
改成下面这样就可以了。
- #remote = url + '/' + relative #这行是原来的,
- remote = '/mnt/DVD/' + relative
2. “Public key for ****.rpm is not installed”
导入rpm的签名信息
[root@bbbb ccc]#
rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release重新安装即可。
阅读(2996) | 评论(0) | 转发(0) |