Filemanagement

Chris F.A. Johnson c.f.a.johnson-bJEeYj9oJeDQT0dZR+AlfA at public.gmane.org
Sun Mar 7 23:49:10 UTC 2004


On Mon, 8 Mar 2004, Peter L. Peres wrote:

>
> On Sun, 7 Mar 2004, John Wildberger wrote:
>
> > Can you enlighten me what CLI length is?
>
> The maximum number of characters on a single line passed to the shell
> (CLI=command line interface).

    Actually, it's the length of the line files passed to the
    OS. Lines of any length can be passed to bash for its own use. For
    example, compare these:

ls *.pgn

for file in *.pgn; do ...

    The first one may fail if there are too many matching files, but
    the second will probably succeed, as it's only limited by
    available memory.

> It is set at compilation time and it turns
> out to be hard to discover. It is probably related to the pipe size (bash
> manual, ulimit -p -- says 8*512 bytes = 4kBytes here). If you try to pass
> a longer command line it will be flagged as an error. Additionally, under
> certain circumstances you can cause bad things to happen (as in, wrong
> parameters passed to the next command) if you do this in a script and do
> not check for errors. When something like *.pgn expands in a directory
> with several hundred files you will exceed this limit. The error that
> should be returned is E2BIG (see /usr/include/asm/errno.h), but in reality
> it is something else like 'command line too long'.
>
> Speaking of which, what is ENOANO (comment is 'no anode' ?! i.e. cathode
> only, or ?!)

-- 
	Chris F.A. Johnson                      http://cfaj.freeshell.org
	=================================================================
                Everything in moderation -- including moderation
--
The Toronto Linux Users Group.      Meetings: http://tlug.ss.org
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://tlug.ss.org/subscribe.shtml





More information about the Legacy mailing list