Bug 141556 - rdonly query creates files when using --root or --dbpath
rdonly query creates files when using --root or --dbpath
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: rpm (Show other bugs)
All Linux
medium Severity low
: ---
: ---
Assigned To: Jeff Johnson
Mike McLean
Depends On:
  Show dependency treegraph
Reported: 2004-12-01 19:00 EST by Mike McLean
Modified: 2007-11-30 17:07 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-02-07 18:00:08 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 Mike McLean 2004-12-01 19:00:16 EST
Description of problem:
An rpm query using the --root or --dbpath options will (silently) create
directories and files for an rpm db if they do not yet exist.  This is
counter-intuitive because one expects a query operation to be read-only.

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

How reproducible:

Steps to Reproduce:
[root@zim root]# rm -rf /tmp/badpath
[root@zim root]# rpm -qa --root /tmp/badpath

Actual results:
[root@zim root]# find /tmp/badpath -type f

Expected results:
[root@zim root]# find /tmp/badpath -type f
find: /tmp/badpath: No such file or directory

and perhaps even
[root@zim root]# rpm -qa --root /tmp/badpath
rpmq: no such rpm database, try using rpm --initdb first
Comment 1 Jeff Johnson 2005-02-07 18:00:08 EST
Unless told otherwise (and with an attached tracking
bug so I know where to delive a fix), this is exactly
the behavior that I intended to implement in rpm.

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