Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZggNj-0000vo-PH for pgsql-bugs@arkaria.postgresql.org; Mon, 28 Sep 2015 21:54:47 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZggNj-0006j0-AP for pgsql-bugs@arkaria.postgresql.org; Mon, 28 Sep 2015 21:54:47 +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) (envelope-from ) id 1ZggN6-00061Z-MA for pgsql-bugs@postgresql.org; Mon, 28 Sep 2015 21:54:08 +0000 Received: from smtp-auth.no-ip.com ([8.23.224.61] helo=out.smtp-auth.no-ip.com) by magus.postgresql.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84) (envelope-from ) id 1ZggN2-0005VK-Om for pgsql-bugs@postgresql.org; Mon, 28 Sep 2015 21:54:08 +0000 X-No-IP: alvh.no-ip.org@noip-smtp X-Report-Spam-To: abuse@no-ip.com Received: from alvin.alvh.no-ip.org (unknown [200.104.15.201]) (Authenticated sender: alvh.no-ip.org@noip-smtp) by smtp-auth.no-ip.com (Postfix) with ESMTPA id 24C5B4012BF; Mon, 28 Sep 2015 14:54:01 -0700 (PDT) Received: by alvin.alvh.no-ip.org (Postfix, from userid 1000) id D94343817; Mon, 28 Sep 2015 18:53:57 -0300 (CLT) Date: Mon, 28 Sep 2015 18:53:57 -0300 From: Alvaro Herrera To: Amir Rohan Cc: pgsql-bugs@postgresql.org Subject: Re: BUG #13643: Should a process dying bring postgresql down, or not? Message-ID: <20150928215357.GZ295765@alvherre.pgsql> References: <20150926032021.3005.82023@wrigleys.postgresql.org> <20150927185949.GP295765@alvherre.pgsql> <56085581.1000105@mail.com> <20150927210637.GR295765@alvherre.pgsql> <5609B428.6020006@mail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <5609B428.6020006@mail.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Amir Rohan wrote: > On 09/28/2015 12:06 AM, Alvaro Herrera wrote: > > Amir Rohan wrote: > >> > That postmaster is in STOPped mode is the issue here. That doesn't > >> > happen unless you take specific action to do that. > >> > >> I hadn't noticed that. That looks like I suspended pg_ctl during start, > >> but with the backup in progress already, it's not clear how I managed > >> that state. There was no kill -SIGSTOP involved... > > > > Suspending a process *is* sending sigstop. You may not have sent > > sigstop explicitely, but the shell would have done it if you suspended > > the process. > > I *know*. But as you can see that backup process is already underway. > That means pg_ctl had returned by then, and I had issued the > pg_basebackup command. Since I didn't manually send a SIGSTOP, > and postgres was already detached by then, I don't know how it > could have gotten suspended. Maybe if you do pg_ctl in a terminal and it remains there as an unfinished job, then close the terminal, it will get sent a SIGSTOP. I have vague recollections that stuff worked in this way. > >> After killing some subprocesses in random I do see postgres > >> restarting the whole group once one goes down, if/once its > >> running/unsuspended. > > > Well, doing things randomly is unlikely to teach you much ... > > Well, It can teach you which electric socket will > electrocute you when poked with a fork. That's useful data. If you *learn* which one was it, you weren't doing it randomly but systematically trying them all. That's what I wanted to point out. -- Álvaro Herrera http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs