Re: BUG #5491: Queries performing slowly - Mailing list pgsql-bugs

From Craig Ringer
Subject Re: BUG #5491: Queries performing slowly
Date
Msg-id 4C0DA605.5040206@postnewspapers.com.au
Whole thread Raw
In response to BUG #5491: Queries performing slowly  ("Piergiorgio Buongiovanni" <piergiorgio.buongiovanni@netspa.it>)
List pgsql-bugs
On 7/06/2010 11:34 PM, Piergiorgio Buongiovanni wrote:
>
> The following bug has been logged online:
>
> Bug reference:      5491
> Logged by:          Piergiorgio Buongiovanni
> Email address:      piergiorgio.buongiovanni@netspa.it
> PostgreSQL version: 8.4.3
> Operating system:   x86_64-redhat-linux-gnu
> Description:        Queries performing slowly
> Details:
>
> Hereby our production environment:
>
> PostgreSQL 8.4.3 on x86_64-redhat-linux-gnu, compiled by GCC gcc (GCC) 4.1.2
> 20080704 (Red Hat 4.1.2-46), 64-bit
>
> The problem we have is simply queries perform very slowly. I simply ask the
> DB SELECT * FROM business.Subject and the response time is 640555ms for 86
> rows extracted. It's unbelievable!

Is business.subject a view? See:
http://wiki.postgresql.org/wiki/SlowQueryQuestions

What's the EXPLAIN ANALYZE result from that query?
See: http://wiki.postgresql.org/wiki/Using_EXPLAIN

Do you VACUUM regularly / is autovacuum enabled?
See:  http://www.postgresql.org/docs/8.3/interactive/routine-vacuuming.html
See:
http://wiki.postgresql.org/wiki/Introduction_to_VACUUM%2C_ANALYZE%2C_EXPLAIN%2C_and_COUNT

--
Craig Ringer

pgsql-bugs by date:

Previous
From: Greg Stark
Date:
Subject: Re: BUG #5492: Query performs slowly and sequence corrupted
Next
From: Florian Weimer
Date:
Subject: Re: [HACKERS] Invalid YAML output from EXPLAIN