From: Tom Lane <tgl@sss.pgh.pa.us>
To: Albe Laurenz <laurenz.albe@wien.gv.at>
Cc: 'Phil S *EXTERN*' <pjsanders@gmail.com>
Cc: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: Re: High Planning Time
Date: Fri, 22 Jan 2016 09:35:01 -0500
Message-ID: <403.1453473301@sss.pgh.pa.us> (raw)
In-Reply-To: <A737B7A37273E048B164557ADEF4A58B537D51D9@ntex2010i.host.magwien.gv.at>
References: <CAKpy=ySCyhNUzbKjSpk649R6xpeAU+Vx9dHc1uJ6pLVA_MStaA@mail.gmail.com>
<A737B7A37273E048B164557ADEF4A58B537D51D9@ntex2010i.host.magwien.gv.at>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>
Albe Laurenz <laurenz.albe@wien.gv.at> writes:
> Phil S wrote:
>> explain analyze
>> select * from message
>> limit 1
>>
>> "Limit (cost=0.00..0.44 rows=1 width=1517) (actual time=0.009..0.009 rows=1 loops=1)"
>> " -> Seq Scan on message (cost=0.00..28205.48 rows=64448 width=1517) (actual time=0.007..0.007
>> rows=1 loops=1)"
>> "Planning time: 3667.361 ms"
>> "Execution time: 1.652 ms"
>>
>> As you can see the query is simple and does not justify 3 seconds of planning time. It would appear
>> that there is an issue with my configuration but I am not able to find anything that looks out of
>> sorts in the query planning configuration variables. Any advice about what I should be looking for to
>> fix this would be appreciated.
> This is odd.
> Could you profile the backend during such a statement to see where the time is spent?
I'm wondering about locks. Perhaps turning on log_lock_waits would
yield useful info.
regards, tom lane
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tgl@sss.pgh.pa.us, laurenz.albe@wien.gv.at, pjsanders@gmail.com
Subject: Re: High Planning Time
In-Reply-To: <403.1453473301@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox