Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id EDAB07591C6 for ; Thu, 24 May 2012 19:39:51 -0300 (ADT) Received: from smtp.01.com ([199.36.142.181]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SXghB-0003pq-86 for pgsql-bugs@postgresql.org; Thu, 24 May 2012 22:39:51 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp-out-1.01.com (Postfix) with ESMTP id E9A9D3F660F; Thu, 24 May 2012 17:39:35 -0500 (CDT) X-Virus-Scanned: amavisd-new at smtp-out-1.01.com Received: from smtp.01.com ([127.0.0.1]) by localhost (smtp-out-1.01.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id oL9xSdtbAVlB; Thu, 24 May 2012 17:39:35 -0500 (CDT) Received: from smtp.01.com (localhost.localdomain [127.0.0.1]) by smtp-out-1.01.com (Postfix) with ESMTP id C2E483F660D; Thu, 24 May 2012 17:39:35 -0500 (CDT) Received: from [10.10.10.20] (8.202-62-69.ftth.swbr.surewest.net [69.62.202.8]) by smtp-out-1.01.com (Postfix) with ESMTPSA id 8FFAC3F660F; Thu, 24 May 2012 17:39:35 -0500 (CDT) Subject: Re: 9.1.3 backends getting stuck in 'startup' Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=us-ascii From: Jeff Frost In-Reply-To: <2784.1337898946@sss.pgh.pa.us> Date: Thu, 24 May 2012 15:39:34 -0700 Cc: pgsql-bugs@postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: <3B46C63B-A770-45C5-8889-2796C5E3AB84@pgexperts.com> References: <4F9AC452.3050102@pgexperts.com> <28484.1337887297@sss.pgh.pa.us> <4FBE9CDB.3030009@pgexperts.com> <2196.1337897586@sss.pgh.pa.us> <7A939C5B-ABA4-4CF4-9473-F48989399813@pgexperts.com> <2784.1337898946@sss.pgh.pa.us> To: Tom Lane X-Mailer: Apple Mail (2.1257) X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201205/194 X-Sequence-Number: 33165 On May 24, 2012, at 3:35 PM, Tom Lane wrote: > Jeff Frost writes: >> On May 24, 2012, at 3:13 PM, Tom Lane wrote: >>> Huh. A bit bigger, but not by that much. It doesn't seem like this >>> would be enough to make seqscan performance fall off a cliff, as it >>> apparently did. Unless maybe the slightly-bloated catalogs were = just a >>> bit too large to fit in RAM, and so the repeated seqscans went from >>> finding all their data in kernel disk buffers to finding none of it? >=20 >> Seems unlikely. >> Server has 128GB of RAM. >=20 > Hm ... sure seems like that ought to be enough ;-), even with a = near-2GB > pg_attribute table. What's your shared_buffers setting? It's 8GB. >=20 >> BTW, when I connected to it this time, I had a really long time = before my psql was able to send a query, so it seems to be still broken = at least. >=20 > Yeah, I was afraid that re-initdb would be at best a temporary = solution. Oh, sorry, I wasn't clear on that. The currently running system is = still happy, but the old data directory got stuck in 'startup' for a = while when I connected via psql. >=20 > It would probably be useful to confirm the theory that relcache = rebuild > is what makes it stall. You should be able to manually remove the > pg_internal.init file in the database's directory; then connect with > psql, and time how long it takes before the pg_internal.init file > reappears. So, you're thinking autovac invalidates the cache and causes it to be = rebuilt, then a bunch of new connections get stalled as they all wait = for the rebuild? I'll see if I can get the customer to move the data directory to a test = system so I can futz with it on a non production system.=