Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 5BBDC6500C9 for ; Mon, 22 Dec 2008 09:23:55 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 14275-01 for ; Mon, 22 Dec 2008 09:23:52 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id ACD22650048 for ; Mon, 22 Dec 2008 09:23:52 -0400 (AST) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id mBMDNmLo006939; Mon, 22 Dec 2008 08:23:48 -0500 (EST) To: Laszlo Nagy cc: Alvaro Herrera , pgsql-admin@postgresql.org Subject: Re: rebellious pg stats collector (reopened case) In-reply-to: <494F67D2.3090406@shopzeus.com> References: <49479876.8040607@shopzeus.com> <20081216134542.GH4741@alvh.no-ip.org> <494B614C.5060808@shopzeus.com> <20081219130446.GC4278@alvh.no-ip.org> <494F67D2.3090406@shopzeus.com> Comments: In-reply-to Laszlo Nagy message dated "Mon, 22 Dec 2008 11:11:30 +0100" Date: Mon, 22 Dec 2008 08:23:48 -0500 Message-ID: <6938.1229952228@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200812/174 X-Sequence-Number: 31007 Laszlo Nagy writes: > And the stats collector exited! It cannot be by accident. Last time I > checked, it had the same problem: tried to poll something. It was in an > inifinte loop, polling something but always got POLERR. Then because I > started to trace it, it exited with rval=0 or rval=1. > I do not understand why it exited after I started to trace it? Is this > some kind of bug? AFAICS, the only ways to reach the exit(0) in PgstatCollectorMain are (1) need_exit becomes set (and the only way for that to happen is to receive a SIGQUIT signal); or (2) PostmasterIsAlive(true) fails, which implies that getppid() is returning something different than it used to. I wonder whether your tracing tool is affecting the result of getppid(). Most people would consider that a bug in the tracing tool. regards, tom lane