Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 421A49F9260 for ; Tue, 6 Nov 2007 12:21:13 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 26068-01-8 for ; Tue, 6 Nov 2007 12:21:09 -0400 (AST) Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.188]) by postgresql.org (Postfix) with ESMTP id 3BB3E9F9294 for ; Tue, 6 Nov 2007 12:20:26 -0400 (AST) Received: by nf-out-0910.google.com with SMTP id f5so1409190nfh for ; Tue, 06 Nov 2007 08:20:26 -0800 (PST) Received: by 10.82.126.5 with SMTP id y5mr12845163buc.1194366025361; Tue, 06 Nov 2007 08:20:25 -0800 (PST) Received: by 10.82.108.10 with HTTP; Tue, 6 Nov 2007 08:20:25 -0800 (PST) Message-ID: Date: Tue, 6 Nov 2007 11:20:25 -0500 From: "Phillip Mills" To: "Dave Cramer" Subject: Re: Beginning tuning Cc: pgsql-jdbc@postgresql.org In-Reply-To: <1FE7BE24-04ED-4E83-8B8C-8A0E90644B3C@fastcrypt.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_33477_5530973.1194366025334" References: <1FE7BE24-04ED-4E83-8B8C-8A0E90644B3C@fastcrypt.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200711/14 X-Sequence-Number: 17769 ------=_Part_33477_5530973.1194366025334 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline It doesn't seem to be slow. It certainly isn't using a lot of CPU and our DBA hasn't identified any locking on that front that would explain anything. As I said originally, my main interest at this point is getting some idea why most user threads in the application server are sampled in I/O processing, funneled through that ReceiveChar() call. It may be irrelevant, but it would be interesting to know that one way or the other. On 11/6/07, Dave Cramer wrote: > > Phillip, > Sorry there's no one manual that will give you all the answers. > > have you tuned postgres ? > > is it actually slow ? > > Dave > On 6-Nov-07, at 9:51 AM, Phillip Mills wrote: > > I was rather hoping for a "go here, read this" answer as a starting point > instead of loading people down with a bunch of details. Also, I have no > evidence that JDBC is doing anything wrong; it was just the next item on my > path after determining that there wasn't any application lock silliness. > But as a software sanity check: > JBoss 4.2.1 with a JBossManagedConnectionPool of 20 (but testing with > fewer client threads) > PostgreSQL 8.1.9-1.2 > postgresql-8.1-407.jdbc3.jar > (Linux OpenSUsE 10.2) > > On 11/6/07, Dave Cramer wrote: > > > > Phillip, > > > > You'd have to give us a lot more information than this to help you. > > > > machine specs ? > > Postgresql version and jdbc version > > postgresql configuration > > are you using a db pool ? > > > > Dave > > > > On 6-Nov-07, at 9:09 AM, Phillip Mills wrote: > > > > > I'm just getting started on the process of analyzing performance for > > > a Java Enterprise application. (The main negative symptom at the > > > moment is that it doesn't use more than three processors on an eight- > > > processor system, regardless of load.) > > > > > > One of the first things I've noticed out of a number of thread dumps > > > is that there's about an 80% chance that the stack points to I/O > > > requests from PGStream.ReceiveChar(). I'm wondering about any hints > > > or pointers that would help me understand whether that's expected > > > behavior, or something that needs fixing, or just generally how to > > > evaluate/improve JDBC performance. > > > > > > (Regarding the main problem, none of my threads are reported in a > > > blocked state, leading to my focus on I/O.) > > > > > > ------=_Part_33477_5530973.1194366025334 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline It doesn't seem to be slow.  It certainly isn't using a lot of CPU and our DBA hasn't identified any locking on that front that would explain anything.

As I said originally, my main interest at this point is getting some idea why most user threads in the application server are sampled in I/O processing, funneled through that ReceiveChar() call.  It may be irrelevant, but it would be interesting to know that one way or the other.


On 11/6/07, Dave Cramer <pg@fastcrypt.com> wrote:
Phillip,

Sorry there's no one manual that will give you all the answers.

have you tuned postgres ?

is it actually slow ?

Dave

On 6-Nov-07, at 9:51 AM, Phillip Mills wrote:

I was rather hoping for a "go here, read this" answer as a starting point instead of loading people down with a bunch of details.  Also, I have no evidence that JDBC is doing anything wrong; it was just the next item on my path after determining that there wasn't any application lock silliness.
But as a software sanity check:
JBoss 4.2.1 with a JBossManagedConnectionPool of 20 (but testing with fewer client threads)
PostgreSQL 8.1.9-1.2
postgresql-8.1-407.jdbc3.jar
(Linux OpenSUsE 10.2)

On 11/6/07, Dave Cramer <pg@fastcrypt.com> wrote:
Phillip,

You'd have to give us a lot more information than this to help you.

machine specs ?
Postgresql version and jdbc version
postgresql configuration
are you using a db pool ?

Dave

On 6-Nov-07, at 9:09 AM, Phillip Mills wrote:

> I'm just getting started on the process of analyzing performance for
> a Java Enterprise application.  (The main negative symptom at the
> moment is that it doesn't use more than three processors on an eight-
> processor system, regardless of load.)
>
> One of the first things I've noticed out of a number of thread dumps
> is that there's about an 80% chance that the stack points to I/O
> requests from PGStream.ReceiveChar().  I'm wondering about any hints
> or pointers that would help me understand whether that's expected
> behavior, or something that needs fixing, or just generally how to
> evaluate/improve JDBC performance.
>
> (Regarding the main problem, none of my threads are reported in a
> blocked state, leading to my focus on I/O.)




------=_Part_33477_5530973.1194366025334--