Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 84372 invoked from network); 7 Sep 2009 04:19:19 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 7 Sep 2009 04:19:19 -0000 Received: (qmail 10338 invoked by uid 500); 7 Sep 2009 04:19:18 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 10244 invoked by uid 500); 7 Sep 2009 04:19:18 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 10234 invoked by uid 99); 7 Sep 2009 04:19:18 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Sep 2009 04:19:18 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of paul.joseph.davis@gmail.com designates 209.85.132.245 as permitted sender) Received: from [209.85.132.245] (HELO an-out-0708.google.com) (209.85.132.245) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 07 Sep 2009 04:19:07 +0000 Received: by an-out-0708.google.com with SMTP id b2so888226ana.5 for ; Sun, 06 Sep 2009 21:18:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=nQeBmPMQ/hXJWAnUeZEzLDnwWUVx72OwVBI5HSg0itU=; b=uc6SqaOswp6qdi5xxmCIYIIuJz8nYdMDvG6UDmYer+2RRYtZysKNUNinML5Qbm+HmJ 8n/pqcwxxnSr2n7MAw64TBEmx31+ZaQ9gJVLQf+ApC5Xc4QK4om1MSgofzWF1t99sJYN 8xoGYnl4ikPzgSaN8PiQMiKafAZeQz0DzeZZU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=D0Zo3WlxCrXW+4snxrRZqkNcaBbh5Gh53Daigmsk3J5vMFnt0/bFI3StHr5PVZ622/ 8L2zL2YYt+fRX7JNdUJAR9/EOjCZ2daSh/4VsiAw/4aOtmrN8Yfk4HVIoIT0SjPReruj rrW2GO6xiOErmRLSTF1Jvldws4cGawLQNEHNo= MIME-Version: 1.0 Received: by 10.100.239.2 with SMTP id m2mr14931290anh.20.1252297126141; Sun, 06 Sep 2009 21:18:46 -0700 (PDT) In-Reply-To: References: Date: Mon, 7 Sep 2009 00:18:46 -0400 Message-ID: Subject: Re: Multiple couchjs processes being spawned From: Paul Davis To: user@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org Another random thought, after your clients have been running a bit, an easy way to check why type of stuff is going on with sockets is: $ netstat -ap tcp If your apps have periods of high turnover, check the sockets to see if you have lots of them in TIME_WAIT state. Paul On Sun, Sep 6, 2009 at 11:39 PM, Arun Thampi wrote: > Thanks Paul for the quick response. I'll poke around further to see if there > is anything amiss and will keep the list posted. > Cheers, > Arun > > On Mon, Sep 7, 2009 at 11:24 AM, Paul Davis wrote: > >> The algorithm for CouchDB's use of OS processes is pretty simple: >> >> "Give me an os process plz" >> >> If none are available, then it creates a new one. A large number of OS >> processes would suggest to me that something isn't releasing OS >> processes correctly. My first guess would be to look at _list and >> _show as those both require an OS process, but are also at the mercy >> of client connection semantics. I might be reaching a bit, but I >> wonder if CouchRest is failing to close sockets properly. Its not much >> more than a random finger pointing, but there have been other errors >> recently that also suggest CouchRest isn't doing proper socket >> handling. >> >> The other possibility is there's something weird with killing >> processes, but couchspawnkillable should've fixed that. >> >> HTH, >> Paul Davis >> >> On Sun, Sep 6, 2009 at 11:18 PM, Arun Thampi wrote: >> > Hi guys - Been running CouchDB trunk(r804727) in production for about 3 >> > weeks now and one thing I've noticed is that the number of couchjs >> processes >> > (/usr/local/lib/couchdb/bin/couchjs >> /usr/local/share/couchdb/server/main.js) >> > keeps increasing to a large amount. Is this normal? Does CouchDB manage >> > these processes and eventually kill inactive couchjs processes? >> > Just FYI I'm using CouchRest as part of a Rails app to query two >> different >> > views in my db. >> > >> > Thanks in advance. >> > >> > Cheers, >> > Arun >> > >> > -- >> > It's better to be a pirate than join the Navy - Steve Jobs >> > http://mclov.in >> > >> > > > > -- > It's better to be a pirate than join the Navy - Steve Jobs > http://mclov.in >