X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 2028FD1B989 for ; Sat, 13 Mar 2004 04:02:46 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 66449-01 for ; Sat, 13 Mar 2004 00:02:40 -0400 (AST) Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by svr1.postgresql.org (Postfix) with ESMTP id CFA6CD1CAF3 for ; Sat, 13 Mar 2004 00:02:38 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.12.11/8.12.11) with ESMTP id i2D42aEN014885; Fri, 12 Mar 2004 23:02:36 -0500 (EST) To: Joe Conway Cc: pgsql-performance Subject: Re: rapid degradation after postmaster restart In-reply-to: <4052661D.5060505@joeconway.com> References: <4052661D.5060505@joeconway.com> Comments: In-reply-to Joe Conway message dated "Fri, 12 Mar 2004 17:38:37 -0800" Date: Fri, 12 Mar 2004 23:02:35 -0500 Message-ID: <14884.1079150555@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200403/169 X-Sequence-Number: 6025 Joe Conway writes: > The problem is this: the application runs an insert, that fires off a > trigger, that cascades into a fairly complex series of functions, that > do a bunch of calculations, inserts, updates, and deletes. Immediately > after a postmaster restart, the first insert or two take about 1.5 > minutes (undoubtedly this could be improved, but it isn't the main > issue). However by the second or third insert, the time increases to 7 - > 9 minutes. Restarting the postmaster causes the cycle to repeat, i.e. > the first one or two inserts are back to the 1.5 minute range. I realize this question might take some patience to answer, but what does the performance curve look like beyond three trials? Does it level off or continue to get worse? If it doesn't level off, does the degradation seem linear in the number of trials, or worse than linear? I have no ideas in mind, just trying to gather data ... regards, tom lane