dnf upgrade and dnf update fails

Issues related to applications and software problems and general support
Exlord
Posts: 2
Joined: 2020/01/18 06:09:43
Location: Tabriz, Iran
Contact:

dnf upgrade and dnf update fails

Post by Exlord » 2020/01/18 06:27:22

Hi, I upgraded my centos7 to 8 recently ...

Now when I try

Code: Select all

dnf upgrade --best --allowerasing
dnf update --best --allowerasing
I am getting this error :

Code: Select all


Running transaction check
Error: transaction check vs depsolve:
(gcc >= 8 with gcc < 9) is needed by annobin-8.78-1.el8.x86_64
rpmlib(RichDependencies) <= 4.12.0-1 is needed by annobin-8.78-1.el8.x86_64
(annobin if gcc) is needed by redhat-rpm-config-120-1.el8.noarch
rpmlib(RichDependencies) <= 4.12.0-1 is needed by redhat-rpm-config-120-1.el8.noarch
To diagnose the problem, try running: 'rpm -Va --nofiles --nodigest'.
You probably have corrupted RPMDB, running 'rpm --rebuilddb' might fix the issue.
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.

[root@vm6263622508 ~]# gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/8/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-redhat-linux
Configured with: ../configure --enable-bootstrap --enable-languages=c,c++,fortran,lto --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-shared --enable-threads=posix --enable-checking=release --enable-multilib --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-gcc-major-version-only --with-linker-hash-style=gnu --enable-plugin --enable-initfini-array --with-isl --disable-libmpx --enable-offload-targets=nvptx-none --without-cuda-driver --enable-gnu-indirect-function --enable-cet --with-tune=generic --with-arch_32=x86-64 --build=x86_64-redhat-linux
Thread model: posix
gcc version 8.3.1 20190507 (Red Hat 8.3.1-4) (GCC)

Code: Select all

rpm --rebuilddb
dnf clean packages
rpm -Va --nofiles --nodigest
makes no changes

Code: Select all

dnf update
dnf upgrade
results in this error :

Code: Select all

Running transaction check
Transaction check succeeded.
Running transaction test
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Error: Transaction check error:
  file /usr/lib64/libgdbm_compat.so.4.0.0 from install of gdbm-libs-1:1.18-1.el8.x86_64 conflicts with file from package gdbm-1.10-8.el7.x86_64

Error Summary
-------------

Code: Select all

dnf remove gdbm

Error: Problem: The operation would result in removing the following protected packages: dnf

Code: Select all

dnf swap gdbm gdbm-libs

Error: Problem: package python-libs-2.7.5-86.el7.x86_64 requires libgdbm.so.4()(64bit), but none of the providers can be installed - conflicting requests - problem with installed package python-libs-2.7.5-86.el7.x86_64

User avatar
jlehtone
Posts: 4523
Joined: 2007/12/11 08:17:33
Location: Finland

Re: dnf upgrade and dnf update fails

Post by jlehtone » 2020/01/18 19:14:51

Exlord wrote:
2020/01/18 06:27:22
Hi, I upgraded my centos7 to 8 recently ...
There is no 7->8 upgrade. One has to install fresh 8.

Sounds like you have broken your 7 system.

Exlord
Posts: 2
Joined: 2020/01/18 06:09:43
Location: Tabriz, Iran
Contact:

Re: dnf upgrade and dnf update fails

Post by Exlord » 2020/01/19 01:46:51

jlehtone wrote:
2020/01/18 19:14:51

There is no 7->8 upgrade. One has to install fresh 8.

Sounds like you have broken your 7 system.
So what are these then ?
https://www.google.com/search?q=centos+7+to+8+upgrade
https://www.tecmint.com/upgrade-centos-7-to-centos-8/
https://www.howtoforge.com/how-to-upgra ... core-to-8/

User avatar
toracat
Site Admin
Posts: 7518
Joined: 2006/09/03 16:37:24
Location: California, US
Contact:

Re: dnf upgrade and dnf update fails

Post by toracat » 2020/01/19 06:15:57

None of them are supported by CentOS. There is no officially supported pathway to upgrade CentOS 7 to 8.
CentOS Forum FAQ

User avatar
jlehtone
Posts: 4523
Joined: 2007/12/11 08:17:33
Location: Finland

Re: dnf upgrade and dnf update fails

Post by jlehtone » 2020/01/19 09:59:14

If their ideas got you into tight spot, then you should ask them for assistance. (Although, they might not be able to help any better.)


A "system" has essentially three parts:
  • Installed packages. These change on every version. Fresh install (but rather than overwrite, one can install to different partition/volume/disk)
  • User data. Does not change when OS changes. Best kept separate
  • Configuration. If you have logical config saved outside the system, then you can apply it appropriately into fresh installs

jringoot
Posts: 5
Joined: 2010/03/01 09:24:41

Re: dnf upgrade and dnf update fails

Post by jringoot » 2020/10/20 14:23:35

This is quite absurd

Upgrade from rhel7 to rhel8 is supported

https://access.redhat.com/documentation ... el_8/index
https://github.com/oamg/leapp

This is probably in essence just a (long) script that performs the upgrade tasks in the correct order.

And Centos has a stream distro that should switch automagically from centos 8 to centos 9?
https://wiki.centos.org/FAQ/CentOSStream

Compare this to the smooth process for Debian, which I did numerously from 8 to 9 and from 9 to 10
https://wiki.debian.org/DebianUpgrade

Yeah, I am ranting


Image

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: dnf upgrade and dnf update fails

Post by TrevorH » 2020/10/20 14:37:56

And you pay Red Hat for the privilege of being able to use their upgrade tool...
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

BillHudacek
Posts: 5
Joined: 2006/12/04 04:17:25

Re: dnf upgrade and dnf update fails

Post by BillHudacek » 2020/12/08 15:58:08

I just stumbled on this thread myself.

Wow. Just WOW.

It's quite outside my experience to find that legit web sites are giving impossible advice. and are permitted to do so. snarky comments like 'well get THEM to support you' don't advance the cause very much, though i note the unpleasant fact that "TrevorH" is both moderator and has over 30,000 posts (congrats on that milestone). I don't live here, don't even visit very often, because for me CentOS has been rock-solid and 100% trustworthy. Up to now.

(I use centos as my linux firewall on a box with 3 NICs in it. So, not much day-to-day admin needed.)

I found the tecmint article at https://www.centlinux.com/2020/01/how-t ... erver.html and liked that 'dnf' finalliy shows up in centos, so I went ahead & started the steps.

Now I'm in the same boat. "(gcc >= 8 with gcc < 9) is needed by annobin-9.23-1.el8.x86_64". Can't seem to get out of rpm hell on this one. But I'll keep looking.

And of course I have backups. And though all my kernels are gone and a reboot is impossible as i write this - I simply won't reboot it for a few days, weeks, or months. CentOS is that good. I trust it.

But the trust has a bit of tarnish on it today.

Yep, it's my fault for seeing an article that has very clear and detailed steps, text-blocks rather than GIF screencaps, and stupidly thinking I could follow those steps & upgrade CentOS 7 to 8 "overnight". Lesson learned, I suppose.

Sorry for the trace of snark that crept into this post. But while I expect this kind of bleeding-edge behavior with Fedora (that's why I use it, AAMOF), I didn't expect to be ever be left hanging like this by Centos.

BillHudacek
Posts: 5
Joined: 2006/12/04 04:17:25

Re: dnf upgrade and dnf update fails

Post by BillHudacek » 2020/12/08 16:19:27

Sorry, page I was following is at https://www.centlinux.com/2020/01/how-t ... erver.html

I should not have typed "tecmint" as that's not a page I visited...

Caveat CentOS-user!

(sorry about that)

scottro
Forum Moderator
Posts: 2556
Joined: 2007/09/03 21:18:09
Location: NYC
Contact:

Re: dnf upgrade and dnf update fails

Post by scottro » 2020/12/08 19:21:55

I vaguely remember a CentOS tool to upgrade from 6 to 7, but it never worked well and eventually, advice was to not use it as it was broken. Aside from that, CentOS has never supported in place upgrades, though as Fedora has for awhile, and judging from above posts, so is RedHat now, it seems as if it will be supported in the future. (Although with CentOS-stream, not sure what the story is going to be).

At any rate, there is no in place upgrade supported by CentOS. This is a CentOS forum, so though folks may think it is a matter of moderators sticking together, whatever article was used to attempt the upgrade is something by the article's author, that may have worked for them. So, while it may seem snarky, saying contact them is actually the most logical response. Trevor does more work than any of the other mods on this forum, and spends a great deal of his spare time helping those who post here by answering questions.
New users should check the FAQ and Read Me First pages

Post Reply