Re: Curious run-away index build on upgrade to 8.1.3 - Mailing list pgsql-admin

From Jerry Sievers
Subject Re: Curious run-away index build on upgrade to 8.1.3
Date
Msg-id m3irqekpy9.fsf@prod01.jerrysievers.com
Whole thread Raw
In response to Curious run-away index build on upgrade to 8.1.3  (Jerry Sievers <jerry@jerrysievers.com>)
List pgsql-admin
Well, I'll be dipped!  More below;

Tom Lane <tgl@sss.pgh.pa.us> writes:

> On further analysis, it seems the problem is dependent on the exact
> ordering of the inputs to the qsort function.  So not only do you need
> maintenance_work_mem to be large enough that the code will try to use
> qsort, but the physical order of the rows in the table matters.
> I suspect that you are testing on an 8.0 table with a different physical
> row order --- if you drop the table and reload it from the same dump you
> loaded into 8.1, does it get slow?

Tom, your theory is correct.  If we had to build that index from
scratch on 8.0, with the data ordered as it was when I made the
original dump, it would have stalled all the same.

I just reproduced this on an 8.0.3 box.

FYI

--
-------------------------------------------------------------------------------
Jerry Sievers   305 854-3001 (home)     WWW ECommerce Consultant
                305 321-1144 (mobile    http://www.JerrySievers.com/

pgsql-admin by date:

Previous
From: Tom Lane
Date:
Subject: Re: Curious run-away index build on upgrade to 8.1.3
Next
From: "Kevin Grittner"
Date:
Subject: Re: reg:FilePath error