Re: function for testing that causes the backend to terminate

From: Dave Cramer <davecramer(at)gmail(dot)com>
To: Joe Conway <mail(at)joeconway(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: function for testing that causes the backend to terminate
Date: 2021-05-03 17:51:29
Message-ID: CADK3HHLMMrMMB=8gCxQHM7d2DWs8grigc+7UtsCPDvT+qpR7SA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Joe,

Thanks,

This works and I don't have to install anything!

Dave Cramer

On Thu, 29 Apr 2021 at 16:16, Joe Conway <mail(at)joeconway(dot)com> wrote:

> On 4/29/21 6:56 AM, Dave Cramer wrote:
> > For testing unusual situations I'd like to be able to cause a backend to
> > terminate due to something like a segfault. Do we currently have this in
> > testing ?
>
> If you can run SQL as a superuser from that backend, try:
>
> COPY (SELECT pg_backend_pid())
> TO PROGRAM 'xargs kill -SIGSEGV';
>
> HTH,
>
> Joe
>
> --
> Crunchy Data - http://crunchydata.com
> PostgreSQL Support for Secure Enterprises
> Consulting, Training, & Open Source Development
>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Davis 2021-05-03 17:57:26 Re: MaxOffsetNumber for Table AMs
Previous Message Chapman Flack 2021-05-03 17:43:32 Re: Granting control of SUSET gucs to non-superusers