From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: * X-Spam-ASN: AS33070 50.56.128.0/17 X-Spam-Status: No, score=1.3 required=3.0 tests=MSGID_FROM_MTA_HEADER, RDNS_NONE shortcircuit=no autolearn=no version=3.3.2 Path: news.gmane.org!not-for-mail From: Alexandre Riveira Newsgroups: gmane.comp.lang.ruby.rainbows.general Subject: Re: memory usage Date: Sun, 27 Oct 2013 11:35:40 +0000 Message-ID: <526CFA8C.7000300@objectdata.com.br> References: <52663744.6040600@objectdata.com.br> <20131022160930.GA3020@dcvr.yhbt.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1382881054 20461 80.91.229.3 (27 Oct 2013 13:37:34 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 27 Oct 2013 13:37:34 +0000 (UTC) To: "Rainbows! list" Original-X-From: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Sun Oct 27 14:37:35 2013 Return-path: Envelope-to: gclrrg-rainbows-talk@m.gmane.org X-Original-To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Delivered-To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=D6i4Nijx5mr2abV3d7Jn+6zwkLrVMnea4XRp2Kqj6Rg=; b=MemaTkTf0FfNQfnlVcxHU76TfMcdMawU271tCMo5svEUYVkzDmgZ74LJElkBQZ0L85 POeyXQXXKB0sZuSo0GB80beVPOKx9+tRo4hvJsmY/weAWVIV4o+DE7yRkrEAzeTiLBZE GHsbVFIt8KUCA3J9c9dIz4E9O1WsvLuwsoyBpWcdyqE8SZsgKFhju2SsSMJ3erOTwu/x itNmzLAUWejF0h+40IGKbnnSL+9zwjSp7NMTG19emMsSzc5KBWowar/ReMYeB8SeDnLb HS1rU6nS8x6ejKt99PdeMniw+O4CcUrWfAXlKlYjmOZAquY/MugNft0xUYFgZxCKQrrD xJ0A== X-Gm-Message-State: ALoCoQk/u48y1KyUOB5dwruCVBIyBFpOcg3SlnRi3x21ffH7H9rvkQiaSvilL+nI6BS0CjPfbYhS X-Received: by 10.236.176.231 with SMTP id b67mr11754431yhm.54.1382880953628; Sun, 27 Oct 2013 06:35:53 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130911 Thunderbird/17.0.9 In-Reply-To: <20131022160930.GA3020-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org> X-BeenThere: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Errors-To: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org X-Broken-Reverse-DNS: no host name found for IP address 50.56.192.79 Xref: news.gmane.org gmane.comp.lang.ruby.rainbows.general:565 Archived-At: Received: from [50.56.192.79] (helo=rubyforge.org) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VaQX6-0000BX-HA for gclrrg-rainbows-talk@m.gmane.org; Sun, 27 Oct 2013 14:37:32 +0100 Received: from localhost.localdomain (localhost [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id B2AAB2E1CC; Sun, 27 Oct 2013 13:37:31 +0000 (UTC) Received: from mail-gg0-f181.google.com (mail-gg0-f181.google.com [209.85.161.181]) by rubyforge.org (Postfix) with ESMTP id 598AB2E17D for ; Sun, 27 Oct 2013 13:35:54 +0000 (UTC) Received: by mail-gg0-f181.google.com with SMTP id h1so973047gga.12 for ; Sun, 27 Oct 2013 06:35:53 -0700 (PDT) Received: from [192.168.1.2] ([177.158.66.39]) by mx.google.com with ESMTPSA id m68sm25766209yhj.22.2013.10.27.06.35.52 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 27 Oct 2013 06:35:53 -0700 (PDT) Hello Eric, I discovered that when you restart the server (linux 2.3.50, glibc 2.15) memory stopped growing indiscriminately. 2 questions: 1) The POOL_SIZE XEpollThreadPool series of the number of connections accepted epoll so'd have one for each thread 2) I saw the gem 'mall' and she seems to adjust as you indicted by glibc environment variables are correct? If yes in config / initializers added a file.rb with the following: Mall.opt (Mall :: ARENA_MAX, 1) Mall.opt (Mall :: ARENA_TEST, 1) Tanks, Alexandre Riveira On 22-10-2013 16:09, Eric Wong wrote: > Alexandre Riveira wrote: >> I usually use XEpollThreadPool however persebi a large memory usage >> for sites that have a lot of content and access reaching over 1 GB. >> Changed to ThreadPool and memory fell not from 4x 256MB. However >> XEpollThreadPool is faster than ThreadPool. Accepted suggestions for >> configuration. I tested also with CoolioThreadPool speed was good >> but the memory consumption and large too. > Wait, ThreadPool uses significantly less than XEpollThreadPool? > > Since this is likely glibc/eglibc, try setting MALLOC_ARENA_MAX=1 and > MALLOC_ARENA_TEST=1 in the env before starting Rainbows! AFAIK, these > are mainly documented by Red Hat, but in all recent-ish versions of > glibc/eglibc support it. > > Then increase the values if you see performance gains (unlikely unless > your app releases the GVL a lot or don't have one (rbx)). > _______________________________________________ > Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org > http://rubyforge.org/mailman/listinfo/rainbows-talk > Do not quote signatures (like this one) or top post when replying > _______________________________________________ Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org http://rubyforge.org/mailman/listinfo/rainbows-talk Do not quote signatures (like this one) or top post when replying