Thread: terminated by signal 11: Segmentation fault

terminated by signal 11: Segmentation fault

From
Gerrit Fouche
Date:
Hi All,

This is the second time I get this error since Postgresql 12 was officially released. My version:
PostgreSQL 12.0 (Ubuntu 12.0-2.pgdg18.04+1) on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0, 64-bit

I am running a Warehouse Management system in a Live environment.
Postgresql was installed from http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease

When this error occurs all other active processes are also terminated. Both these statements are in production for years. The OS of the server is a new implementation on VMWare. Can you please point me in the right direction to solve it?

2019-11-13 11:18:31.296 SAST,,,5033,,5dc7a74d.13a9,75,,2019-11-10 07:59:41 SAST,,0,LOG,00000,"server process (PID 17257) was terminated by signal 11: Segmentation fault","Failed process was running: UPDATE stock_items SET ""parties_role_id"" = NULL, ""inventory_transaction_stock_id"" = NULL, ""stock_type_id"" = 3, ""inventory_quantity"" = 1, ""previous_location_id"" = 7638, ""updated_at"" = '2019-11-13 11:18:30.377770', ""location_code"" = 'KROMCO', ""status_id"" = NULL, ""parties_role_name"" = NULL, ""destroyed"" = 't', ""inventory_transaction_id"" = 32504133, ""status_code"" = 'available', ""current_reference_id"" = NULL, ""inventory_reference"" = '11460516', ""party_name"" = NULL, ""location_id"" = 5150, ""stock_type_code"" = 'BIN', ""created_on"" = '2019-05-21 14:11:12.793316' WHERE ""id"" = 5197826",,,,,,,,""
2019-11-13 11:18:31.296 SAST,,,5033,,5dc7a74d.13a9,76,,2019-11-10 07:59:41 SAST,,0,LOG,00000,"terminating any other active server processes",,,,,,,,,""


/pglog/postgresql-2019-11-05_000000.csv:2019-11-05 09:20:58.291 SAST,,,19626,,5da40a0c.4caa,3,,2019-10-14 07:39:24 SAST,,0,LOG,00000,"server process (PID 12242) was terminated by signal 11: Segmentation fault","Failed process was running: UPDATE bins SET tipped_date_time='Tue Nov 05 07:29:17 UTC 2019',exit_reference_date_time='Tue Nov 05 07:29:17 UTC 2019',exit_ref='PRESORT_BIN_TIPPED',ps_tipped_lot_no='12755',updated_by = '',affected_by_program = '',affected_by_env = '',affected_by_function ='',updated_at = '2019-11-05 09:10:05' WHERE (bin_number = '11375907') ",,,,,,,,""

Re: terminated by signal 11: Segmentation fault

From
Tom Lane
Date:
Gerrit Fouche <gerrit.fouche@gmail.com> writes:
> This is the second time I get this error since Postgresql 12 was officially
> released. My version:
> PostgreSQL 12.0 (Ubuntu 12.0-2.pgdg18.04+1) on x86_64-pc-linux-gnu,
> compiled by gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0, 64-bit

Given that this failed in an UPDATE, I suspect it's a known problem:
if you have a BEFORE UPDATE row-level trigger, and a concurrent update
on the same row happens, 12.0 can dump core due to a slot memory
management mistake.  There's a fix in 12.1, due out tomorrow.

            regards, tom lane



Re: terminated by signal 11: Segmentation fault

From
Gerrit Fouche
Date:
Hi Tom,
Thank you, we have that same scenario.
Regards
Gerrit

On Wed, 13 Nov 2019, 20:57 Tom Lane, <tgl@sss.pgh.pa.us> wrote:
Gerrit Fouche <gerrit.fouche@gmail.com> writes:
> This is the second time I get this error since Postgresql 12 was officially
> released. My version:
> PostgreSQL 12.0 (Ubuntu 12.0-2.pgdg18.04+1) on x86_64-pc-linux-gnu,
> compiled by gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0, 64-bit

Given that this failed in an UPDATE, I suspect it's a known problem:
if you have a BEFORE UPDATE row-level trigger, and a concurrent update
on the same row happens, 12.0 can dump core due to a slot memory
management mistake.  There's a fix in 12.1, due out tomorrow.

                        regards, tom lane