Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id 0E09A2E0033 for ; Tue, 10 Jun 2008 22:28:47 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 98628-05 for ; Tue, 10 Jun 2008 22:28:37 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by developer.postgresql.org (Postfix) with ESMTP id BF3E12E0032 for ; Tue, 10 Jun 2008 22:28:42 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id m5B1Sb2J027796; Tue, 10 Jun 2008 21:28:37 -0400 (EDT) To: Devendra Singh Rawat cc: "Joshua D. Drake" , "pgsql-admin@postgresql.org" Subject: Re: Disk Space issue In-reply-to: <4242E42288B6E842A52B88D4B3A3E620E0610625@AUSMELMBX01.ad.infosys.com> References: <484E61A0.5030706@kerkhove.net> <484E88AB.6020505@kerkhove.net> <4242E42288B6E842A52B88D4B3A3E620E0610550@AUSMELMBX01.ad.infosys.com> <1213142115.17340.213.camel@jd-laptop> <4242E42288B6E842A52B88D4B3A3E620E0610579@AUSMELMBX01.ad.infosys.com> <1213142730.17340.218.camel@jd-laptop> <4242E42288B6E842A52B88D4B3A3E620E0610625@AUSMELMBX01.ad.infosys.com> Comments: In-reply-to Devendra Singh Rawat message dated "Wed, 11 Jun 2008 11:08:14 +1000" Date: Tue, 10 Jun 2008 21:28:37 -0400 Message-ID: <27795.1213147717@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200806/92 X-Sequence-Number: 29430 Devendra Singh Rawat writes: > We ran the SQL to get the table which are consuming maximum space. > The results are as shown:- > SELECT relname, relpages FROM pg_class ORDER BY relpages DESC; > relname | relpages > --------------------------------------------------+---------- > | 52869 > | 31267 > | 15418 > | 9693 > | 6426 > But these only cover around few GB of data. pg_class.relpages is only up-to-date as of the last VACUUM. There's already good reason to suspect that you're not vacuuming enough; maybe some big tables are not getting vacuumed at all. I'd suggest having a look into the data directory to see for yourself which are the big files. The documentation might help you: http://www.postgresql.org/docs/8.3/static/storage.html (IIRC, all of this except the material on tablespaces will apply to 7.4.) regards, tom lane