Return-Path: Delivered-To: apmail-httpd-users-archive@www.apache.org Received: (qmail 83730 invoked from network); 17 Nov 2010 21:35:22 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 17 Nov 2010 21:35:22 -0000 Received: (qmail 50156 invoked by uid 500); 17 Nov 2010 21:35:50 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 50096 invoked by uid 500); 17 Nov 2010 21:35:50 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 50088 invoked by uid 99); 17 Nov 2010 21:35:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Nov 2010 21:35:50 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [83.160.57.126] (HELO mail.adaptr.nl) (83.160.57.126) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Nov 2010 21:35:44 +0000 Received: from [10.10.10.100] (core64.adaptr.nl [10.10.10.100]) by mail.adaptr.nl (Postfix) with ESMTPSA id E4E8A1D8081 for ; Wed, 17 Nov 2010 22:35:22 +0100 (CET) Message-ID: <4CE44A9A.5060707@adaptr.nl> Date: Wed, 17 Nov 2010 22:35:22 +0100 From: Jeroen Geilman User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.14) Gecko/20101020 Mnenhy/0.8.3 Thunderbird/3.0.9 ThunderBrowse/3.3.2 MIME-Version: 1.0 To: users@httpd.apache.org References: <20101117204318.06e9371e@baldur> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [users@httpd] httpd choking (503 errors) when stressing mod_proxy On 11/17/2010 10:23 PM, Ahmed Bakir wrote: > Thanks for the responses! > > @jeroen: > > - There is no bandwidth difference between the connections. Both the > client and the host are either running on the same machine or on the > same LAN (I have tested on both and see the problem in both cases) > - I have increased TCP receiver buffers, and that has alleviated the > problem but it's not a feasible solution for my application. Because ? > - I am running httpd on Windows (I have tried both Windows 7 and > Windows XP) Ugh. Fugly TCP stack. > - These are my MPM details: > > Timeout 300 > MaxKeepAliveRequests 100 > KeepAliveTimeout 15 > For a reverse proxy with heavy load, DISABLE keepalives. COMPLETELY. They don't serve any useful purpose, and may in fact slow things down. You won't observe the issues when testing from one client, because that one client will re-use its connections. However, this does not work in the real world - proxy connections are fire-and-forget as far as the server is concerned. Keepalive under heavy load contributes to what you are seeing - service unavailable. > > ThreadsPerChild 250 > MaxRequestsPerChild 0 > > > - I have configured my reverse proxy using rewrite rules with the [P] > directive > > This is an example: > > RewriteRule ^files/(.*)$ http://localhost:16/$1 [P] Yeah... that means you can't regulate the proxy pool size and other settings. I'd reconsider using rewriterules when you don't really know why you're using them. A proper FilesMatch or Proxy block will do just fine: ProxyPass http://localhost:16/ min=100 max=250 smax=100 acquire=1000ms For example; I am by no means an expert on proxy configuration, but this I could infer from the documentation in a few minutes. You need to match the number of backend threads to your expected or - better - observed connections. > - I did not set any ProxyPass options in my config. Perhaps you should! -- J. --------------------------------------------------------------------- The official User-To-User support forum of the Apache HTTP Server Project. See for more info. To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org " from the digest: users-digest-unsubscribe@httpd.apache.org For additional commands, e-mail: users-help@httpd.apache.org