CentOS8: dnf update fails, any suggestion

Good morning,

on a standard CERN installed desktop, CentOS8, I get failure with dnf update.
Has somebody a suggestion?

Thank you in advance,
Eric

[root@x ~]# cat /etc/redhat-release
CentOS Linux release 8.2.2004 (Core)
[root@x ~]# dnf clean all
61 files removed
[root@x ~]# dnf update
CentOS-8 - CERN                                                                                                                                  5.6 MB/s |  45 kB     00:00
CentOS-8 - AppStream                                                                                                                             5.4 MB/s | 6.3 MB     00:01
CentOS-8 - Base                                                                                                                                   51 MB/s | 2.3 MB     00:00
CentOS-8 - Extras                                                                                                                                 69 kB/s | 8.6 kB     00:00
CentOS-8 - PowerTools                                                                                                                             11 MB/s | 2.0 MB     00:00
CentOS-8 - fasttrack                                                                                                                              11 kB/s | 257  B     00:00
Extra Packages for Enterprise Linux Modular 8 - x86_64                                                                                            31 MB/s | 527 kB     00:00
Extra Packages for Enterprise Linux 8 - x86_64                                                                                                    12 MB/s | 8.7 MB     00:00
locmap [stable]                                                                                                                                  2.3 MB/s |  66 kB     00:00
openafs-8                                                                                                                                        390 kB/s |  89 kB     00:00
Error:
 Problem 1: package centos-linux-release-666:8.3-1.2011.el8.cern.noarch requires centos-repos(8), but none of the providers can be installed
  - package centos-linux-repos-666:8-2.0.2.el8.cern.noarch requires centos-gpg-keys = 666:8-2.0.2.el8.cern, but none of the providers can be installed
  - package centos-linux-repos-666:8-2.el8.cern.noarch requires centos-gpg-keys = 666:8-2.el8.cern, but none of the providers can be installed
  - package centos-linux-repos-8-2.el8.noarch requires centos-gpg-keys = 1:8-2.el8, but none of the providers can be installed
  - package centos-linux-release-666:8.3-1.2011.el8.cern.noarch obsoletes centos-repos < 666:8.2-3 provided by centos-repos-666:8.2-2.2004.0.2.2.el8.cern.x86_64
  - cannot install both centos-gpg-keys-666:8-2.0.2.el8.cern.noarch and centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
  - cannot install both centos-gpg-keys-666:8-2.el8.cern.noarch and centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
  - cannot install both centos-gpg-keys-1:8-2.el8.noarch and centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
  - cannot install the best update candidate for package centos-release-666:8.2-2.2004.0.2.2.el8.cern.x86_64
  - problem with installed package centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
 Problem 2: both package centos-linux-release-666:8.3-1.2011.el8.cern.noarch and centos-linux-repos-666:8-2.el8.cern.noarch obsolete centos-repos < 666:8.2-3
  - cannot install the best update candidate for package centos-repos-666:8.2-2.2004.0.2.2.el8.cern.x86_64
  - package centos-linux-repos-666:8-2.0.2.el8.cern.noarch requires centos-gpg-keys = 666:8-2.0.2.el8.cern, but none of the providers can be installed
  - package centos-linux-repos-666:8-2.el8.cern.noarch requires centos-gpg-keys = 666:8-2.el8.cern, but none of the providers can be installed
  - cannot install both centos-gpg-keys-666:8-2.0.2.el8.cern.noarch and centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
  - cannot install both centos-gpg-keys-666:8-2.el8.cern.noarch and centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
  - cannot install the best update candidate for package centos-gpg-keys-666:8.2-2.2004.0.2.2.el8.cern.noarch
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

Hello,
This is due to version numbering changes of the centos-release package with the 8.3 upgrade.
There are two work arounds if you face this issue.

  1. use “dnf distro-sync”
    or
  2. update centos-release first with “dnf install centos-release”, and then run a full system upgrade with “dnf upgrade”.

Cheers,

Ben

1 Like

Thank you a lot, it works perfectly
Eric