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 9B42611CAE for ; Tue, 22 Apr 2014 16:57:03 +0000 (UTC) Received: (qmail 14750 invoked by uid 500); 22 Apr 2014 16:57:01 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 14624 invoked by uid 500); 22 Apr 2014 16:57:01 -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 14616 invoked by uid 99); 22 Apr 2014 16:57:01 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Apr 2014 16:57:01 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of vladimir.ralev@gmail.com designates 209.85.219.51 as permitted sender) Received: from [209.85.219.51] (HELO mail-oa0-f51.google.com) (209.85.219.51) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Apr 2014 16:56:56 +0000 Received: by mail-oa0-f51.google.com with SMTP id i4so5953265oah.38 for ; Tue, 22 Apr 2014 09:56:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=r0YXd4nrrDMgJPd6EG9DuiyAVI6s2dE+Uhtwu28TDvE=; b=wPXGhXmrLuH94pa5GK28GLUrmxoAS9o8S1T49XmpA480H3GdqAHwfr6c1SJfU2raCn IYwrK3pnsJsWJAiqX4q3ijDprTOmfTgPnb8F0GKVoNU93HkmJAJjA/c3HFWCX2BQMspe m6sWMVaIMP/JIw15ZK9YQLQyzdrZ+UNySaOSZCu21MzHnsPtghcPDT+Vh9FsbPu7m+Wz U4sdHINbdcGheFaZe+5KSqe95Q586PCQyCtpTFv5ZD08aKFyYDBKA0xOFv6crdqFrQYa 7Ue52DAPhPKHg9UN2JnSIBS6H+7MDMNacXaMkbHcO5tn5Dn6379N4aYTIdlnTq3my/4R Y55A== X-Received: by 10.182.60.4 with SMTP id d4mr10913541obr.4.1398185795412; Tue, 22 Apr 2014 09:56:35 -0700 (PDT) MIME-Version: 1.0 Received: by 10.60.16.166 with HTTP; Tue, 22 Apr 2014 09:56:15 -0700 (PDT) In-Reply-To: <9DC1F9A5-F8BE-4442-8C3F-FED46556CB57@eileo.com> References: <9DC1F9A5-F8BE-4442-8C3F-FED46556CB57@eileo.com> From: Vladimir Ralev Date: Tue, 22 Apr 2014 19:56:15 +0300 Message-ID: Subject: Re: Issues with terabytes databases To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=089e0158ac86aa685104f7a47f2f X-Virus-Checked: Checked by ClamAV on apache.org --089e0158ac86aa685104f7a47f2f Content-Type: text/plain; charset=UTF-8 Hi very interesting case, are you sure you are not exceeding the write capacity of the RAID, few MBs per second is actually enough to starve a lot of the older HDDs, remember they have to reposition themselves for almost every write when load is concurrent and out of context, essentially random access writes on sequential media. This effect is amplified if you are partitioning your databases. What errors do you get when you go above the capacity? Do you see error lines in the log? How is the IOwait? Are you running with debug logs enabled? Do you monitor your couchjs workers and the system limits? I think your compaction problem can be solved by BigCouch since it tries to split the databases into smaller partitions, but splitting the data into separate databases manually is still common. On Tue, Apr 22, 2014 at 5:09 PM, Jean-Yves Moulin < jean-yves.moulin@eileo.com> wrote: > Hi everybody, > > we use CouchDB in production for more than two years now. And we are > almost happy with it :-) We have a heavy writing workload, with very few > update, and we never delete data. Some of our databases are terabytes with > billions of documents (sometimes 20 millions of doc per day). But we are > experiencing some issues, and the only solution was to split our data: > today we create a new database each week, with even and odd on two > different servers (thus we have on-line and off-line servers). This is not > perfect, and we look forward BigCouch :-) > > Below is some of our current problems with these big databases. For the > record, we use couchdb-1.2 and couchdb-1.4 on twelve servers running > FreeBSD (because we like ZFS). > > I don't know if these issues are known or not (or specific to us). > > * Overall speed: we are far from our real server performance: it seems > that CouchDB is not able to use the full potential of the system. Even with > 24 disks in RAID10, we can't go faster that 2000 doc/sec (with an average > document size of 1k, that's only a few MB/s on disk) on replication or > compaction. CPU and disk are almost idle. Tweaking the number of Erlang I/O > thread doesn't help. > > * Insert time: At 1000 PUT/sec the insert time is good, even without bulk. > But it collapses when launching view calculation, replication or > compaction. So, we use stale view in our applications and views are > processed regularly by a crontab scripts. We avoid compaction on live > servers. Compaction are launched manually on off-line servers only. We also > avoid replication on heavy loaded servers. > > * Compaction: When size of database increase, compaction time can be > really really long. It will be great if compaction process can run faster > on already compressed doc. This is our biggest drawback, which implies the > database split each week. And the speed decreases slowly: compaction starts > fast (>2000 doc/sec) but slow down to ~100 doc/sec after hundred of > millions of documents. > > Is there other people using CouchDB this kind of database ? How do you > handle a write-heavy workload ? > > Sorry for my english and thank you for the reading. > > Best, > > --089e0158ac86aa685104f7a47f2f--