Linda Walsh wrote: > Chet Ramey wrote: >> Linda Walsh wrote: >>> When under linux (2.6.30.x), I type >>> ulimit -p and get a return value of "8". >>> >>> from the man page this is in 512-byte blocks and may not be set. >> >> It's set at build time. Look at builtins/ulimit.def:pipesize() and >> builtins/psize.sh (which uses builtins/psize.c). >> Chet > ---- > What is supposed to be controlling? > > When I create a pipe with the pipe system call, and try writing > blocks of data from a master(parent) to a child, I get very large values > for > bytes sent in one write or read in one read from the pipe. > > More like it's a limitation on some physical memory constraint.
No, it's the atomic pipe size. That's the number of bytes guaranteed to be written to a pipe atomically (as a single unit, without interspersing data from other processes). This is 4096 on Linux no matter how you get it: PIPE_BUF/pathconf/fpathconf/sysconf/getconf/write-and-run-your-own-program. Chet -- ``The lyf so short, the craft so long to lerne.'' - Chaucer Chet Ramey, ITS, CWRU c...@case.edu http://cnswww.cns.cwru.edu/~chet/