Return-Path: X-Original-To: apmail-httpd-users-archive@www.apache.org Delivered-To: apmail-httpd-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 559DA10A83 for ; Thu, 18 Dec 2014 23:07:52 +0000 (UTC) Received: (qmail 95536 invoked by uid 500); 18 Dec 2014 23:07:46 -0000 Delivered-To: apmail-httpd-users-archive@httpd.apache.org Received: (qmail 95500 invoked by uid 500); 18 Dec 2014 23:07:46 -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 95490 invoked by uid 99); 18 Dec 2014 23:07:46 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 18 Dec 2014 23:07:46 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of ylavic.dev@gmail.com designates 209.85.214.181 as permitted sender) Received: from [209.85.214.181] (HELO mail-ob0-f181.google.com) (209.85.214.181) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 18 Dec 2014 23:07:20 +0000 Received: by mail-ob0-f181.google.com with SMTP id gq1so7024130obb.12 for ; Thu, 18 Dec 2014 15:06:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=4dzNkxdiDO4DGqz1ibzXS7+uuZgNP2tvezTVxtAsM1Y=; b=G4Hp9crWUuQo/3JDZThUgKe4BK3ocnh7Htt+GP7CJ+FmsKNDc/nuoLp0iYfBE0fn2E L8Vs2H2EyjArgZ171AGtJKWaTnUrReS+bOjDxsVrMyiTh2uh7pRwDMOjcacoaCT4JiCr U2VujurFRTE53MOOvzn70Hvrix2O3UF3I5FkOsNVRj369wxaoOt/BjCcFjSOfOhmTvSc vOUx91UDVmCLWD1X61PO73ex664OtvKEViiE3ntxZ6HsZdmhfBo2PJHNp8MCEJN/54QN Qemjettath9p1RG8rdQdsI/9ySywoizRdkpUKsKOx1pjc+W6XgNb63dWc3zlrw1OQdRF dEPA== MIME-Version: 1.0 X-Received: by 10.107.134.212 with SMTP id q81mr4491158ioi.62.1418943994174; Thu, 18 Dec 2014 15:06:34 -0800 (PST) Received: by 10.42.255.7 with HTTP; Thu, 18 Dec 2014 15:06:34 -0800 (PST) In-Reply-To: References: Date: Fri, 19 Dec 2014 00:06:34 +0100 Message-ID: From: Yann Ylavic To: users@httpd.apache.org Content-Type: text/plain; charset=UTF-8 X-Virus-Checked: Checked by ClamAV on apache.org Subject: Re: [users@httpd] Apache 2.4 create a huge amount of shared memory segments If you can manage to recompile the APR library used by your Apache 2.4 (you probably did that already since 2.4 does not seem to be the version packaged with RHEL 6.4), you can use "./configure --enable-posix-shm ..." to use another shared memory mechanism than the default one (IPC SysV) which is limited to 32K segments (system wide). The number of segments would then be limited by the usual number of file descriptors per process (ulimit -n). Unfortunately, there no equivalent to the Mutex directive for shared memories, this can't be changed by httpd's configuration (as far as I know). On Thu, Dec 18, 2014 at 2:30 PM, Sylvain Goulmy wrote: > > I also noticed that a single proxy_balancer creates almost 350 shm on the > system. > > Is it normal that a single proxy_balancer creates so many shm ? How many VirtualHost(s) do you use in your configuration? Also, how do you declare the balancer(s), in each VirtualHost or in the main section using BalancerInherit on? > > Do i really have to increase the memory segment on my system in huge > proportion to handle all my proxy_balancers ? The number of IPC SysV shared-memory segments is limited to 32768 on linux (system wide), and you are already above with 100 * 350, so you would need to use another SHM mechanism. Unfortunately, there no equivalent to the Mutex directive for shared memories, AFAIK this can't be changed by httpd's configuration. So you would have to recompile the APR library used by your Apache 2.4 (you probably did that already since RHEL 6.4 does not seem to package 2.4 by default), and do for example "./configure --enable-posix-shm ..." to use another shared-memory mechanism. The number of segments would then be limited by the usual number of file descriptors per process (ulimit -n). However 350 shm per balancer looks weird to me, your configuration may do something not optimal... Regards, Yann. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org For additional commands, e-mail: users-help@httpd.apache.org