Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] Re: Apache: Logging: how-to pipe logs orlogtoanothermachine (was Disk



>>>>> "BR" == Bruno Raoult <br@example.com> writes:

    >> posted earlier shows that gzip uses buffer size 49152, for both print
    >> $_ and print rand.

    BR> strace on gzip gives:
    BR> [...]
    BR> read(0, "VIDIA NVdriver Kernel Module  1."..., 8192) = 8192
    BR> read(0, "(li) CMD (cd /www/li-bridge; wge"..., 32768) = 8192
    BR> read(0, "] Rejected at IN(default) filter"..., 24576) = 8192
    BR> write(1, "\266\255\334\221\322\\\333\272$)\315\267\255\272\332!I"...,
    BR> 16384) = 16384
    BR> [...]

    BR> This means that the input buffer is BUFSIZ, and output buffer is
    BR> 2*BUFSIZ.

Yes but you can also see several reads before the write. It means that
gzip writes its output after certain number of reads (6 for the first
output, 6*BUFSIZ = 49152 according to what I found out). But I think
the internal buffering (a number of reads followed by a number of
writes) depends on the compressing algorithm.

Viktor


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links