Closed
Description
Normally when a backend crashes with a segfault, postmaster will kill all other backends and then reinitialize everything. But this breaks when using PgLwLock
, because shared memory initialization of the extension is executed again and then PgLwLock complains that it cannot attach.
2023-07-21 16:08:56.754 CEST [538131] LOG: background worker "Some background worker" (PID 538137) was terminated by signal 11: Segmentation fault
2023-07-21 16:08:56.755 CEST [538131] LOG: all server processes terminated; reinitializing
2023-07-21 16:08:56.924 CEST [538131] FATAL: Can't attach, lock is not in an empty state: PgLwLockInner