Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 53E74B5DBE9 for ; Mon, 10 Oct 2011 22:44:40 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 14662-04 for ; Tue, 11 Oct 2011 01:44:40 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by mail.postgresql.org (Postfix) with ESMTP id 8E7E4B5DBE4 for ; Mon, 10 Oct 2011 22:44:39 -0300 (ADT) Received: from wwwmaster.postgresql.org (wwwmaster.postgresql.org [217.196.146.204]) by wwwmaster.postgresql.org (8.14.3/8.14.3) with ESMTP id p9B1idwS038423 for ; Tue, 11 Oct 2011 01:44:39 GMT (envelope-from www@wwwmaster.postgresql.org) Received: (from www@localhost) by wwwmaster.postgresql.org (8.14.3/8.14.3/Submit) id p9B1idhO038422; Tue, 11 Oct 2011 01:44:39 GMT (envelope-from www) Date: Tue, 11 Oct 2011 01:44:39 GMT Message-Id: <201110110144.p9B1idhO038422@wwwmaster.postgresql.org> To: pgsql-bugs@postgresql.org Subject: BUG #6249: Segmentation fault in VirtualXactLock() From: "Fujii Masao" Content-Type: text/plain; charset=utf-8 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 201110/76 X-Sequence-Number: 31346 The following bug has been logged online: Bug reference: 6249 Logged by: Fujii Masao Email address: masao.fujii@gmail.com PostgreSQL version: 9.2dev Operating system: Linux hermes 2.6.38-11-generic #50-Ubuntu SMP Mon Sep 12 21:18:14 UTC 2011 i686 i686 i386 GNU/Linux Description: Segmentation fault in VirtualXactLock() Details: When I built Streaming Replication and Hot Standby environment, set max_standby_streaming_delay to 1s and ran the following shell script which creates the conflict between read-only query and recovery, SEGV occurred on the standby. ---------------------- #!/bin/sh # Master's port: 5432 # Standby's port: 9999 psql -c "CREATE TABLE tbl (id int)" -p 5432 psql -c "INSERT INTO tbl VALUES(1)" -p 5432 sleep 1 psql -c "SELECT pg_sleep(60) FROM tbl" -p 9999 & sleep 1 psql -c "DELETE FROM tbl" -p 5432 psql -c "VACUUM tbl" -p 5432 ---------------------- backtrace is: Core was generated by `postgres: startup process recovering 000000'. Program terminated with signal 11, Segmentation fault. #0 0x083114db in VirtualXactLock () (gdb) bt #0 0x083114db in VirtualXactLock () #1 0x083072d1 in ResolveRecoveryConflictWithVirtualXIDs () #2 0x08307355 in ResolveRecoveryConflictWithSnapshot () #3 0x080b8abc in heap_xlog_clean () #4 0x080bc31a in heap2_redo () #5 0x080f02fd in StartupXLOG () #6 0x080f6c70 in StartupProcessMain () #7 0x0811d5f9 in AuxiliaryProcessMain () #8 0x082d17e4 in StartChildProcess () #9 0x082cd151 in PostmasterMain () #10 0x0824d6b4 in main () I was not able to reproduce this issue on 9.1.1. So the bug would exist only on 9.2dev.