* SUMMARY: Tru64 pipe buffer size
@ 2005-04-11 19:40 Iain Barker
0 siblings, 0 replies; only message in thread
From: Iain Barker @ 2005-04-11 19:40 UTC (permalink / raw)
The problem was that the application detected whether its stdout was going to file (pipe) or term, and did buffering in the case of a file.
Thanks to John Lanier, who wrote:
Reference these parameters in the "vfs" kernel subsystem:
--> sysconfig -q vfs|grep pipe
pipe_maxbuf_size = 262144
pipe_databuf_size = 8192
pipe_max_bytes_all_pipes = 134217728
--> sysconfig -Q vfs|grep pipe
pipe_maxbuf_size - type=INT op=CRQ min_val=4096 max_val=1048576
pipe_databuf_size - type=INT op=CRQ min_val=4096 max_val=32768
pipe_max_bytes_all_pipes - type=INT op=CRQ min_val=819200
max_val=1717986918
In actual fact, there was an easier way around the problem in our particular situation: Pipe the output via the tee command.
It seems that tee opens its stdin as a term, and its output as a file handle. So it can happily sit in the middle of the pipe and do the required un-buffering.
- Iain
-----Original Message-----
From: tru64-unix-managers-owner@ornl.gov
[mailto:tru64-unix-managers-owner@ornl.gov]On Behalf Of Iain Barker
Sent: Wednesday, 06 April, 2005 14:57
To: tru64-unix-managers@ornl.gov
Subject: Tru64 pipe buffer size
Managers,
Is there any way to alter the buffer size used for the pipe (|) command on Tru64?
We have a third-party tool which writes line-by-line to terminal device, but when its output is piped it seems to be buffering the data in chunks of approx 4KB at a guess.
For example, assuming each line represents ~1.5K of data:
./foobar
a
b
c
d
e
f
end of data
./foobar | tee outfile
a
b
c
<20 minute wait>
d
e
f
end of data
thanks,
Iain
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-04-11 19:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-04-11 19:40 SUMMARY: Tru64 pipe buffer size Iain Barker
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox