|
Find - exec is much slower than find |xargs rm, because in the case of n files find -exec will invoke rm n times whereas find|xargs will only invoke rm n mod <max commandline args> times, so you see a major speed up in terms of process invocation overhead.
The ultimate power combo is find -print0|xargs -0 rm -f
It uses null characters rather than whitespace to separate the output/input so it won't break in the face of files with spaces or newlines embedded in the names.
__________________
Stop intellectual property from infringing on me
|