Re: Help with count(*)

From: Christopher Browne <cbbrowne(at)acm(dot)org>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: Help with count(*)
Date: 2003-11-14 14:13:48
Message-ID: m3ad6zkpgj.fsf@wolfe.cbbrowne.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-performance

Martha Stewart called it a Good Thing when mallah(at)trade-india(dot)com (Rajesh Kumar Mallah) wrote:
> INFO: "profiles": found 0 removable, 369195 nonremovable row versions in 43423 pages
> DETAIL: 246130 dead row versions cannot be removed yet.
> Nonremovable row versions range from 136 to 2036 bytes long.

It seems as though you have a transaction open that is holding onto a
whole lot of old rows.

I have seen this happen somewhat-invisibly when a JDBC connection
manager opens transactions for each connection, and then no processing
happens to use those connections for a long time. The open
transactions prevent vacuums from doing any good...
--
If this was helpful, <http://svcs.affero.net/rm.php?r=cbbrowne> rate me
http://cbbrowne.com/info/multiplexor.html
"Waving away a cloud of smoke, I look up, and am blinded by a bright,
white light. It's God. No, not Richard Stallman, or Linus Torvalds,
but God. In a booming voice, He says: "THIS IS A SIGN. USE LINUX, THE
FREE Unix SYSTEM FOR THE 386." -- Matt Welsh

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2003-11-14 14:17:32 Re: ALTER TABLE modifications
Previous Message Dave Cramer 2003-11-14 13:59:05 Re: ALTER TABLE modifications

Browse pgsql-performance by date

  From Date Subject
Next Message SZŰCS Gábor 2003-11-14 15:08:27 constant vs function param differs in performance
Previous Message Jeff 2003-11-14 13:37:55 Re: INSERT extremely slow with large data sets (fwd)