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

Re: rm -rf is too slow on large files and directory structure(Around 30000)



Christofer C. Bell wrote:
> unlink is slower than rm removing a 1.5GB file (at least on ext3):
> ...
> I suspect that removing a large number of non-zero byte files will be
> slower with unlink than rm.

If it is then it is pointing to a kernel performance issue.  Because
there is very little difference between them.  Until recently rm used
unlink(2) and there would have been no difference.  But recent
versions of coreutils now use unlinkat(2) for improved security now
instead.  Any difference in performace would be in the realm of the
kernel internals.  It doesn't seem to me like there should be any
significant difference.

Bob

Attachment: signature.asc
Description: Digital signature


Reply to: