Re: Postgres batch write very slow - what to do - Mailing list pgsql-performance

From Merlin Moncure
Subject Re: Postgres batch write very slow - what to do
Date
Msg-id b42b73150703160548t683ee4eckc3b05275e000b02b@mail.gmail.com
Whole thread Raw
In response to Re: Postgres batch write very slow - what to do  (femski <hypertree@yahoo.com>)
Responses Re: Postgres batch write very slow - what to do  ("Merlin Moncure" <mmoncure@gmail.com>)
List pgsql-performance
On 3/15/07, femski <hypertree@yahoo.com> wrote:
>
> I tried maxpages = 0 and  full_page_writes=off and it seemed to be taking
> forever.
> All other tricks I have already tried.
>
> At this point I wondering if its a jdbc client side issue - I am using the
> latest 8.1.
> (as I said in an earlier post - I am using addBatch with batch size of 100).
> But just in case - I am missing something.
>
> If 17k record/sec is right around expected then I must say I am little
> disappointed from the "most advanced open source database".

Be careful...you are just testing one very specific thing and it its
extremely possible that the Oracle JDBC batch insert is more optimized
than PostgreSQL's.  On my little pentium 4 workstation, by inserting
10 rows per insert:
insert values ([...]), ([...]), [8 more rows];

I got a 5x speedup in insert performance using this feature (which is
unfortunately new for 8.2).  Oracle is most likely pulling similar
tricks inside the driver.  PostgreSQL is much faster than you think...

merlin

pgsql-performance by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: Determine dead tuples size
Next
From: "Merlin Moncure"
Date:
Subject: Re: Postgres batch write very slow - what to do