Bug 221406

Summary: Double free() or corruption
Product: Red Hat Enterprise Linux 4 Reporter: Matteo Corti <matteo>
Component: slocateAssignee: Miloslav Trmač <mitr>
Status: CLOSED WONTFIX QA Contact: Brock Organ <borgan>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.4   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-20 13:30:04 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:
Attachments:
Description Flags
valgrind --log-file=/root/updatedb.log updatedb
none
updatedb 2>&1 |tee log
none
TEST_FIX=1 updatedb 2>&1 | tee log2
none
/etc/mtab
none
updatedb 2>&1 |tee log
none
updatedb 2>&1 |tee log4
none
Make sure fts_cur is always valid after return from fts_read () none

Description Matteo Corti 2007-01-04 15:13:46 UTC
Description of problem:


Version-Release number of selected component (if applicable):
slocate-2.7-13.el4.6

How reproducible:
updatedb

Steps to Reproduce:
1. updatedb
  
Actual results:
*** glibc detected *** double free or corruption (top): 0x08553d60 ***

Expected results:
nothing

Additional info:

Comment 1 Miloslav Trmač 2007-01-05 01:45:24 UTC
Thanks for your report.

If you are a RHEL customer and have an active support entitlement, please
contact official Red Hat Support at https://www.redhat.com/apps/support/ to
allow correct prioritization of this issue.

Otherwise, please install the valgrind and slocate-debuginfo packages, run the
following commands:
    chmod g-s /usr/bin/updatedb
    valgrind --log-file=updatedb.log updatedb
    chmod g+s /usr/bin/updatedb
and attach the generated updatedb.log* files.

Comment 2 Matteo Corti 2007-01-05 07:20:42 UTC
Created attachment 144891 [details]
 valgrind --log-file=/root/updatedb.log updatedb

Comment 3 Miloslav Trmač 2007-01-09 08:50:20 UTC
Thanks.  Please install
http://people.redhat.com/mitr/221406/slocate-2.7-13.el4.6.0.mitr.test221406.1.i386.rpm
and:
- run (updatedb 2>&1 |tee log), and attach at least the last 100 lines of the
  generated log output.  This should crash similarly to slocate-2.7-13.el4.6.
- run (TEST_FIX=1 updatedb 2>&1 | tee log2).  This should not crash; if it does,
  please attach at least the last 100 lines of the generated log2 output.

This is only a debugging version of the package, please return to 2.7-13.el4.6
after performing the tests

Please attach the contents of your /etc/mtab as well.

Comment 4 Matteo Corti 2007-01-09 09:43:14 UTC
Created attachment 145143 [details]
updatedb 2>&1 |tee log

Comment 5 Matteo Corti 2007-01-09 09:47:26 UTC
Created attachment 145144 [details]
TEST_FIX=1 updatedb 2>&1 | tee log2

Comment 6 Matteo Corti 2007-01-09 09:50:13 UTC
Created attachment 145145 [details]
/etc/mtab

Comment 7 Matteo Corti 2007-01-09 09:51:39 UTC
Thank,
I run the supplied version and it still crashes (even with TEST_FIX=1): see
attachments.
Matteo

Comment 8 Miloslav Trmač 2007-01-10 07:40:46 UTC
Thanks.
This demonstrates that the root cause of the problems is that the inode number
of /usr/sepp/Old/pack/openssl-0.9.8c-lp is changing while updatedb is running;
this can't be fixed within slocate. 
http://www.openafs.org/pipermail/openafs-devel/2006-June/013901.html seems to
suggest this is a bug in OpenAFS.

Nevertheless, updatedb shouldn't crash, and I can't figure out why TEST_FIX=1
doesn't work.  Please install
http://people.redhat.com/mitr/221406/slocate-2.7-13.el4.6.0.mitr.test221406.1.i386.rpm
, run (updatedb 2>&1 |tee log), and attach the generated log file.

Comment 9 Matteo Corti 2007-01-10 11:04:31 UTC
Created attachment 145246 [details]
updatedb 2>&1 |tee log

Comment 10 Matteo Corti 2007-01-10 11:05:59 UTC
Thanks again,

OK. I'll wait to try to fix AFS so that we can reproduce the bug.

Matteo

Comment 11 Miloslav Trmač 2007-01-11 10:10:57 UTC
I'm really sorry, I intended to point you to 
http://people.redhat.com/mitr/221406/slocate-2.7-13.el4.6.0.mitr.test221406.2.i386.rpm
(not ...test221406.1.i386.rpm).  Can you attach the log from this version, please?

Comment 12 Matteo Corti 2007-01-11 11:08:13 UTC
Created attachment 145331 [details]
updatedb 2>&1 |tee log4 

slocate-2.7-13.el4.6.0.mitr.test221406.2.i386.rpm

Comment 13 Miloslav Trmač 2007-01-11 11:22:21 UTC
Thanks.  This version didn't crash, did it?

Comment 14 Matteo Corti 2007-01-11 11:32:18 UTC
Sorry I forgot to comment last run.
It didn't crash (although it seems to stop where the problem occurs, i.e., the
last processed entry seems the same).
Matteo

Comment 15 Miloslav Trmač 2007-01-11 11:35:58 UTC
Thank you.

Stopping at the problem directory is expected, there is no practical way to
recover from the inode mismatch.


Comment 16 Miloslav Trmač 2007-01-11 11:37:31 UTC
Created attachment 145333 [details]
Make sure fts_cur is always valid after return from fts_read ()

Comment 17 RHEL Program Management 2008-02-01 19:10:42 UTC
This request was evaluated by Red Hat Product Management for
inclusion, but this component is not scheduled to be updated in
the current Red Hat Enterprise Linux release. If you would like
this request to be reviewed for the next minor release, ask your
support representative to set the next rhel-x.y flag to "?".

Comment 18 Jiri Pallich 2012-06-20 13:30:04 UTC
Thank you for submitting this issue for consideration in Red Hat Enterprise Linux. The release for which you requested us to review is now End of Life. 
Please See https://access.redhat.com/support/policy/updates/errata/

If you would like Red Hat to re-consider your feature request for an active release, please re-open the request via appropriate support channels and provide additional supporting details about the importance of this issue.