> >This message is for every proxied request.
> >Does anybody knows what does it means ?
> >In proxy config I have 
> >ProxyReceiveBufferSize 1048576
> >
> >Restarting proxy server doesn't helps.
> 
> Are you sure you are getting this message on absolutely every proxy request ? 
> 
> Maybe 1048576 is a bit too high, are you really buffering that much ? I
> have set mine to 10240 but I suspect it might still be too high because
> what I am proying is pretty small. I don't get that error though. Have you
> tried setting it to a smaller value to see if you still get that error ?
> The example in the docs sets a buffer of 2048.
> 
> 
> >btw, anybody know what is an optimal size of ProxyReceiveBufferSize
> >and does it really works.


ProxyReceiveBufferSize is used to set the size of the proxy socket's
receive buffer; in proxy_http.c the value is used to set the SO_RCVBUF option.
Check your system's manpage for setsockopt, mine says:

     SO_SNDBUF and SO_RCVBUF are options to adjust
     the normal buffer sizes allocated for output and input buffers, respec-
     tively.  The buffer size may be increased for high-volume connections, or
     may be decreased to limit the possible backlog of incoming data.  The
     system places an absolute maximum on these values, which is accessible
     through the sysctl(3) MIB variable ``kern.maxsockbuf''.


> No, I'm unsure of how that buffer works, especially I don't know if it
> accumulates until it is full or there is nothing more to come, or if it is
> using the same kind of scheme as the new mod_cgi which is supposed to use a
> more efficient scheme. Knowing more about that would likely be useful for
> those of us that are using an Apache proxy to mod_perl.

mod_proxy then goes on to read data from the back end server in a 8k buffer
(HUGE_STRING_LEN = 8k), using a loop:

    if (ap_should_client_block(r)) {
        while ((i = ap_get_client_block(r, buffer, sizeof buffer)) > 0)
            ap_bwrite(f, buffer, i);
    }
    ap_bflush(f);


--
Eric

Reply via email to