BUG #9741: Mininal case for the BUG #9735: Error: "ERROR: tuple offset out of range: 0" during bitmap scan

From: maxim(dot)boguk(at)gmail(dot)com
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #9741: Mininal case for the BUG #9735: Error: "ERROR: tuple offset out of range: 0" during bitmap scan
Date: 2014-03-27 09:33:57
Message-ID: 20140327093357.13967.98197@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 9741
Logged by: Maxim Boguk
Email address: maxim(dot)boguk(at)gmail(dot)com
PostgreSQL version: 9.3.3
Operating system: Linux (Ubuntu)
Description:

Hi,

How situation with the BUG #9735 become even more curious.

One query successfully executing on master db but doesn't work on both
streaming replicas.
After much digging I located problem and produced it in pretty simple way:

gate_platbox=# set enable_indexscan to 0;
SET
(force bitmap scan)
gate_platbox=# explain analyze select * from transactions where
id=53265020;
ERROR: tuple offset out of range: 0

This tuple had been frozen not that long time ago:

gate_platbox=# select id,xmin,xmax,cmin,cmax,ctid from transactions where
id=53265020;
id | xmin | xmax | cmin | cmax | ctid
----------+------+------+------+------+-------------
53265020 | 2 | 0 | 1 | 1 | (2413168,1)

pageinspect over used index also show nothing suspicious:
select gs.i,t.* from (select generate_series(1,94961) as i) as gs,
bt_page_items('transactions_pkey', i) as t where ctid::text='(2413168,1)';
i | itemoffset | ctid | itemlen | nulls | vars | data
-------+------------+-------------+---------+-------+------+-------------------------
88472 | 93 | (2413168,1) | 16 | f | f | 7c c2 2c 03 00
00 00 00

Any ideas what's can be wrong with the database?

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Maxim Boguk 2014-03-27 11:32:03 Re: BUG #9741: Mininal case for the BUG #9735: Error: "ERROR: tuple offset out of range: 0" during bitmap scan
Previous Message Dang Minh Huong 2014-03-26 22:07:01 Re: [HACKERS] Duplicated row after promote in synchronous streaming replication