Re: Major performance problem after upgrade from 8.3 to 8.4 - Mailing list pgsql-performance

From Gerhard Wiesinger
Subject Re: Major performance problem after upgrade from 8.3 to 8.4
Date
Msg-id alpine.LFD.2.01.1009032129590.23544@bbs.intern
Whole thread Raw
In response to Re: Major performance problem after upgrade from 8.3 to 8.4  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Major performance problem after upgrade from 8.3 to 8.4
List pgsql-performance
On Fri, 3 Sep 2010, Tom Lane wrote:

> Gerhard Wiesinger <lists@wiesinger.com> writes:
>> On Fri, 3 Sep 2010, Tom Lane wrote:
>>> I think what may be happening here is that a postgres executable expects
>>> to find itself in a full installation tree, ie if it's in /someplace/bin
>>> then the timezone files are in /someplace/share, etc.  Did you do a full
>>> "make install" after building, or did you just copy the postgres
>>> executable?
>
>> I just copied it as discussed in the original mail to avoid that make
>> install kills the 8.4 production RPM version:
>> cp ./src/backend/postgres /bin/postgres-8.3.11
>
> Definitely not going to work.  Instead, configure with --prefix set
> to /someplace/harmless, make, make install, execute from
> /someplace/harmless/bin/.

Thanks tom, your support for PostgreSQL is really very, very good.
Install:
./configure --prefix /opt/postgres-8.3
make
make install
su -l postgres -c "/opt/postgres-8.3/bin/postgres -p 54321 -D /var/lib/pgsql-old/data &" >>
/var/lib/pgsql-old/pgstartup.log2>&1 < /dev/null 

Back to the original problem:
8.3 query plans: http://www.wiesinger.com/tmp/pg_perf_83_new.txt
8.4 quey plans: http://www.wiesinger.com/tmp/pg_perf_84.txt

Main difference as I saw:
8.3: ->  Nested Loop Left Join  (cost=0.00..1195433.19 rows=67 width=16)
8.4:   ->  Merge Left Join
(cost=1750660.22..4273805884876845789194861338991916289697885665127154313046252183850255795798561612107149662486528.00
rows=238233578115856634454073334945297075430094545596765511255148896328828230572227215727052643001958400width=16) 

Any ideas why? How to fix?

Thnx.

Ciao,
Gerhard

--
http://www.wiesinger.com/

pgsql-performance by date:

Previous
From: Tom Lane
Date:
Subject: Re: Major performance problem after upgrade from 8.3 to 8.4
Next
From: Tom Lane
Date:
Subject: Re: Major performance problem after upgrade from 8.3 to 8.4