bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: find command trigger coredump


From: Kamil Dudka
Subject: Re: find command trigger coredump
Date: Thu, 16 Apr 2020 12:58:11 +0200

On Thursday, April 16, 2020 6:03:45 AM CEST Paul Eggert wrote:
> Thanks for the bug report archived at
> <https://lists.gnu.org/r/bug-gnulib/2020-04/msg00068.html>. What you appear
> to be saying is that the Gnulib fts NOSTAT_LEAF_OPTIMIZATION code is buggy
> when an XFS filesystem is mutating, and that your test case illustrates a
> mutating filesystem that can cause 'find' and 'du' to dump core because
> fts.c's tight-cycle check messes up its hash table.
> 
> I reproduced the bug on an XFS filesystem on Fedora 31 x86-64.
> 
> I worked around the bug by removing that optimization from Gnulib fts.c, by
> installing the attached patch. I expect that this optimization is obsolete
> nowadays, as XFS is now working and ReiserFS is either working, or is so
> unpopular that high performance for du and find is not that important for
> it.
> 
> I have the sneaking suspicion that we can now remove at least some of the
> special cases for AFS, CIFS, NFS, and /proc filesystems in the
> leaf_optimization subroutine. However, doing so would merely improve
> performance, so I resisted the temptation to make that change. I'll cc this
> message to other people who've touched the fts.c code to see whether they
> have any advice about that.
> 
> Thanks again for reporting the bug.

We had a similar bug report this week in Red Hat Bugzilla - find crashed while 
traversing a mutating directory tree on an XFS file system:

    https://bugzilla.redhat.com/1823247

But we did not have an isolated reproducer for the crash, so we cannot easily 
check whether the proposed patch fixes it or not.

Kamil





reply via email to

[Prev in Thread] Current Thread [Next in Thread]