bug-coreutils
[Top][All Lists]
Advanced

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

Re: Threaded versions of cp, mv, ls for high latency / parallel filesyst


From: James Youngman
Subject: Re: Threaded versions of cp, mv, ls for high latency / parallel filesystems?
Date: Sat, 8 Nov 2008 19:42:15 +0000

On Sat, Nov 8, 2008 at 6:05 PM, Jim Meyering <address@hidden> wrote:
> How about parallelizing it via xargs, e.g.,
>
>    $ echo a b c d e f g h | xargs -t -n4 --no-run-if-empty \
>      --max-procs=2 -- cp --target-directory=dest
>    cp --target-directory=dest a b c d
>    cp --target-directory=dest e f g h

For tools lacking a --target-directory option there is this shell trick:

$ echo a b c d e f g h |
 xargs -n4 --no-run-if-empty --max-procs=2 -- sh -c 'prog "$@" destination' prog

James.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]