Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.92) (envelope-from ) id 1jBNhi-0006eG-FK for pgsql-hackers@arkaria.postgresql.org; Mon, 09 Mar 2020 19:04:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1jBNhh-0001zh-6p for pgsql-hackers@arkaria.postgresql.org; Mon, 09 Mar 2020 19:04:41 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1jBNhg-0001za-UP for pgsql-hackers@lists.postgresql.org; Mon, 09 Mar 2020 19:04:40 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jBNha-0007jj-Ia for pgsql-hackers@postgresql.org; Mon, 09 Mar 2020 19:04:40 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id 029J4NCK008669; Mon, 9 Mar 2020 15:04:23 -0400 From: Tom Lane To: Andres Freund cc: Alvaro Herrera , Kyotaro Horiguchi , michael@paquier.xyz, thomas.munro@gmail.com, tomas.vondra@2ndquadrant.com, a.zakirov@postgrespro.ru, ah@cybertec.at, magnus@hagander.net, robertmhaas@gmail.com, pgsql-hackers@postgresql.org Subject: Re: shared-memory based stats collector In-reply-to: <20200309184754.yvrgzqpzs3iynszq@alap3.anarazel.de> References: <15888.1583770875@sss.pgh.pa.us> <20200309183705.GA10363@alvherre.pgsql> <20200309184754.yvrgzqpzs3iynszq@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Mon, 09 Mar 2020 11:47:54 -0700" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <8667.1583780663.1@sss.pgh.pa.us> Date: Mon, 09 Mar 2020 15:04:23 -0400 Message-ID: <8668.1583780663@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Andres Freund writes: > On 2020-03-09 15:37:05 -0300, Alvaro Herrera wrote: >> I'm worried that we're causing all processes to terminate when an >> archiver dies in some ugly way; but in the current coding, it's pretty >> harmless and we'd just start a new one. I think this needs to be >> reconsidered. As far as I know, pgarchiver remains unconnected to >> shared memory so a crash-restart cycle is not necessary. We should >> continue to just log the error message and move on. > Why is it worth having the archiver be "robust" that way? I'd ask a different question: what the heck is this patchset doing touching the archiver in the first place? I can see no plausible reason for that doing anything related to stats collection. If we now need some new background processing for stats, let's make a new postmaster child process to do that, not overload the archiver with unrelated responsibilities. regards, tom lane