1

I am trying to update CentOS and getting errors as follows. I tried to remove Python and I couldn't.

[root@csc ~]# cat /etc/issue
CentOS release 6.7 (Final)
Kernel \r on an \m

Error updating Cent-OS as follows:

[root@csc ~]# yum update 
Loaded plugins: fastestmirror, refresh-packagekit, security
Setting up Update Process
Loading mirror speeds from cached hostfile
epel/metalink                                                                                                                                   | 4.4 kB     00:00     
 * base: centoso4.centos.org
 * epel: mirror.premi.st
 * extras: centosi3.centos.org
 * rpmforge: mirror1.hs-esslingen.de
 * updates: centosv.centos.org
Dropbox                                                                                                                                         |  951 B     00:00     
base                                                                                                                                            | 3.7 kB     00:00     
extras                                                                                                                                          | 3.4 kB     00:00     
gcsfuse/signature                                                                                                                               |  454 B     00:00     
gcsfuse/signature                                                                                                                               | 1.4 kB     00:00 ... 
google-chrome                                                                                                                                   |  951 B     00:00     
rpmforge                                                                                                                                        | 1.9 kB     00:00     
updates                                                                                                                                         | 3.4 kB     00:00     
Resolving Dependencies
--> Running transaction check
---> Package chkconfig.x86_64 0:1.3.49.3-5.el6 will be updated
---> Package chkconfig.x86_64 0:1.3.49.3-5.el6_7.2 will be an update
---> Package clusterlib.x86_64 0:3.0.12.1-73.el6.1 will be updated
---> Package clusterlib.x86_64 0:3.0.12.1-73.el6_7.2 will be an update
---> Package cman.x86_64 0:3.0.12.1-73.el6.1 will be updated
---> Package cman.x86_64 0:3.0.12.1-73.el6_7.2 will be an update
---> Package dnsmasq.x86_64 0:2.48-14.el6 will be updated
---> Package dnsmasq.x86_64 0:2.48-16.el6_7 will be an update
---> Package firefox.x86_64 0:38.6.0-1.el6.centos.0.1 will be updated
---> Package firefox.x86_64 0:38.6.0-2.el6.centos will be an update
---> Package gcsfuse.x86_64 0:0.15.1-1 will be updated
---> Package gcsfuse.x86_64 0:0.16.0-1 will be an update
---> Package gfs2-utils.x86_64 0:3.0.12.1-73.el6.1 will be updated
---> Package gfs2-utils.x86_64 0:3.0.12.1-73.el6_7.2 will be an update
---> Package google-chrome-stable.x86_64 0:48.0.2564.103-1 will be updated
---> Package google-chrome-stable.x86_64 0:48.0.2564.109-1 will be an update
---> Package httpd.x86_64 0:2.2.15-47.el6.centos.1 will be updated
---> Package httpd.x86_64 0:2.2.15-47.el6.centos.3 will be an update
---> Package httpd-manual.noarch 0:2.2.15-47.el6.centos.1 will be updated
---> Package httpd-manual.noarch 0:2.2.15-47.el6.centos.3 will be an update
---> Package httpd-tools.x86_64 0:2.2.15-47.el6.centos.1 will be updated
---> Package httpd-tools.x86_64 0:2.2.15-47.el6.centos.3 will be an update
---> Package initscripts.x86_64 0:9.03.49-1.el6.centos.3 will be updated
---> Package initscripts.x86_64 0:9.03.49-1.el6.centos.4 will be an update
---> Package kdelibs-common.x86_64 6:4.3.4-23.el6_6 will be updated
---> Package kdelibs-common.x86_64 6:4.3.4-24.el6_7 will be an update
---> Package kernel.x86_64 0:2.6.32-573.18.1.el6 will be installed
---> Package kernel-devel.x86_64 0:2.6.32-573.18.1.el6 will be installed
---> Package kernel-firmware.noarch 0:2.6.32-573.12.1.el6 will be updated
---> Package kernel-firmware.noarch 0:2.6.32-573.18.1.el6 will be an update
---> Package kernel-headers.x86_64 0:2.6.32-573.12.1.el6 will be updated
---> Package kernel-headers.x86_64 0:2.6.32-573.18.1.el6 will be an update
---> Package kexec-tools.x86_64 0:2.0.0-286.el6 will be updated
---> Package kexec-tools.x86_64 0:2.0.0-286.el6_7.1 will be an update
---> Package libipa_hbac.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package libipa_hbac.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package libipa_hbac-python.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package libipa_hbac-python.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package librdmacm.x86_64 0:1.0.19.1-1.el6 will be updated
---> Package librdmacm.x86_64 0:1.0.19.1-1.1.el6_7 will be an update
---> Package libsss_idmap.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package libsss_idmap.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package mod_ssl.x86_64 1:2.2.15-47.el6.centos.1 will be updated
---> Package mod_ssl.x86_64 1:2.2.15-47.el6.centos.3 will be an update
---> Package ntsysv.x86_64 0:1.3.49.3-5.el6 will be updated
---> Package ntsysv.x86_64 0:1.3.49.3-5.el6_7.2 will be an update
---> Package perf.x86_64 0:2.6.32-573.12.1.el6 will be updated
---> Package perf.x86_64 0:2.6.32-573.18.1.el6 will be an update
---> Package php.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package php-cli.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php-cli.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package php-common.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php-common.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package php-mbstring.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php-mbstring.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package php-mysql.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php-mysql.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package php-pdo.x86_64 0:5.3.3-46.el6_6 will be updated
---> Package php-pdo.x86_64 0:5.3.3-46.el6_7.1 will be an update
---> Package poppler.x86_64 0:0.12.4-4.el6_6.1 will be updated
---> Package poppler.x86_64 0:0.12.4-5.el6_7.1 will be an update
---> Package poppler-glib.x86_64 0:0.12.4-4.el6_6.1 will be updated
---> Package poppler-glib.x86_64 0:0.12.4-5.el6_7.1 will be an update
---> Package poppler-utils.x86_64 0:0.12.4-4.el6_6.1 will be updated
---> Package poppler-utils.x86_64 0:0.12.4-5.el6_7.1 will be an update
---> Package python-crypto.x86_64 0:2.0.1-22.el6 will be updated
---> Package python-crypto.x86_64 0:2.6.1-1.el5.rf will be an update
--> Processing Dependency: python(abi) = 2.4 for package: python-crypto-2.6.1-1.el5.rf.x86_64
---> Package python-markupsafe.x86_64 0:0.9.2-4.el6 will be updated
---> Package python-markupsafe.x86_64 0:0.11-1.el5.rf will be an update
--> Processing Dependency: python(abi) = 2.4 for package: python-markupsafe-0.11-1.el5.rf.x86_64
---> Package python-netaddr.noarch 0:0.7.5-4.el6 will be updated
---> Package python-netaddr.noarch 0:0.7.10-1.el5.rf will be an update
--> Processing Dependency: python(abi) = 2.4 for package: python-netaddr-0.7.10-1.el5.rf.noarch
---> Package python-paramiko.noarch 0:1.7.5-2.1.el6 will be updated
---> Package python-paramiko.noarch 0:1.7.6-1.el5.rf will be an update
--> Processing Dependency: python(abi) = 2.4 for package: python-paramiko-1.7.6-1.el5.rf.noarch
---> Package python-pygments.noarch 0:1.1.1-1.el6 will be updated
---> Package python-pygments.noarch 0:1.4-1.el5.rf will be an update
--> Processing Dependency: python(abi) = 2.4 for package: python-pygments-1.4-1.el5.rf.noarch
---> Package python-sssdconfig.noarch 0:1.12.4-47.el6_7.4 will be updated
---> Package python-sssdconfig.noarch 0:1.12.4-47.el6_7.7 will be an update
---> Package sg3_utils.x86_64 0:1.28-8.el6 will be updated
---> Package sg3_utils.x86_64 0:1.28-9.el6_7 will be an update
---> Package sg3_utils-libs.x86_64 0:1.28-8.el6 will be updated
---> Package sg3_utils-libs.x86_64 0:1.28-9.el6_7 will be an update
---> Package sos.noarch 0:3.2-28.el6.centos will be updated
---> Package sos.noarch 0:3.2-28.el6.centos.2 will be an update
---> Package sssd.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-ad.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-ad.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-client.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-client.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-common.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-common.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-common-pac.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-common-pac.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-ipa.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-ipa.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-krb5.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-krb5.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-krb5-common.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-krb5-common.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-ldap.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-ldap.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package sssd-proxy.x86_64 0:1.12.4-47.el6_7.4 will be updated
---> Package sssd-proxy.x86_64 0:1.12.4-47.el6_7.7 will be an update
---> Package tzdata.noarch 0:2015g-2.el6 will be updated
---> Package tzdata.noarch 0:2016a-2.el6 will be an update
---> Package tzdata-java.noarch 0:2015g-2.el6 will be updated
---> Package tzdata-java.noarch 0:2016a-2.el6 will be an update
--> Finished Dependency Resolution
Error: Package: python-crypto-2.6.1-1.el5.rf.x86_64 (rpmforge)
           Requires: python(abi) = 2.4
           Installed: python-2.6.6-64.el6.x86_64 (@base)
               python(abi) = 2.6
Error: Package: python-netaddr-0.7.10-1.el5.rf.noarch (rpmforge)
           Requires: python(abi) = 2.4
           Installed: python-2.6.6-64.el6.x86_64 (@base)
               python(abi) = 2.6
Error: Package: python-paramiko-1.7.6-1.el5.rf.noarch (rpmforge)
           Requires: python(abi) = 2.4
           Installed: python-2.6.6-64.el6.x86_64 (@base)
               python(abi) = 2.6
Error: Package: python-pygments-1.4-1.el5.rf.noarch (rpmforge)
           Requires: python(abi) = 2.4
           Installed: python-2.6.6-64.el6.x86_64 (@base)
               python(abi) = 2.6
Error: Package: python-markupsafe-0.11-1.el5.rf.x86_64 (rpmforge)
           Requires: python(abi) = 2.4
           Installed: python-2.6.6-64.el6.x86_64 (@base)
               python(abi) = 2.6
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
  • 1
    Have you tried "You could try using --skip-broken to work around the problem" as the message suggests?" – Rui F Ribeiro Feb 15 '16 at 10:17
2

CentOS 6 ships with Python 2.6.6, but you've apparently either installed Python 2.4 or packages built against Python 2.4 through RPMForge by using its CentOS 5 RPMs, as evidenced by the el5 in some of the file names given.

You need to remove those packages and install the correct EL6 versions.

Generally, mixing two different versions of Python on a Red Hat type Linux is a very bad idea because so much of the core OS is based on Python. You're sure to get conflicts like this.

There are safe ways to set up an isolated installation of a second version of Python, but that's a separate question.

  • How can I remove only el5 Python packages ? When I am going to remove Python the operation getting lock by yum. I am advising that how to keep only using one EL version. @Warren Young – Chaminda Bandara Feb 15 '16 at 11:56
  • @ChamindaBandara: Just look for el5 in the file names in the output above. You may be able to remove the packages one-by-one (e.g. rpm -e python-netaddr-0.7.10-1.el5.rf.noarch) or you may have to list a whole bunch of them on a single rpm -e command line in order to give RPM a shot at unwinding all of the dependencies. You might also want to say rpm -qa | grep el5 to get a list of all EL5 packages. – Warren Young Feb 15 '16 at 11:59
  • @WarrenYoung Removing the python packages will not be possible without breaking the base system, disabling the rpmforge repo like Thomas Dickey suggested would be the right way to go. – doktor5000 Feb 15 '16 at 20:51
  • @doktor5000: The few el5 packages don't look like core Python packages to me, just peripheral libraries. They probably need to be replaced by el6 versions rather than removed, to satisfy dependencies. As for the RPMForge repo, OP appears to have installed the el5 repo rather than the el6 one; so rather than disable it, it should be removed or replaced. – Warren Young Feb 16 '16 at 8:50
  • I changed my all el5 to el6 and done update successfully. Thanks @WarrenYoung – Chaminda Bandara Feb 16 '16 at 10:48
1

The problem would be aggravated by blindly following the advice to skip broken packages. The problem is from mixed repositories. To start repairing the problem, disable the rpmforge repository, and if updating still fails, try updating parts of the list to reduce the number of conflicting packages.

Even when you have conflicts, yum update still accepts optional package names, e.g.,

yum update chkconfig.x86_64

As @warren-young notes, to finish repairing the system, you will have to remove the packages which conflict with CentOS. Doing this is usually simpler if only a few packages are listed in the yum update.

  • chkconfig.x86_64 updated successfully but again getting same error when running command yum update. – Chaminda Bandara Feb 15 '16 at 11:51
  • You can probably update anything that does not depend upon one of the conflicting (python) packages. To resolve the problem, you will have to update python from CentOS -- without rpmforge. – Thomas Dickey Feb 15 '16 at 12:05
0

To be honest, at this point the easiest fix is going to be to reinstall the OS from scratch. I'm honestly surprised that yum runs at all. Stay away from rpmforge, that is not a safe repository. CentOS believes that the project is abandoned. If you need newer versions of Python on RHEL/CentOS, you should consider the parallel packages from the IUS project.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.