I don't know exactly why you're showing such performance, although I suppose any command that has to work through the kernel's I/O system will likely be slower than one like
dd that can do direct disk operations. Not to mention that shred needs to overwrite the disk several times in order to destroy data, as opposed to simply creating a file, which takes only a single write operation. There may be buffering effects going on as well.
The
find | xargs pipe chain can only slow it down even more. But you really shouldn't need to use
xargs here anyway.
find has the equivalent ability to apply commands on it's own, using the
-exec option.
Code:
find . -type f -exec shred -zu '{}' \+
The
\+ at the end of the -exec command makes it perform the same way xargs does, with as many files as possible concatenated into a single run. If your command can't handle the multiple inputs, you'd have to use
\; instead, which will make it run separately for each file find feeds it.