Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 2352F9F9CB1 for ; Sun, 23 Sep 2007 16:24:17 -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 86263-03 for ; Sun, 23 Sep 2007 16:24:10 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from rv-out-0910.google.com (rv-out-0910.google.com [209.85.198.186]) by postgresql.org (Postfix) with ESMTP id 72E039F9940 for ; Sun, 23 Sep 2007 16:24:12 -0300 (ADT) Received: by rv-out-0910.google.com with SMTP id l15so1095382rvb for ; Sun, 23 Sep 2007 12:24:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=ywyEAVKYeWfU8R5pSfGD7rLqy1jAQmbE6OkemEBNliM=; b=pWxwMZiayqajmFr30AfhN2j+uoNpj6jKxIL8UQ7gL7muBl8kUF/waOmTHJlxO6s1nG3T+Zda30pZaX+MYTqt8I+2FRleuEpbd8cPyUCNTgnO5AaPPD+eRYgyKM+pOa1q/p+EIRGPagkb6FnHa+OQDX7Gp/FSnQ2e6BqFTWW96hg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=o9p8a/Gc08PDgOxdm4UL2yjYYexPnO6lJmmyVlRUfCeP3inBgTcFH7ejhh/pxSFcPTGa2jEpjgUbmZfHmNE0MMBsiD0yU+qmTzXqwiAlhGAz3rtwUaEA0E1QcHHVt3y0R4Rn2+sWHnJc4DHNpz5QWj7+mQ7v/25EaUepagULsB0= Received: by 10.142.229.4 with SMTP id b4mr1491927wfh.1190575451041; Sun, 23 Sep 2007 12:24:11 -0700 (PDT) Received: by 10.143.19.7 with HTTP; Sun, 23 Sep 2007 12:24:10 -0700 (PDT) Message-ID: <36e682920709231224y3fb13ce3t9dd4217215c62bf7@mail.gmail.com> Date: Sun, 23 Sep 2007 15:24:10 -0400 From: "Jonah H. Harris" To: "Carlos Moreno" Subject: Re: Possible explanations for catastrophic performace deterioration? Cc: pgsql-performance@postgresql.org In-Reply-To: <46F6BA82.3080101@mochima.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <46F6981B.1010600@mochima.com> <36e682920709230956p1312745eif1c6ba7a342dae3d@mail.gmail.com> <46F6AD2D.4090300@mochima.com> <20070923182349.GC5679@alvh.no-ip.org> <46F6BA82.3080101@mochima.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200709/405 X-Sequence-Number: 26950 On 9/23/07, Carlos Moreno wrote: > Wait a second --- am I correct in understanding then that the bloating > you guys are referring to occurs *in memory*?? No, bloating occurs on-disk; but this does affect memory. Bloat means that even though your table data may take up 1G after the initial load, due to poor vacuuming, table layouts, etc. it to equal something more... say 2G. The thing is, even though the table only stores 1G of data, it is now physically 2G. So, anything that would need to read the entire table (like COUNT(*)), or large sections of it sequentially, are performing twice as many I/Os to do so. Which means you're actually waiting on two things, I/O and additional CPU time reading blocks that have very little viable data in them. -- Jonah H. Harris, Sr. Software Architect | phone: 732.331.1324 EnterpriseDB Corporation | fax: 732.331.1301 499 Thornall Street, 2nd Floor | jonah.harris@enterprisedb.com Edison, NJ 08837 | http://www.enterprisedb.com/