Re: newbie - questions about "rm"
- From: "Chris F.A. Johnson" <cfajohnson@xxxxxxxxx>
- Date: Wed, 27 Dec 2006 15:21:17 -0500
On 2006-12-27, dave8421@xxxxxxxxxxx wrote:
Hi,
I've read that 'xargs' should be used with 'rm' when using a list of
files too large for 'rm' to process.
I'm wondering why 'rm' doesn't just accept a list of files as a command
line argument,
It does, but if therre are a lot of files, it may exceed the
system limit.
Also, if the output is redirected from another command, is there a lot
of overhead using a program like xargs, since it is calling the program
multiple times? Is this considered to be efficient way of processing
arguments, or is there a better way?
xargs puts as many arguments on the command line as the system
will allow, so that the command is called the fewest possible
number of times.
--
Chris F.A. Johnson, author | <http://cfaj.freeshell.org>
Shell Scripting Recipes: | My code in this post, if any,
A Problem-Solution Approach | is released under the
2005, Apress | GNU General Public Licence
.
- References:
- newbie - questions about "rm"
- From: dave8421
- newbie - questions about "rm"
- Prev by Date: Re: newbie - questions about "rm"
- Next by Date: Re: newbie - questions about "rm"
- Previous by thread: Re: newbie - questions about "rm"
- Next by thread: Hibernate all processes in a KDE desktop?
- Index(es):
Relevant Pages
|