On Tue, Jul 08, 2003 at 10:21:19AM -0700, Andrew Farmer wrote:
> 
> The problem is probably that, when the command is run at boot,
> (find /var/lock -type f -print0) returns a very long list of files,

Hmm...

Why?

What would create a lot of files in /var/lock?

How long is a "long list"?  Hundreds of files?  Thousands?  Millions?

xargs is reading from stdin!!  It should be able to read an infinitely
long list of filenames.

> which is too long for xargs to deal with properly.

xargs was written *explicitly* to get around the problem of "too many
files passed".  That's why it reads from stdin.

The "-print0" option to find and "-0" option to xargs is a gnu extension
(AFAIK) to allow for files containing newlines in their name, but xargs
is definitely broken if it can't read an arbitrarily long list of
null separated filenames from stdin.

I'm still completely puzzled by this problem.  I wish I could reproduce
it without having to reboot!

Regards,
-- 
Rex

--
[EMAIL PROTECTED] mailing list

Reply via email to