LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   problem with rmp database (https://www.linuxquestions.org/questions/linux-software-2/problem-with-rmp-database-208839/)

linmix 07-23-2004 03:33 PM

problem with rmp database
 
I tried to use find in Gnome and got an alert that the database hadn't been updated in more than 8 days. I didn't remember exactly how to update it so I tried running

Code:

[root@localhost linmix]# updatedb
later I remembered that the original command had been

Code:

[root@localhost linmix]# rpm --updatedb
but the first one appeared to work allright. Then I tried to find out if I had a dependency installed and did rpm -q with the following result:

Code:

[root@localhost linmix]# rpm -qi compat-libstdc++
error: cannot get shared lock on /var/lib/rpm/Packages
error: cannot open Packages index using db3 - Operation not permitted (1)
error: cannot open Packages database in /var/lib/rpm
package compat-libstdc++ is not installed

I think all three errors are related to the same problem and that it may be due to the bad command I issued before. I've thought of manually removing the database (/var/lib/rpm/Packages) and making a new database (something like "rpm --makedb", probably not exactly right, but I can't check it now), but then I thought that this might affect the Install/Uninstall utility (although that always reads the headers, whatever that means). Can anyone tell me if my assumptions are correct, and how to fix this error?

zakaluka 07-23-2004 03:44 PM

I've had that error when I try to use the DB while the database is still being updated in the background. Are you sure the command has finished running (top, ps, ...)?

Regards,

zakaluka.

linmix 07-23-2004 03:48 PM

I'll try running it again as soon as I'm back in Linux

linmix 07-24-2004 02:52 AM

Database update must still have been underway. I tried again after reboot (needed to get into windows) and everything worked perfectly.

bigrigdriver 07-24-2004 07:54 PM

Updatedb builds the database of all installed files on the system, and is seperate from rpm. If you suspect that the rpm database is corrupt, you can rebuild it with the command rpm --rebuilddb.


All times are GMT -5. The time now is 04:03 PM.