Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 82443 - Attempt to erase non-existent package corrupts database
Attempt to erase non-existent package corrupts database
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
All Linux
medium Severity high
: ---
: ---
Assigned To: Jeff Johnson
Mike McLean
Depends On:
  Show dependency treegraph
Reported: 2003-01-22 01:46 EST by jw1233219
Modified: 2007-04-18 12:50 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2003-01-22 06:49:27 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 jw1233219 2003-01-22 01:46:10 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows 98; hahaha-fooled you!
This is really Mozilla/5.0 on Linux i686 rv:1.0.1 Gecko/2002103)

Description of problem:
If you attempt to erase a non-existent package rpm exits
with an error message but leaves database in inconsistent state.

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

How reproducible:

Steps to Reproduce:
1. rpm -e kde-i18n-German
2. rpm -e kde-i18n-xxxxxx
3. rpm -e kde-i18n-Slovenian

Actual Results:  1. Success
2. error: package kde-i18n-xxxxxx is not installed
3. rpm hangs up forever - you can only stop the process
   with kill -9 because it has interrupts disabled.

Expected Results:  1. Success
2. error: package kde-i18n-xxxxxx is not installed
3. Success

Additional info:

rpm should be much more robust because it is so important to
the maintenance of a system, and because it is a RedHat product.

An instance of rpm should also behave differently if it sees
that the database appears to be locked - instead of just hanging
indefinitely with all signals disabled!
Comment 1 Jeff Johnson 2003-01-22 05:26:00 EST
You have a stale lock.

This has nothing to do with removal of non-existent

Remove the stale lock by doing
    rm -f /var/lib/rpm/__db*

See the bug report regarding "hangs" and "READ ME FIRST".
Comment 2 jw1233219 2003-01-22 06:45:01 EST
Before I started I did:

    rm -f /var/lib/rpm/__*
    rpm --initdb
    rpm --rebuilddb

So it was a clean database.

Comment 3 Jeff Johnson 2003-01-22 06:49:27 EST
I tried exactly the commands you gave with rpm-4.2-0.56
and cannot reproduce.

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