Skip site navigation (1) Skip section navigation (2)

Re: Optimizing PostgreSQL for Windows

From: "Christian Rengstl" <Christian(dot)Rengstl(at)klinik(dot)uni-regensburg(dot)de>
To: "Guillaume Lelarge" <guillaume(at)lelarge(dot)info>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Optimizing PostgreSQL for Windows
Date: 2007-10-31 08:43:57
Message-ID: 47284B8A.90AD.0080.0@klinik.uni-regensburg.de (view raw or flat)
Thread:
Lists: pgsql-performance
Now the execution time for my query is down to ~10 - 13 seconds, which
is already a big step ahead. Thanks!
Are there any other settings that might be necessary to tweak on
windows in order to reduce execution time even a little bit more?
One thing i don't understand very well though is that if I execute the
query on table 1 with some conditions for the first time it is still
slow, but when i execute it more often with changing the conditions it
gets faster. Even when i query table 1 then query table 3 (with the same
table definition) and then query table 1 again, the query on table 1
gets faster again.


Christian Rengstl M.A.
Klinik und Poliklinik für Innere Medizin II
Kardiologie - Forschung
Universitätsklinikum Regensburg
B3 1.388
Franz-Josef-Strauss-Allee 11
93053 Regensburg
Tel.: +49-941-944-7230




>>> On Tue, Oct 30, 2007 at  8:21 PM, in message
<47278421(dot)6010906(at)lelarge(dot)info>,
Guillaume Lelarge <guillaume(at)lelarge(dot)info> wrote: 
> Christian Rengstl a écrit :
>> My OS is Windows 2003 with 4GB Ram and Xeon Duo with 3.2 GHz;
>> shared_buffers is set to 32MB (as I read it should be fairly low on
>> Windows) and work_mem is set to 2500MB, but nevertheless the query
takes
>> about 38 seconds to finish. The table "table1" contains approx. 3
>> million tuples and table2 approx. 500.000 tuples. If anyone could
give
>> an advice on either how to optimize the settings in postgresql.conf
or
>> anything else to make this query run faster, I really would
appreciate.
>> 
> 
> 32MB for shared_buffers seems really low to me but 2500MB for
work_mem
> seems awfully high. The highest I've seen for work_mem was something
> like 128MB. I think the first thing you have to do is to really
lower
> work_mem. Something like 64MB seems a better bet at first.
> 
> Regards.
> 
> 
> -- 
> Guillaume.
>  http://www.postgresqlfr.org
>  http://dalibo.com


In response to

pgsql-performance by date

Next:From: clusterDate: 2007-10-31 09:37:24
Subject: Re: Two fast queries get slow when combined
Previous:From: Tom LaneDate: 2007-10-31 04:05:42
Subject: Re: Two fast queries get slow when combined

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group