1. 问题描述由于之前我在执行yun update命令时ctrl + c将其中断了, 现在重新执行yum update时出现如下错误: # yum update Loaded plugins: security Setting up Update Process Resolving Dependencies There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them. --> Running transaction check ---> Package git.x86_64 0:1.7.1-3.el6_4.1 will be updated ---> Package git.x86_64 0:1.7.1-4.el6_7.1 will be an update ---> Package glibc-headers.x86_64 0:2.12-1.166.el6_7.3 will be updated --> Processing Dependency: glibc-headers = 2.12-1.166.el6_7.3 for package: glibc-devel-2.12-1.166.el6_7.3.x86_64 ---> Package glibc-headers.x86_64 0:2.12-1.166.el6_7.7 will be an update ---> Package gnutls.x86_64 0:2.8.5-18.el6 will be updated ---> Package gnutls.x86_64 0:2.8.5-19.el6_7 will be an update ---> Package grub.x86_64 1:0.97-94.el6 will be updated ---> Package grub.x86_64 1:0.97-94.el6_7.1 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 kernel.x86_64 0:2.6.32-573.22.1.el6 will be installed ---> Package kernel-devel.x86_64 0:2.6.32-573.22.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 updated ---> Package kernel-firmware.noarch 0:2.6.32-573.22.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 updated ---> Package kernel-headers.x86_64 0:2.6.32-573.22.1.el6 will be an update ---> Package krb5-devel.x86_64 0:1.10.3-42.el6 will be updated ---> Package krb5-devel.x86_64 0:1.10.3-42z1.el6_7 will be an update ---> Package krb5-libs.x86_64 0:1.10.3-42.el6 will be updated ---> Package krb5-libs.x86_64 0:1.10.3-42z1.el6_7 will be an update ---> Package nscd.x86_64 0:2.12-1.166.el6_7.3 will be updated ---> Package nscd.x86_64 0:2.12-1.166.el6_7.7 will be an update ---> Package nspr.x86_64 0:4.10.8-2.el6_7 will be updated ---> Package nspr.x86_64 0:4.11.0-0.1.el6_7 will be an update ---> Package nss.x86_64 0:3.19.1-5.el6_7 will be updated ---> Package nss.x86_64 0:3.19.1-8.el6_7 will be updated ---> Package nss.x86_64 0:3.21.0-0.3.el6_7 will be an update ---> Package nss-sysinit.x86_64 0:3.19.1-5.el6_7 will be updated ---> Package nss-sysinit.x86_64 0:3.19.1-8.el6_7 will be updated ---> Package nss-sysinit.x86_64 0:3.21.0-0.3.el6_7 will be an update ---> Package nss-tools.x86_64 0:3.19.1-5.el6_7 will be updated ---> Package nss-tools.x86_64 0:3.19.1-8.el6_7 will be updated ---> Package nss-tools.x86_64 0:3.21.0-0.3.el6_7 will be an update ---> Package nss-util.x86_64 0:3.19.1-2.el6_7 will be updated ---> Package nss-util.x86_64 0:3.19.1-5.el6_7 will be updated ---> Package nss-util.x86_64 0:3.21.0-0.3.el6_7 will be an update ---> Package ntpdate.x86_64 0:4.2.6p5-5.el6.centos.2 will be updated --> Processing Dependency: ntpdate = 4.2.6p5-5.el6.centos.2 for package: ntp-4.2.6p5-5.el6.centos.2.x86_64 ---> Package ntpdate.x86_64 0:4.2.6p5-5.el6.centos.4 will be an update ---> Package openssh-server.x86_64 0:5.3p1-112.el6_7 will be updated ---> Package openssh-server.x86_64 0:5.3p1-114.el6_7 will be an update ---> Package perl-Git.noarch 0:1.7.1-3.el6_4.1 will be updated ---> Package perl-Git.noarch 0:1.7.1-4.el6_7.1 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-10.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 tzdata.noarch 0:2015g-2.el6 will be updated ---> Package tzdata.noarch 0:2016b-1.el6 will be updated ---> Package tzdata.noarch 0:2016c-1.el6 will be an update --> Finished Dependency Resolution Error: Package: ntp-4.2.6p5-5.el6.centos.2.x86_64 (@updates) Requires: ntpdate = 4.2.6p5-5.el6.centos.2 Removing: ntpdate-4.2.6p5-5.el6.centos.2.x86_64 (@updates) ntpdate = 4.2.6p5-5.el6.centos.2 Updated By: ntpdate-4.2.6p5-5.el6.centos.4.x86_64 (updates) ntpdate = 4.2.6p5-5.el6.centos.4 Available: ntpdate-4.2.6p5-5.el6.centos.x86_64 (base) ntpdate = 4.2.6p5-5.el6.centos Error: Package: glibc-devel-2.12-1.166.el6_7.3.x86_64 (@updates) Requires: glibc-headers = 2.12-1.166.el6_7.3 Removing: glibc-headers-2.12-1.166.el6_7.3.x86_64 (@updates) glibc-headers = 2.12-1.166.el6_7.3 Updated By: glibc-headers-2.12-1.166.el6_7.7.x86_64 (updates) glibc-headers = 2.12-1.166.el6_7.7 Available: glibc-headers-2.12-1.166.el6.x86_64 (base) glibc-headers = 2.12-1.166.el6 Available: glibc-headers-2.12-1.166.el6_7.1.x86_64 (updates) glibc-headers = 2.12-1.166.el6_7.1 You could try using --skip-broken to work around the problem ** Found 25 pre-existing rpmdb problem(s), 'yum check' output follows: 32:bind-libs-9.8.2-0.37.rc1.el6_7.7.x86_64 is a duplicate with 32:bind-libs-9.8.2-0.37.rc1.el6_7.5.x86_64 32:bind-utils-9.8.2-0.37.rc1.el6_7.7.x86_64 is a duplicate with 32:bind-utils-9.8.2-0.37.rc1.el6_7.5.x86_64 ca-certificates-2015.2.6-65.0.1.el6_7.noarch is a duplicate with ca-certificates-2015.2.4-65.0.1.el6_6.noarch chkconfig-1.3.49.3-5.el6_7.2.x86_64 is a duplicate with chkconfig-1.3.49.3-5.el6.x86_64 fio-2.0.13-2.el6.x86_64 is a duplicate with fio-2.0.13-1.el6.x86_64 glibc-2.12-1.166.el6_7.7.x86_64 is a duplicate with glibc-2.12-1.166.el6_7.3.x86_64 glibc-common-2.12-1.166.el6_7.7.x86_64 is a duplicate with glibc-common-2.12-1.166.el6_7.3.x86_64 glibc-devel-2.12-1.166.el6_7.7.x86_64 is a duplicate with glibc-devel-2.12-1.166.el6_7.3.x86_64 glibc-devel-2.12-1.166.el6_7.7.x86_64 has missing requires of glibc-headers = ('0', '2.12', '1.166.el6_7.7') kernel-firmware-2.6.32-573.18.1.el6.noarch is a duplicate with kernel-firmware-2.6.32-573.12.1.el6.noarch kernel-headers-2.6.32-573.18.1.el6.x86_64 is a duplicate with kernel-headers-2.6.32-573.12.1.el6.x86_64 kexec-tools-2.0.0-286.el6_7.2.x86_64 is a duplicate with kexec-tools-2.0.0-286.el6.x86_64 libssh2-1.4.2-2.el6_7.1.x86_64 is a duplicate with libssh2-1.4.2-1.el6_6.1.x86_64 nss-3.19.1-8.el6_7.x86_64 is a duplicate with nss-3.19.1-5.el6_7.x86_64 nss-sysinit-3.19.1-8.el6_7.x86_64 is a duplicate with nss-sysinit-3.19.1-5.el6_7.x86_64 nss-tools-3.19.1-8.el6_7.x86_64 is a duplicate with nss-tools-3.19.1-5.el6_7.x86_64 nss-util-3.19.1-5.el6_7.x86_64 is a duplicate with nss-util-3.19.1-2.el6_7.x86_64 ntp-4.2.6p5-5.el6.centos.4.x86_64 is a duplicate with ntp-4.2.6p5-5.el6.centos.2.x86_64 ntp-4.2.6p5-5.el6.centos.4.x86_64 has missing requires of ntpdate = ('0', '4.2.6p5', '5.el6.centos.4') ntsysv-1.3.49.3-5.el6_7.2.x86_64 is a duplicate with ntsysv-1.3.49.3-5.el6.x86_64 openssh-5.3p1-114.el6_7.x86_64 is a duplicate with openssh-5.3p1-112.el6_7.x86_64 openssh-clients-5.3p1-114.el6_7.x86_64 is a duplicate with openssh-clients-5.3p1-112.el6_7.x86_64 openssl-1.0.1e-42.el6_7.4.x86_64 is a duplicate with openssl-1.0.1e-42.el6_7.2.x86_64 openssl-devel-1.0.1e-42.el6_7.4.x86_64 is a duplicate with openssl-devel-1.0.1e-42.el6_7.2.x86_64 tzdata-2016b-1.el6.noarch is a duplicate with tzdata-2015g-2.el6.noarch # 2. 解决方法在stackovreflow网站找到了答案 列出重复的包 # package-cleanup --dupes 删除重复的包 # package-cleanup --cleandupes 执行完上面两个命令, 再yum update成功解决问题 (责任编辑:IT) |