I'm testing a system which uses a protocol of its own built on top of HTTP. It
is supposed to work through an Apache server configured as a proxy. For better
or worse, the application protocol requires that a sequence of HTTP requests
take place on a single TCP connection - this isn't something I can change.
However, I am having difficulty because the Apache proxy is splitting the
requests across multiple connections - fine for normal Web serving but fatal to
the application I am required to test.
This is the topology I am using:
:
+-----+1.11 1.12+----:---+2.10 2.11+-----+
| App |===========| Pro:xy |===========| App |
+-----+ 80+----:---+ 80+-----+
:
(upper numbers are last two octets of IP, lower numbers are ports)
These are the relevant (as far as I'm aware) directives from httpd.conf:
Timeout 120
KeepAlive On
MaxKeepAliveRequests 5000
KeepAliveTimeout 43200
<IfModule prefork.c>
StartServers 8
MinSpareServers 5
MaxSpareServers 20
ServerLimit 256
MaxClients 256
MaxRequestsPerChild 4000
</IfModule>
(and httpd -l shows prefork rather than worker)
Listen 80
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
ProxyRequests On
<Proxy *>
</Proxy>
Any suggestions on why Apache isn't keeping the connections open? Before testing
the version under development, I'm setting the test up against the "current
release" version of the application - which is known to have worked in this
configuration (though possibly on an older Apache).
Thanks for your help,
Pete
The ProxyPass directive has various parameters that influence how long
the connections are kept open for:
http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxypass see e.g.
max, smax and ttl.
The Apache Users mailing list might be a good place to ask about this.
But expect to be told that your application is broken.
Phil.
> The ProxyPass directive has various parameters that influence how long the connections are kept open for:
...
> But expect to be told that your application is broken.
You might think this; I couldn't possibly comment :-)
It's a long-standing application, in a commercial setting. The chance of any
effort being assigned to modify it in this way, when it apparently works under
normal circumstances, is slim-to-none.
I'll try using ProxyPass and report back - thanks.
Pete
> I'll try using ProxyPass and report back - thanks.
Thanks, Phil - this seems to have fixed the problem.
Pete