Bill Campbell wrote:
There are two possible buffer limits one could encounter: tty driver input line buffer (which is not an issue for bash because readline avoids it) and kernel exec space for the arguments plus environment passed to a new process. Only the second one causes the error message that started this thread, and previous posts have pointed out that recent Linux kernels have effectively removed that limit (see message from Jeremy Sanders).
While current Linux kernels may have removed the limit,
It's probably a mistake to say that the limit is removed. I think this change just moves the limiting factor elsewhere - to the RAM or virtual memory that happens to be available.
this has been a common issue on all *nix systems for decades, which is why xargs was written.
Recognizing that you do not have infinite buffer space available is a good thing. Keep using xargs.