How to remove package from rpm database

You need to uninstall the incorrectly installed package, i.e.:

rpm -e zabbix-release

You remove packages by package name, not by filename, because installed packages don't have a filename.


Of course, this probably won't fix the problem, because you destroyed and rebuilt the RPM database when there was no need to do so, and it is likely there are files the wrong package installed that are no longer tracked. You will need to find these and remove them manually. Look in the /etc/yum.repos.d directory and find repo files which don't correspond to your distribution. Or you might get lucky and the files get cleaned out OK.


Once that's done, you need to clean yum's caches with yum clean all and then reinstall the correct zabbix-release RPM.