Question Locked

How to use xargs with find

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I have a large number of files on disk and trying to xargs with find to get faster output. find . -printf '%m %p\n'|sort -nr

If I write find . -printf '%m %p\n'|xargs -0 -P 0 sort -nr, it gives error argument line is too long. Removing -0 option gives other error.

2 replies

by kees_b

I see many explanations if I ask Google to tell me what it knows about LINUX XARGS FIND .

by tourism-must0f

xargs is great, but I find parallel much easier to use, not to mention its output handling is better. There are also xapply and xclate from the BSD world, which also have significant advantages over xargs, but overall I find myself using parallel whenever I need to run lots of jobs at once.

This discussion is closed to new replies.