title: How to measure the time HTTP requests spend sitting in the accept-queue?
body: <p>I am using Apache2 on Ubuntu 9.10, and I am trying to tune my configuration for a web application to reduce latency of responses to HTTP requests.</p>
  
  <p>During a moderately heavy load on my small server, there are 24 apache2 processes handling requests.  Additional requests get queued.</p>
  
  <p>Using "netstat", I see 24 connections are ESTABLISHED and 125 connections are TIME_WAIT.
  I am trying to figure out if that is considered a reasonable backlog.</p>
  
  <p>Most requests get serviced in a fraction of a second, so I am assuming requests move through the accept-queue fairly quickly, probably within 1 or 2 seconds, but I would like to be more certain.</p>
  
  <p>Can anyone recommend an easy way to measure the time an HTTP request sits in the accept-queue?</p>
  
  <p>The suggestions I have come across so far seem to start the clock <em>after</em> the apache2 worker accepts the connection.  I'm trying to quantify the accept-queue delay before that.</p>
  
  <p>thanks in advance,
    David Jones</p>