CentOS下yum找不到安装软件的解决方法。
2012-10-08 15:28
555 查看
在centos下用yum安装新软件是,yum有时候会提示找不到相应的软件(当然可以用源码安装来解决问题,不过这个需要手动解决依赖问题,比较麻烦。)。这时可以到https://fedoraproject.org/wiki/EPEL的子栏目:"How can I use these extra packages?", 到一个和系统相关的epel-release。然后用rpm安装epel-release包,再重新yum install就可以了。附上记录,方便以后解决同类问题。
#yum install git
Loaded plugins: fastestmirror
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository addons is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
Loading mirror speeds from cached hostfile
Setting up Install Process
No package git available.
Nothing to do
#su -c 'rpm -Uvh http://mirrors.sohu.com/fedora-epel/5/i386/epel-release-5-4.noarch.rpm'
或者
#sudo rpm -Uvh http://mirrors.sohu.com/fedora-epel/5/i386/epel-release-5-4.noarch.rpm
[root@glfs1 ~]# yum install git
Loaded plugins: fastestmirror
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository addons is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
Loading mirror speeds from cached hostfile
* epel: mirrors.sohu.com
epel | 3.7 kB 00:00
epel/primary_db | 3.8 MB 00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package git.x86_64 0:1.7.4.1-1.el5 set to be updated
--> Processing Dependency: perl-Git = 1.7.4.1-1.el5 for package: git
--> Processing Dependency: perl(Error) for package: git
--> Processing Dependency: perl(Git) for package: git
--> Running transaction check
---> Package perl-Error.noarch 1:0.17010-1.el5 set to be updated
---> Package perl-Git.x86_64 0:1.7.4.1-1.el5 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
..........
..........
顺利完成安装。
#yum install git
Loaded plugins: fastestmirror
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository addons is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
Loading mirror speeds from cached hostfile
Setting up Install Process
No package git available.
Nothing to do
#su -c 'rpm -Uvh http://mirrors.sohu.com/fedora-epel/5/i386/epel-release-5-4.noarch.rpm'
或者
#sudo rpm -Uvh http://mirrors.sohu.com/fedora-epel/5/i386/epel-release-5-4.noarch.rpm
[root@glfs1 ~]# yum install git
Loaded plugins: fastestmirror
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository addons is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
Loading mirror speeds from cached hostfile
* epel: mirrors.sohu.com
epel | 3.7 kB 00:00
epel/primary_db | 3.8 MB 00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package git.x86_64 0:1.7.4.1-1.el5 set to be updated
--> Processing Dependency: perl-Git = 1.7.4.1-1.el5 for package: git
--> Processing Dependency: perl(Error) for package: git
--> Processing Dependency: perl(Git) for package: git
--> Running transaction check
---> Package perl-Error.noarch 1:0.17010-1.el5 set to be updated
---> Package perl-Git.x86_64 0:1.7.4.1-1.el5 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
..........
..........
顺利完成安装。
相关文章推荐
- Centos 64位使用 yum 会安装两个相同软件包的解决方法
- Centos 64位使用 yum 会安装两个相同软件包的解决方法
- Centos 64位使用 yum 会安装两个相同软件包的解决方法
- CentOS使用yum安装软件提示需要KEY的解决方法
- 安装centos mini版,无法联网,用yum安装软件提示 cannot find a valid baseurl for repo:base/7/x86_64 的解决方法
- 解决centos 6.3 yum安装软件时找不到镜像问题
- 在Centos中yum安装和卸载软件的使用方法
- 在Centos中yum安装和卸载软件的使用方法
- centos的软件安装方法rpm和yum
- 在Centos中yum安装和卸载软件的使用方法
- centos中软件的安装方法rpm和yum
- 安装CentOS7文字界面版后,无法联网,用yum安装软件提示 cannot find a valid baseurl for repo:base/7/x86_64 的解决方法
- IBM X3650 M4服务器安装centos找不到硬盘的解决方法
- 在Centos中yum安装和卸载软件的使用方法(转)
- 在Centos中yum安装和卸载软件的使用方法
- centos的软件安装方法rpm和yum
- centos 7 yum install mysql 安装mariadb 后 mysql 无法启动的解决方法
- 在Centos中yum安装和卸载软件的使用方法
- CentOS的软件安装方法rpm和yum
- centos 7 yum install mysql 安装mariadb 后 mysql 无法启动的解决方法