pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Merlin Moncure <mmoncure@gmail.com>
To: femski <hypertree@yahoo.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Postgres batch write very slow - what to do
Date: Tue, 13 Mar 2007 07:40:49 -0500
Message-ID: <b42b73150703130540sf2a388ka2d5e5e4341d9272@mail.gmail.com> (raw)
In-Reply-To: <9452092.post@talk.nabble.com>
References: <9452092.post@talk.nabble.com>

On 3/13/07, femski <hypertree@yahoo.com> wrote:
>
> Folks !
>
> I have a batch application that writes approx. 4 million rows into a narrow
> table. I am using JDBC addBatch/ExecuteBatch with auto commit turned off.
> Batch size is 100. So far I am seeing Postgres take roughly five times the
> time it takes to do this in the Oracle.
>
> I have played with many parameters. Only one that seems to have any affect
> is fsync - but thats only 10% or so.
> Initially I got the warning that checkpoints were happening too often so I
> increased the segments to 24. Warnings stopped, but no real improvement in
> performance.
>
> Is postgres really that slow ? What am I missing ?

how many inserts/sec are you getting approximately.  Maybe you have
some type of network issue.

merlin



view thread (20+ messages)  latest in thread

Message-ID: <b42b73150703130540sf2a388ka2d5e5e4341d9272@mail.gmail.com>
Permalink:  ../b42b73150703130540sf2a388ka2d5e5e4341d9272@mail.gmail.com/
Also on:    postgresql.org/message-id/b42b73150703130540sf2a388ka2d5e5e4341d9272@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: mmoncure@gmail.com, hypertree@yahoo.com
  Subject: Re: Postgres batch write very slow - what to do
  In-Reply-To: <b42b73150703130540sf2a388ka2d5e5e4341d9272@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox