Bug 57523 - RPM mangles it's database
RPM mangles it's database
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
Depends On:
  Show dependency treegraph
Reported: 2001-12-14 15:49 EST by Gabriel Schulhof
Modified: 2008-05-01 11:38 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-01-17 18:08:31 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Gabriel Schulhof 2001-12-14 15:49:43 EST
Description of Problem:
On all systems that I've upgraded from 7.1, I have found that once in a while, when doing 
rpm -qa
it hangs in the middle of the command.  Also, when removing packages, sometimes it complains about some db3-related stuff and the package does not get removed properly.  I /think/ the files disappear, but the entry does not disappear from the rpm db.  Both of these issues are fixed by
rpm --rebuilddb
This is only a workaround, since I don't want to have to periodically run such a command in order to keep rpm working.  I didn't have to do that with previous versions of RedHat, so why should I have to do it now.

Version-Release number of selected component (if applicable):
RPM version 4.0.3

How Reproducible:
Most of the time

Steps to Reproduce:
1.Upgrade an existing 7.1 system to 7.2
2.Try doing rpm -qa and watch it hang.
3.Failing that, try using rpm for a prolonged period of time.

Actual Results:
'rpm -qa' hung.  'rpm -e' didn't work properly.

Expected Results:
rpm should work perfectly and not shoot its own database.

Additional Information:
Comment 1 Jeff Johnson 2001-12-19 14:23:26 EST
	rm -f /var/lib/rpm/__db*
to remove cache files.
Comment 2 Gabriel Schulhof 2002-01-08 00:51:05 EST
That didn't fix the problem.  Not only that, others who have installed RedHat from scratch, not as an upgrade, told me about RPMs suddenly disappearing, RPMs that are not installed showing up in the list, even rpm --rebuilddb failing and so on.  This is a really Bad Thing.  RPM is one of the very important things that make Linux user-friendly, especially with Red Carpet to help out, so this is a serious impediment.

RPM is broken, plain and simple.
Comment 3 Jeff Johnson 2002-01-08 14:12:43 EST
How did removing the /var/lib/rpm/__db* files not fix your problem?
Comment 4 Gabriel Schulhof 2002-01-08 23:32:27 EST
It didn't fix it in that rpm -qa hung shortly thereafter, forcing me to do another --rebuilddb, and so on.
Comment 5 Jeff Johnson 2002-01-09 09:53:20 EST
So it fixed the problem but your problem reoccurred?

The cause is doing ^C (I suspect). Also a --rebuilddb is not necessary, only
rm /var/lib/rpm/__db*
Comment 6 Darren Steven 2002-01-17 18:08:26 EST
I can confirm the behaviour, and repeat it. Typing ^C during rpm -qa breaks it 
every time. any other rpm -qa locks up at the point where the prvious ^C 
Comment 7 Jeff Johnson 2002-02-24 12:23:19 EST
This problem will be fixed when concurrent rpmdb
access is permitted.

Note You need to log in before you can comment on or make changes to this bug.