filesystem limits

Gregory Boyce gboyce at badbelly.com
Tue Jan 11 18:46:51 EST 2005


On Tue, 11 Jan 2005, Bill Holt wrote:

> woops...
> find . -name '*' | xargs rm

Wouldn't this end up adding all of the filenames as an argument to rm, 
hitting the same argument limitation that "rm *" would get?

I would normally do:

find . -name '*' -exec rm {} \;

It ends up invoking a separate rm for each file which gets around that 
problem, although it'll probably be slower since it needs to spawn a new 
process each time.

--
Greg



More information about the Discuss mailing list