Date: Tue, 08 Jul 2014 15:09:05 +0800 From: Julian Elischer <julian@freebsd.org> To: Warner Losh <imp@FreeBSD.org>, svn-src-head@freebsd.org Subject: Re: svn commit: r268376 - head/bin/rm Message-ID: <53BB9911.60804@freebsd.org> In-Reply-To: <201407072321.s67NLL7p070713@svn.freebsd.org> References: <201407072321.s67NLL7p070713@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 7/8/14, 7:21 AM, Warner Losh wrote: > Author: imp > Date: Mon Jul 7 23:21:20 2014 > New Revision: 268376 > URL: http://svnweb.freebsd.org/changeset/base/268376 > > Log: > rm -rf can fail sometimes with an error from fts_read. Make it honor > fflag to ignore fts_read errors, but stop deleting from that directory > because no further progress can be made. > > When building a kernel with a high -j value on a high core count > machine, during the cleanobj phase we can wind up doing multiple rm > -rf at the same time for modules that have subdirectories. This > exposed this race (sometimes) as fts_read can return an error if the > directory is removed by another rm -rf. Since the intent of the -f > flag was to ignore errors, even if this was a bug in fts_read, we > should ignore the error like we've been instructed to do. One could make an argument that being unable to delete something because someone else deleted it first is a "non error". Even without -f >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?53BB9911.60804>