Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 4137D9FB553 for ; Mon, 22 Jan 2007 18:52:48 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-new, port 10024) with ESMTP id 32239-10 for ; Mon, 22 Jan 2007 18:52:44 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from web60712.mail.yahoo.com (web60712.mail.yahoo.com [209.73.178.215]) by postgresql.org (Postfix) with SMTP id D2D0E9FB507 for ; Mon, 22 Jan 2007 18:52:44 -0400 (AST) Received: (qmail 16741 invoked by uid 60001); 22 Jan 2007 22:52:43 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=eZPz4LvsB6K1lqecmRHIFyzi5noCjJ57ix30A2f6b2/JeN61ZWFkdkxIM+bNVGAWRfmpXV3AFSSwSnhqkHFo3ptwWyQmvoayJxGC5pFjPNirbieJri4zCN5SipWJ+iBt5lOmSHRK3cdSe7HBTIODbOLFvdiWTidxBKDznOQR3Pk=; Received: from [66.152.238.10] by web60712.mail.yahoo.com via HTTP; Mon, 22 Jan 2007 14:52:43 PST Date: Mon, 22 Jan 2007 14:52:43 -0800 (PST) From: Subramaniam Aiylam Subject: Postgres processes have a burst of CPU usage To: pgsql-general@postgresql.org, pgsql-performance@postgresql.org, pgsql-jdbc@postgresql.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <321168.15595.qm@web60712.mail.yahoo.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=3.356 tagged_above=0 required=5 tests=BAYES_50, DNS_FROM_RFC_ABUSE, DNS_FROM_RFC_POST, DNS_FROM_RFC_WHOIS X-Spam-Level: *** X-Archive-Number: 200701/1435 X-Sequence-Number: 107975 Hello all, I have a setup in which four client machines access a Postgres database (8.1.1) (on a Linux box). So, there are connections from each machine to the database; hence, the Linux box has about 2 postgres processes associated with each machine. I am using the JDBC driver (postgresql-8.1-404.jdbc3.jar) to talk to the database. I am also using the Spring framework(1.2.2) and Hibernate (3.0.5) on top of JDBC. I use Apache's DBCP database connection pool (1.2.1). Now, there is one particular update that I make from one of the client machines - this involves a reasonably large object graph (from the Java point of view). It deletes a bunch of rows (around 20 rows in all) in 4-5 tables and inserts another bunch into the same tables. When I do this, I see a big spike in the CPU usage of postgres processes that are associated with ALL the client machines, not just the one I executed the delete/insert operation on. The spike seems to happen a second or two AFTER the original update completes and last for a few seconds. Is it that this operation is forcibly clearing some client cache on ALL the postgres processes? Why is there such an interdependency? Can I set some parameter to turn this off? Regards and thanks, S.Aiylam ____________________________________________________________________________________ Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. http://videogames.yahoo.com/platform?platform=120121 ____________________________________________________________________________________ Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail beta. http://new.mail.yahoo.com