Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 71BA69F94F7 for ; Thu, 6 Sep 2007 08:37:36 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 07423-01-2 for ; Thu, 6 Sep 2007 08:37:23 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from ctb-mesg8.saix.net (ctb-mesg8.saix.net [196.25.240.78]) by postgresql.org (Postfix) with ESMTP id 7F22E9F94A1 for ; Thu, 6 Sep 2007 08:37:32 -0300 (ADT) Received: from mirasol.co.za (dsl-240-132-190.telkomadsl.co.za [41.240.132.190]) by ctb-mesg8.saix.net (Postfix) with SMTP id 4B56A2C49 for ; Thu, 6 Sep 2007 13:37:26 +0200 (SAST) Received: (qmail 2572 invoked by uid 453); 6 Sep 2007 11:37:25 -0000 X-Virus-Checked: Checked by ClamAV on mirasol.co.za Received: from pc-00052.mirasol.co.za (HELO [172.16.0.52]) (172.16.0.52) by mirasol.co.za (qpsmtpd/0.40) with ESMTP; Thu, 06 Sep 2007 07:37:25 -0400 Message-ID: <46DFE674.6060702@mirasol.co.za> Date: Thu, 06 Sep 2007 13:37:24 +0200 From: Willo van der Merwe User-Agent: Thunderbird 2.0.0.0 (X11/20070326) MIME-Version: 1.0 To: Jean-David Beyer CC: pgsql-performance@postgresql.org Subject: Re: Hardware spec References: <46DFA43C.2030201@mirasol.co.za> <46DFB79E.9040407@archonet.com> <46DFC7D6.2080803@mirasol.co.za> <46DFE170.20206@verizon.net> In-Reply-To: <46DFE170.20206@verizon.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200709/76 X-Sequence-Number: 26621 Jean-David Beyer wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Willo van der Merwe wrote: > >> Richard Huxton wrote: >> >>> Willo van der Merwe wrote: >>> >>>> Hi guys, >>>> >>>> I'm have the rare opportunity to spec the hardware for a new database >>>> server. It's going to replace an older one, driving a social >>>> networking web application. The current server (a quad opteron with >>>> 4Gb of RAM and 80Gb fast SCSI RAID10) is coping with an average load >>>> of ranging between 1.5 and 3.5. >>>> >>>> The new machine spec I have so far: >>>> >>> What's the limiting factor on your current machine - disk, memory, >>> cpup? >>> >> I'm a bit embarrassed to admit that I'm not sure. The reason we're >> changing machines is that we might be changing ISPs and we're renting / >> leasing the machines from the ISP. >> >> > Before you get rid of the current ISP, better examine what is going on with > the present setup. It would be good to know if you are memory, processor, or > IO limited. That way you could increase what needs to be increased, and not > waste money where the bottleneck is not. > Good advice. After running a vmstat and iostat, it is clear, to my mind anyway, that the most likely bottleneck is IO, next is probably some more RAM. Here's the output: procs -----------memory---------- ---swap-- -----io---- --system-- ----cpu---- r b swpd free buff cache si so bi bo in cs us sy id wa 0 0 29688 80908 128308 3315792 0 0 8 63 6 8 17 2 80 1 avg-cpu: %user %nice %sys %iowait %idle 17.18 0.00 1.93 0.81 80.08 Device: tps Blk_read/s Blk_wrtn/s Blk_read Blk_wrtn sda 14.57 66.48 506.45 58557617 446072213 sda1 0.60 0.27 4.70 235122 4136128 sda2 0.38 0.77 2.27 678754 2002576 sda3 2.37 0.49 18.61 429171 16389960 sda4 0.00 0.00 0.00 2 0 sda5 0.71 0.66 5.46 578307 4807087 sda6 0.03 0.01 0.24 6300 214196 sda7 0.02 0.00 0.19 2622 165992 sda8 60.19 64.29 474.98 56626211 418356226