![`sudo yum -y update` 出错](https://linux22.com/image/1521829/%60sudo%20yum%20-y%20update%60%20%E5%87%BA%E9%94%99.png)
更新我的亚马逊 EC2 实例时出现以下错误。
Transaction check error:
file /usr/bin/pyrsa-decrypt conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-decrypt-bigfile conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-encrypt conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-encrypt-bigfile conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-keygen conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-priv2pub conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-sign conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
file /usr/bin/pyrsa-verify conflicts between attempted installs of python2-rsa-3.4.1-1.el6.noarch and python26-rsa-3.4.1-1.8.amzn1.noarch
我试过
sudo yum remove python26-rsa-3.4.1-1.8.amzn1.noarch
但错误并没有消失。
我的Linux机器信息:
$cat /etc/issue
Amazon Linux AMI release 2014.09
Kernel \r on an \m
答案1
我自己修复了它。更改/etc/yum.repos.d/epel.repo
如下
[epel]
name=Extra Packages for Enterprise Linux 6 - $basearch
enabled=1
# ------^------- set this to zero
failovermethod=priority
gpgcheck=1
gpgkey=http://dl.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6