From: Tom Lane <tgl@sss.pgh.pa.us>
To: Michael Paquier <michael@paquier.xyz>
Cc: Kuntal Ghosh <kuntalghosh.2007@gmail.com>
Cc: Thunder <thunder1@126.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: PANIC :Call AbortTransaction when transaction id is no normal
Date: Mon, 13 May 2019 09:37:32 -0400
Message-ID: <15939.1557754652@sss.pgh.pa.us> (raw)
In-Reply-To: <20190513081018.GC2273@paquier.xyz>
References: <3850b11a.5121.16aaf827e4a.Coremail.thunder1@126.com>
<CAGz5QCJKDptF4R0xHzM9YLxbLwZHA9enW9zjOi+vF93HVycVgw@mail.gmail.com>
<20190513081018.GC2273@paquier.xyz>
Michael Paquier <michael@paquier.xyz> writes:
> On Mon, May 13, 2019 at 01:25:19PM +0530, Kuntal Ghosh wrote:
>> If we fix the issue in this way, we're certainly not going to do all
>> those portal,locks,memory,resource owner cleanups that are done
>> inside AbortTransaction() for a normal transaction ID. But, I'm not
>> sure how relevant those steps are since the database is anyway
>> shutting down.
> And it is happening in bootstrap, meaning that the data folder is most
> likely toast, and needs to be reinitialized.
Indeed, initdb is going to remove the data directory if the bootstrap run
crashes.
If we do anything at all about this, my thought would just be to change
bootstrap_signals() so that it points all the signal handlers at
quickdie(), or maybe something equivalent to quickdie() but printing
a more apropos message, or even just set them all to SIGDFL since that
means process termination for all of these. die() isn't really the right
thing, precisely because it thinks it can trigger transaction abort,
which makes no sense in bootstrap mode.
But ... that code's been like that for decades and nobody's complained
before. Why are we worried about bootstrap's response to signals at all?
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, michael@paquier.xyz, kuntalghosh.2007@gmail.com, thunder1@126.com, pgsql-hackers@lists.postgresql.org
Subject: Re: PANIC :Call AbortTransaction when transaction id is no normal
In-Reply-To: <15939.1557754652@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox