My computer crashes every time I try to install or remove a package with dnf, regardless of which package it is. Does anyone know what’s going on?
My current version is Fedora 32. Anyway, the dnf installation command works. After crashing I need to force reboot, and the package is installed correctly with its dependencies.
I’m not sure when this problem started. But I remember that a few weeks ago, when I was updating the system before the shutdown, the computer remained in the update message for hours and, contrary to what the message recommended, I forced the shutdown.
The context of this link is for problems after version upgrades, but rebuilding applies any time your database gets corrupted (and shutting down while dnf is updating will certainly cause corruption).
As the link says, it’s a good idea to back up /var/lib/rpm beforehand. Once it’s completed, you can hopefully use dnf again. Don’t forget that if the dnf package itself was being updated on forced shutdown, it might itself be corrupt.