Description of problem: When verifying an RPM on a disk with media errors, rpm gets Bus Error (core dump) if it encounters an IO error while reading a file to compute the checksum. Version-Release number of selected component (if applicable): rpm-4.9.1.3-1.fc16.i686 How reproducible: Always Steps to Reproduce: 1. Use a disk with real errors, or error simulating block device for filesystem. 2. Install package foo, create IO error in a file belonging to foo 3. Do stuff to drop files of foo from block cache. Run rpm -V foo Actual results: Bus Error (core dumped) Expected results: At the very least, something like "read: IO Error". Ideally, the error message should mention which file it was reading! Additional info: I'm guessing that verify uses mmap instead of read, complicating error handling.
It would be super handy, when dealing with disk errors in the field in places with no electronics store handy, if rpm would not only report the file with an error, but flag it with an E (for Error) it its report and keep processing. It would be acceptable if this required a command line option to use read() instead of mmap() to simplify error handling (at the cost of performance). Current procedure is to tail /var/log/messages to find block # of failure, run lbatofile.py to discover filename. Rename file, rerun rpm -V (which now reports the file as "missing" - much better than a core dump).
*** This bug has been marked as a duplicate of bug 854798 ***