Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oT6UY-0004iC-HM for pgsql-bugs@arkaria.postgresql.org; Tue, 30 Aug 2022 19:01:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oT6UW-00081Q-Qn for pgsql-bugs@arkaria.postgresql.org; Tue, 30 Aug 2022 19:01:40 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oT6UW-00081H-JE for pgsql-bugs@lists.postgresql.org; Tue, 30 Aug 2022 19:01:40 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oT6UQ-0002nm-BG for pgsql-bugs@lists.postgresql.org; Tue, 30 Aug 2022 19:01:40 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 27UJ1VG03727394; Tue, 30 Aug 2022 15:01:31 -0400 From: Tom Lane To: higherone@gmail.com cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #17602: Query backend process killed because it uses up all memory. In-reply-to: <17602-b072900fa964cabf@postgresql.org> References: <17602-b072900fa964cabf@postgresql.org> Comments: In-reply-to PG Bug reporting form message dated "Tue, 30 Aug 2022 16:11:40 -0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <3727392.1661886091.1@sss.pgh.pa.us> Date: Tue, 30 Aug 2022 15:01:31 -0400 Message-ID: <3727393.1661886091@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk PG Bug reporting form writes: > I'm writing to seek for generic help on trouble shooting bugs related to > query backend process killed because of memory exhaust on this single query > process. Try starting the server under a restrictive ulimit, so that it will get ENOMEM failure before it bloats to the point of receiving an OOM kill. Aside from being more friendly to other server processes, this should result in getting a memory consumption map dumped to postmaster stderr when the failure is hit. Seeing which context is getting bloated would be pretty useful information. On Linux I believe "ulimit -v" is the most appropriate setting to change. regards, tom lane