Argument list too long.

Sean Estabrooks seanlkml at rogers.com
Thu Sep 11 15:58:00 UTC 2003


On Thu, 11 Sep 2003 17:41:35 +0200 (CEST)
Dag Wieers <dag at wieers.com> wrote:

> On Tue, 9 Sep 2003, Mike A. Harris wrote:
> > On Mon, 8 Sep 2003, Dag Wieers wrote:
> > >I'm not in favor to increase it to 64 per se, but at least something 
> > >higher than 32 (as I've already come across this boundary at several 
> > >occassions where the only solution was to work around it in a bad way).
> > 
> > man xargs
> 
> Seems plausible but unpractical in some situations. Eg. you're resigning
> thousands of files, too long for the argument list. Doing it one by one 
> would force you to enter your passphrase a thousand times.
> 
> You could split it up like the document says, but even that will make it 
> harder (there's no guarantee that [a-n] will not be too long). Or you 
> could starting to write an expect script that enters your passphrase... 
> Sure.
> 
> But the easiest solution IMO would be to increase the size so that it 
> doesn't occur that often in practice.
> 

Dag,

  You just don't hear many people complaining about this as a 
problem.  xargs allows you to combine the maximum number of 
arguments per invocation of the command (-s option).   This limit 
isn't reached very often in practice, and no matter what value you 
pick someone will find a command that exceeds the limit.  

   It usually doesn't take much effort to organize things so that this 
just isn't an issue.   Perhaps if you posted a real script where you
are having problems, suggestions could be made on alternative 
methods.

Cheers,
Sean





More information about the fedora-devel-list mailing list