On 3/7/06, Michael O'Keefe <[EMAIL PROTECTED]> wrote:
> > Does not xargs(1) accept the output from find(1) as it arrives, and
> > ship it off to grep(1) in suitable buffersful without waiting for
> > find(1) to finish?
>
> No, xargs takes from stdin a list and builds the argv[] for it's command.
> So worst case scenario it will wait for 1023 "lines" of input (without
> the minus-ell flag) before doing it's fork()
> This can of course take a LONG time to accumulate if you are walking
> many NFS mounts. But if you use a suitable minus-ell flag, it will still
> be faster than -exec

Are we not still saying the same thing -- xargs does not wait for
stdin to finish (from the previous process) but does wait for some
amount of input to accumulate.
"worst case 1023 lines" must be implementation-dependent.  My memory
of xargs dates back to when it was a lot less than that.
In any case it can be changed by the --max-linex=<lines> or -l<liines>
or -L<lines> switch.

    carl
--
    carl lowenstein         marine physical lab     u.c. san diego
                                                 [EMAIL PROTECTED]


--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to