Re: postmaster slowing down

From: "surabhi(dot)ahuja" <surabhi(dot)ahuja(at)iiitb(dot)ac(dot)in>
To: "Richard Huxton" <dev(at)archonet(dot)com>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: postmaster slowing down
Date: 2006-11-06 11:38:57
Message-ID: 8626C1B7EB748940BCDD7596134632BE3986A9@jal.iiitb.ac.in
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Answer to Question 1:

I forgot to mention this:
before i start running this program (refer to the mail below)
I clean up (rm -rf) and create the data directory (PGDATA, by doing initdb)
then i create the 4 tables (stored procedures etc)

and then run the program
Please see that I am not doing any deletes its just the inserts going on.
I guess I wont have to do a vacuum? Am i right.
I am not doing analyze currently, how frequently should I be doing it, I mean what factors should I consider to decide how frequently I should do it.

Answer to Question 2:

the program do not take any input .
When its slow how do i know if the cpu is slow or not?
(sorry i am asking again)

thanks,
regards
Surabhi

________________________________

From: Richard Huxton [mailto:dev(at)archonet(dot)com]
Sent: Mon 11/6/2006 4:20 PM
To: surabhi.ahuja
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] postmaster slowing down

surabhi.ahuja wrote:
> I am using postgres 8.0.0
> In my program I have a single connection to a database.
> in side this connection i do the following
>
> 1. begin transaction
> 2. insert rows to table/s. (max number of tables = 4)
> 3. commit transaction
>
> the above 3 steps take place around 800, 000 times
> does it mean that it will slow down.
>
> I have seen the behaviour as random, sometimes its fast nd sometimes very slow.
>
> nothing else is running on the m/c
> if i see the top output,
> it shows 97 % postmaster

That's normal enough if you're busy.

Question 1: are you happy that you're vacuuming/analysing enough?
Question 2: When it's slow, is it CPU or I/O that's the problem?

P.S. Don't start a new question by replying to another - most people
will miss your question as it will be nested inside the other.
--
Richard Huxton
Archonet Ltd

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Robert Bernier 2006-11-06 12:11:57 Re: Need replacement booth member for USENIX Lisa
Previous Message Richard Huxton 2006-11-06 11:38:15 Re: postmaster slowing down