I'm trying to figure out a very strange problem with
yum on a fairly old CentOS 5.11 VPS using DirectAdmin.
Executing the following command suggests the
telnet package is installed:
# yum install telnet ... Installed: telnet.x86_64 1:0.17-41.el5
telnet is still missing:
# which telnet /usr/bin/which: no telnet in (/root/local/node/bin:/usr/local/share/npm/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/share/adt-bundle/tools:/root/share/adt-bundle/platform-tools)
My version of Yum is 3.2.22.
Perhaps a hint of what is going wrong is that I appear to have different versions of
rpm installed somehow. If I try to verify my RPM database, my database version appears invalid:
# rpm --version RPM version 4.3.3 # rpm --verify telnet rpmdb: Program version 4.2 doesn't match environment version error: db4 error(22) from dbenv->open: Invalid argument error: cannot open Packages index using db3 - Invalid argument (22) error: cannot open Packages database in /var/lib/rpm package telnet is not installed
If I rebuild the RPM database using the following command:
rm -rf /var/lib/rpm/__db* && rpm --rebuilddb
Yum gives a similar error, but complaining about a newer version:
# yum update Loaded plugins: fastestmirror rpmdb: Program version 4.3 doesn't match environment version error: db4 error(-30974) from dbenv->open: DB_VERSION_MISMATCH: Database environment version mismatch error: cannot open Packages index using db3 - (-30974) error: cannot open Packages database in /var/lib/rpm
/var/lib/rpm/__db* files gets Yum past this again, but installed packages still appear to be missing.
I get the feeling that Yum is somehow misconfigured or that I have two different versions of RPM. What can I do to diagnose the problem to ultimately work to a resolution?