Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-14 Thread Tom Lane
Andres Freund writes: > On 2019-05-14 12:37:39 +0900, Michael Paquier wrote: >> Still, I would like to understand why the bootstrap process has been >> signaled to begin with, particularly for an initdb, which is not >> really something that should happen on a server where an instance >> runs. If

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Andres Freund
Hi, On 2019-05-14 12:37:39 +0900, Michael Paquier wrote: > Still, I would like to understand why the bootstrap process has been > signaled to begin with, particularly for an initdb, which is not > really something that should happen on a server where an instance > runs. If you have a too aggressi

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Michael Paquier
On Mon, May 13, 2019 at 11:28:51PM -0400, Tom Lane wrote: > OK, that's fair. The SIG_DFL change I suggested will fix that problem > for SIGINT etc (except SIGQUIT, for which you should be *expecting* > a core file). I agree with Michael that we do not wish to change what > happens for an internal

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Tom Lane
[ please don't top-post on the PG lists ] Thunder writes: > At 2019-05-14 07:53:36, "Michael Paquier" wrote: >> On Mon, May 13, 2019 at 09:37:32AM -0400, Tom Lane wrote: >>> But ... that code's been like that for decades and nobody's complained >>> before. Why are we worried about bootstrap's

Re:Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Thunder
On our server when process crash and core dump file generated we will receive complaining phone call. That's why i try to fix it. At 2019-05-14 07:53:36, "Michael Paquier" wrote: >On Mon, May 13, 2019 at 09:37:32AM -0400, Tom Lane wrote: >> But ... that code's been like that for decades a

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Michael Paquier
On Mon, May 13, 2019 at 09:37:32AM -0400, Tom Lane wrote: > 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? Yeah, I don't think that it is something worth bothering either. As you mentioned the data

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Tom Lane
I wrote: > 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 > mea

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Kuntal Ghosh
On Mon, May 13, 2019 at 7:07 PM Tom Lane wrote: > Michael Paquier 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 A

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Tom Lane
Michael Paquier 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

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Michael Paquier
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 step

Re: PANIC :Call AbortTransaction when transaction id is no normal

2019-05-13 Thread Kuntal Ghosh
Hello, On Mon, May 13, 2019 at 10:15 AM Thunder wrote: > I try to fix this issue and check whether it's normal transaction id > before we do abort. > > diff --git a/src/backend/access/transam/xact.c > b/src/backend/access/transam/xact.c > index 20feeec327..dbf2bf567a 100644 > --- a/src/backend/a

PANIC :Call AbortTransaction when transaction id is no normal

2019-05-12 Thread Thunder
Hello, The process crashed when running in bootstrap mode and received signal to shutdown. From the call stack we can see that the transaction id is 1, which is BootstrapTransactionId. During TransactionLogFetch function, which fetch commit status of specified transaction id, it will return