couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James Marca <>
Subject Re: couchdb on smp?
Date Fri, 08 May 2009 17:47:18 GMT

I too am running couchdb-0.9 on erlang 13.2

I am running Gentoo.  My use flags for erlang are:

USE="emacs java kpoll sctp smp ssl -doc -hipe -odbc -tk -wxwindows

I didn't turn on high performance erlang because the ebuild said "your
on your own if you do"  But I turned on lots of other flags that
looked like it would help erlang use all 8 cores on my server (dual
4-core Intel Xeon CPU  E5420  @ 2.50GHz)

So, I have 12 databases (one per month) for storing some data, each
about gig or so large.  I set up an identical view in each all at the
same time and erlang + couch did a good job using my CPU---using top
(press 1 to see all cpus), all 8 cpus were under load, with loads
ranging from 49 to 61, and the main beam.smp process was running at
340% CPU (obviously spreading its load across the cores).

So if you're not seeing CPUs getting used, try recompiling erlang and
turning on smp support, etc.  Oh, and I also had to recompile CouchDB
after upgrading erlang with smp kpoll and sctp.  

James Marca

On Mon, May 04, 2009 at 02:50:26PM +0300, Elf wrote:
> Hello.
> I'm using couchdb-0.9 (erlang 13.2) on my linux server with 4 CPUs
> (Core 2 Quad).
> Every time couchdb needs to reindex views, i see 2 serious processes
> in htop - beam and couchjs. Each of them eats < 100% of 1 cpu, and sum
> of their usage is about (but not greater) 100% of 1 cpu (80/20, 70/30
> and so on).
> Can somebody explain, why that 2 different processes (they have
> differend PIDs) doesn't used different cpus - (one process for cpu)?
> -- 
> ----------------
> Best regards
> Elf

This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

View raw message