Centos – Updating epel repo to 6 – epel-release-6-x.noarch conflicts with file from package epel-release-5-x.noarch

centosepelrpm

I am following an epel repo upgrade guide from Centos 5 to Centos 6 here (http://www.thegeekstuff.com/2012/06/enable-epel-repository/ and http://www.linuxquestions.org/questions/linux-server-73/epel-issues-centos-6-a-4175424243/), and getting a weird error. How can I solve this?

     rpm -ivh epel-release-6-8.noarch.rpm
Preparing...                ########################################### [100%]
        file /etc/yum.repos.d/epel-testing.repo from install of epel-release-6-8.noarch conflicts with file from package epel-release-5-4.noarch
        file /etc/yum.repos.d/epel.repo from install of epel-release-6-8.noarch conflicts with file from package epel-release-5-4.noarch

Best Answer

As long as you're sure you're running C6, try rpm -Uvh epel-release-6-8.noarch.rpm. That will upgrade the package (ie, replace older with newer) instead of trying to install the two alongside each other.