Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eFWzD-0008DY-7R for pgsql-general@arkaria.postgresql.org; Fri, 17 Nov 2017 03:06:35 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1eFWzB-0006Ih-T6 for pgsql-general@arkaria.postgresql.org; Fri, 17 Nov 2017 03:06:33 +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_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1eFWzA-0006Go-TV for pgsql-general@postgresql.org; Fri, 17 Nov 2017 03:06:32 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1eFWz6-0004Cy-KU for pgsql-general@postgresql.org; Fri, 17 Nov 2017 03:06:31 +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 vAH36Neu023681; Thu, 16 Nov 2017 22:06:23 -0500 From: Tom Lane To: Andres Freund cc: David Pacheco , pgsql-general@postgresql.org Subject: Re: postmaster deadlock while logging after syslogger exited In-reply-to: <20171117025438.vjvgmrrnkpnojleq@alap3.anarazel.de> References: <19239.1510000503@sss.pgh.pa.us> <20171117015040.m36ovf5dqtg3star@alap3.anarazel.de> <22373.1510886389@sss.pgh.pa.us> <20171117025438.vjvgmrrnkpnojleq@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Thu, 16 Nov 2017 18:54:38 -0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <23679.1510887983.1@sss.pgh.pa.us> Date: Thu, 16 Nov 2017 22:06:23 -0500 Message-ID: <23680.1510887983@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-general Precedence: bulk Sender: pgsql-general-owner@postgresql.org Andres Freund writes: > On 2017-11-16 21:39:49 -0500, Tom Lane wrote: >> What might be worth thinking about is allowing the syslogger process to >> inherit the postmaster's OOM-kill-proofness setting, instead of dropping >> down to the same vulnerability as the postmaster's other child processes. > Hm. I'm a bit scared about that - it doesn't seem that inconceivable > that various backends log humongous multi-line messages, leading to > syslogger *actually* taking up a fair amount of memory. Note that we're > using plain stringinfos that ereport(ERROR) out of memory situations, > rather than failing more gracefully. True, but there's no hard limits on the postmaster's memory consumption either ... and if the syslogger does get killed on such a basis, we have at the least lost a bunch of log output. On the whole I think we'd be better off trying to prevent OOM kills on the syslogger. (That doesn't preclude other mitigation measures.) regards, tom lane -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general