pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Fujii Masao <masao.fujii@gmail.com>
To: pgsql-bugs@postgresql.org
Subject: BUG #6249: Segmentation fault in VirtualXactLock()
Date: Tue, 11 Oct 2011 01:44:39 GMT
Message-ID: <201110110144.p9B1idhO038422@wwwmaster.postgresql.org> (raw)


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.



view thread (3+ messages)  latest in thread

Message-ID: <201110110144.p9B1idhO038422@wwwmaster.postgresql.org>
Permalink:  ../201110110144.p9B1idhO038422@wwwmaster.postgresql.org/
Also on:    postgresql.org/message-id/201110110144.p9B1idhO038422@wwwmaster.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: masao.fujii@gmail.com
  Subject: Re: BUG #6249: Segmentation fault in VirtualXactLock()
  In-Reply-To: <201110110144.p9B1idhO038422@wwwmaster.postgresql.org>
  References: <201110110144.p9B1idhO038422@wwwmaster.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox