Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
For bugs related to Red Hat Enterprise Linux 5 product line. The current stable release is 5.10. For Red Hat Enterprise Linux 6 and above, please visit Red Hat JIRA https://issues.redhat.com/secure/CreateIssue!default.jspa?pid=12332745 to report new issues.

Bug 460563

Summary: "rpm --dump" shows size=0
Product: Red Hat Enterprise Linux 5 Reporter: Petr Sklenar <psklenar>
Component: rpmAssignee: Packaging Maintenance Team <packaging-team-maint>
Status: CLOSED NOTABUG QA Contact:
Severity: low Docs Contact:
Priority: low    
Version: 5.2CC: pmatilai
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-03-07 09:45:50 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Petr Sklenar 2008-08-28 16:49:38 UTC
Description of problem:
if file has size=1 then second field of "rpm --dump" shows size=0

priority = lower then low

Version-Release number of selected component (if applicable):
all
# rpm -q rpm
rpm-4.4.2.3-3.el5


How reproducible:
always

Steps to Reproduce:

# rpm -ql rpm --dump | grep __db.001
/var/lib/rpm/__db.001 0 1194852312 d41d8cd98f00b204e9800998ecf8427e 0100644 rpm rpm 1 0 0 X
# ll /var/lib/rpm/__db.001
-rw-r--r-- 1 root root 24576 2008-08-28 18:39 /var/lib/rpm/__db.001

  
Actual results:
--dump shows size of /var/lib/rpm/__db.001 zero

Expected results:
--dump shows size of /var/lib/rpm/__db.001 is 1

# rpm -ql rpm --dump | grep __db.001
/var/lib/rpm/__db.001 1 1194852312 d41d8cd98f00b204e9800998ecf8427e 0100644 rpm rpm 1 0 0 X

Additional info:

found during testing bug 250207

Comment 1 Panu Matilainen 2013-03-07 09:45:50 UTC
/var/lib/rpm/* files are %ghost files, ie they are not created by installing the package. The size recorded in headers for %ghosts depends on what was present at build time, typically they are zero-length files created by running "touch", which is the case here. And as 'rpm -ql' shows the file data from headers, not filesystems, zero size is what you get. So this is not actually a bug but expected behavior for %ghost files.