Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E251C1757C for ; Mon, 12 Jan 2015 00:14:27 +0000 (UTC) Received: (qmail 13626 invoked by uid 500); 12 Jan 2015 00:14:28 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 13558 invoked by uid 500); 12 Jan 2015 00:14:28 -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 13546 invoked by uid 99); 12 Jan 2015 00:14:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2015 00:14:27 +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 kxepal@gmail.com designates 74.125.82.42 as permitted sender) Received: from [74.125.82.42] (HELO mail-wg0-f42.google.com) (74.125.82.42) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Jan 2015 00:14:01 +0000 Received: by mail-wg0-f42.google.com with SMTP id k14so16652558wgh.1 for ; Sun, 11 Jan 2015 16:13:15 -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:content-transfer-encoding; bh=TNhUOQvs9NQAwtTeywG8IKgEuavBTaUJqOdLQ+k2EPk=; b=Igkpi7RgRcpXNKJUUGGs5hi7vu28KNIZ7NUG+i0ZoSBnGyAG2TQWaQIao2Lrvp3DSn Wl+Ibcv6oekDC5XRjJxUyKjSzyiHadxgWyzRQSryYEZZzACn8Bf2BMbRo+q9qaZt+nBT Oxl/x6fDrQuPSJ5TIbW4AX1C+9yeS9SaEQBYXstUvS1HTBmmDyr8o3To7lww/SXw2ipw KDY9+A4xZ8PDQyYYGotkH8YYijTnY2Y2vn72N0uvY5emS/YgI/8D8fo459Kky/n67eFp xrVmcM1dFQqQQSQxvENt1RZd3AefV6J8BBlex93FvED6aHJGXr596ly7ncvUO7IRp5/z x1PA== MIME-Version: 1.0 X-Received: by 10.180.78.73 with SMTP id z9mr25077162wiw.52.1421021595858; Sun, 11 Jan 2015 16:13:15 -0800 (PST) Received: by 10.180.82.101 with HTTP; Sun, 11 Jan 2015 16:13:15 -0800 (PST) In-Reply-To: References: <6B60BAE7-4014-43F8-AD07-5ED9A1EBBB92@gmail.com> Date: Mon, 12 Jan 2015 04:13:15 +0400 Message-ID: Subject: Re: Tweaking CouchDB For DB-Per-User From: Alexander Shorin To: "user@couchdb.apache.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org CouchDB automatically closes unused file handlers. However, for 1000 active databases it's hard to not hit the default 1024 limit. You can setup monitoring for couchdb/open_os_files and send you alert when it's getting close to the deadline. -- ,,,^..^,,, On Mon, Jan 12, 2015 at 3:07 AM, Paul Okstad wrote: > BTW, is there a better strategy to this instead of brute forcing the limi= t to be larger? It seems to be a bad idea to keep over 1000 files open if I= don=E2=80=99t even need to replicate them until a change occurs. It this a= limitation of internal continuous replication? Should I be triggering one = time replications using the database update notifications? > >> On Jan 11, 2015, at 3:44 PM, Paul Okstad wrote: >> >> Thank you for the quick reply. I am indeed using Ubuntu and indeed using= SSL so this is extremely relevant. I=E2=80=99ll try out the fixes and get = back. >> >>> On Jan 11, 2015, at 3:35 PM, Alexander Shorin wrote: >>> >>> On Mon, Jan 12, 2015 at 2:24 AM, Paul Okstad wrote: >>>> {error,emfile} >>> >>> emfile - too many open files. For thousand databases you might likely >>> hit default ulimit for 1024 file handlers. >>> See also this thread: >>> http://erlang.org/pipermail/erlang-questions/2015-January/082446.html >>> about other ways to solve this. For instance, on Ubuntu with upstart >>> there is a bit different way to set process limits. >>> >>> -- >>> ,,,^..^,,, >> >