某次安装yum时遇到的问题

1 0 556

php扩展mcrypt时,需要先安装几个依赖包,安装是遇到下述错误:

错误描述:

#yum install libmcrypt libmcrypt-devel mcrypt mhash

Setting up Install Process

No package php-mcrypt available.
Error: Nothing to do

我们会看到centos yum从仓库中根本找不到这几个包。

yum  install epel-release  //扩展包更新包

# yum install libmcrypt libmcrypt-devel mcrypt mhash
Loaded plugins: fastestmirror, security
Loading mirror speeds from cached hostfile
Error: Cannot retrieve metalink for repository: epel. Please verify its path and try again

编辑/etc/yum.repos.d/epel.repo,把基础的恢复,镜像的地址注释掉
#baseurl
mirrorlist
改成
baseurl
#mirrorlist

然后安装成功!!

留言

电子邮件地址不会被公开。 必填项已用 * 标注

*

您可以使用这些 HTML 标签和属性: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>