Re: strange index performance? - Mailing list pgsql-performance

From Scott Marlowe
Subject Re: strange index performance?
Date
Msg-id dcc563d10901251412h26042bb4r3723f67ee2def0b5@mail.gmail.com
Whole thread Raw
In response to Re: strange index performance?  (Thomas Finneid <tfinneid@fcon.no>)
Responses Re: strange index performance?  (Thomas Finneid <tfinneid@fcon.no>)
List pgsql-performance
On Sun, Jan 25, 2009 at 2:54 PM, Thomas Finneid <tfinneid@fcon.no> wrote:
> Scott Marlowe wrote:
>>
>> On Sun, Jan 25, 2009 at 1:14 AM, Thomas Finneid <tfinneid@fcon.no> wrote:
>>>
>>> Scott Marlowe wrote:
>>>>
>>>> So I don't think you've found the cause of your problem with the smaller
>>>> index.
>
> Ok I understand, but why dont you think the index is the problem?

Because on any decent hardware you should be able to insert a single
row in way under 200ms.  Whether it's got an index on it or not.

>> I thought it was the other way around for you, that the smaller index
>> was slower.
>
> Sorry for the mistake, I meant to say the smaller index causes the slowest
> insert time.

I'm guessing that you just had more data in the table or something by
the time you tested that, or some cron job was running in the
background, or some other issue, not the index.

>> What version pgsql are you running?  My tests were on 8.3.x on a
>
> I am running on pg 8.2.x (kubuntu x64) with 8GB ram, 8 opteron cores and 8
> disks on a Areca Raid controller

Quite a similar machine.  write back cache with battery backed
controller on the controller?  A really old Areca like an 11xx series
or a newer one 12xx, 16xx?

>> 0.12 ms per insert with all 10,000 inserted in a transaction
>> 0.24 ms per insert with each insert being individual transactions
>> (i.e. no begin; commt; wrapped around them all)  This is on a machine
>> with a 12 disk RAID-10 array under an Areca 1680ix controller with
>> 512M battery backed cache.  Note that the table had no other columns
>> in it like yours does.
>
> Are you sure you mean to say 0.12 ms and not 0.12 seconds? My server also

0.12 seconds per insert is pretty slow.  10 inserts would take a
second.  I'm inserting 10,000 rows in about 2 seconds.  Each insert is
definitely in the 0.12 millisecond range.

> uses an Areca RAID controller (8 disk controller model), but it does not
> matter how many disks are in the stripe, its still the same performance. So,
> if you get that performance then I have must have set up postgres, the OS or
> the RAID controller wrong.  What are the most important configurations you
> did to get that performance?

Hard to say.  What does bonnie++ have to say about the performance of
your RAID array?

pgsql-performance by date:

Previous
From: "M. Edward (Ed) Borasky"
Date:
Subject: Re: postgresql 8.3 tps rate
Next
From: Thomas Finneid
Date:
Subject: Re: strange index performance?