Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm running a web server (apache, but I don't think there is really a difference), that serves a lot of requests to mobile devices (hundreds per second). The server is a mix of a pure web server with front end server for a J2EE app server (connecting through something like AJP).

What I notice is that I regularly have to increase the amount of Apache workers to keep up with the amount of requests. And when the bottleneck starts to happen, I see a large amount (~90%) of workers busy with "Writing to client" and "Closing connection".

I understand that this is normal. Considering that the clients are on a slower link, it will hold up Apache worker until the worker can deal away with an individual client request. But I was wondering if there is a dedicated system, h/w or s/w that can buffer the traffic on both request/and response. I've heard of all this "traffic acceleration" hardware, but I don't really know where to start looking for the one that will do just exactly that.

Thank you!

share|improve this question
up vote 2 down vote accepted

Since you mentioned hardware, you may want to look at something like F5's BigIP, which can make an enormous difference in situations like this. It'll terminate those mobile (and other) client connections, spool the content, and optimize the back end flows. It's expensive stuff though.

Another trick with mobile clients is that they often lose packets due to less than ideal signal strength as opposed to link congestion. This causes the TCP/IP stack to back off, so the data rates can be terrible. BigIP can help situations like this too, so it may be worth looking into.

On the open source front, you may consider fronting with nginx or another async I/O proxy to front your system and potentially buffer those connections a bit. This is probably a good first step to try - you can enable proxy buffering on nginx so the effect will be to offload the connections to nginx as opposed to apache and your dynamic apps behind it.

share|improve this answer

Try setting Keepalive Off in your Apache Vhost config.

Sometimes Mobile connections are proxied by a server that will artificially hold connections open whilst they rewrite packets so that the mobile user gets ACK packets quicker than the server has actually ACKed them.

It's sneaky, but sometimes mobile networks are evil.

share|improve this answer
Umm, I wouldn't want to be unfriendly to the mobile devices either, especially since there is a very good chance that a single device will send more than one request, so that would add additional set up/tear down cost. – Pawel Veselov Dec 16 '11 at 0:24

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.