Re: Missing Chunk Error when doing a VACUUM FULL operation - DB Corruption?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Arjun Ranade <ranade(at)nodalexchange(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Missing Chunk Error when doing a VACUUM FULL operation - DB Corruption?
Date: 2017-10-31 21:56:14
Message-ID: 23996.1509486974@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Arjun Ranade <ranade(at)nodalexchange(dot)com> writes:
> Yes, it is still reproducible. When I try to VACUUM FULL right now, I get
> the same error.

> This is postgres 9.4. I am new to gdb, but based on what you said, I have
> the following output:

> Breakpoint 1, 0x0000000000768be0 in errfinish ()
> (gdb) bt
> #0 0x0000000000768be0 in errfinish ()
> #1 0x000000000076998c in elog_finish ()
> #2 0x0000000000495960 in ?? ()
> #3 0x0000000000496075 in heap_tuple_fetch_attr ()
> #4 0x0000000000496572 in toast_insert_or_update ()
> #5 0x0000000000492ce1 in ?? ()
> #6 0x0000000000493733 in rewrite_heap_tuple ()
> #7 0x000000000053ebdf in ?? ()
> #8 0x000000000053f68e in cluster_rel ()
> #9 0x0000000000590a1b in ?? ()
> #10 0x0000000000590f9f in vacuum ()
> #11 0x000000000068ee77 in standard_ProcessUtility ()

Hm. I suspect what is happening is that VACUUM is trying to copy a tuple
that you deleted, but which it thinks is still visible to some open
transaction. Do you have any really old transactions hanging around,
according to pg_stat_activity or pg_prepared_xacts?

If that is not it, probably truncating pg_statistic instead of just
doing "delete from pg_statistic" would solve the problem. But we're
no closer to understanding what was the original source of the issue.

regards, tom lane

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Arjun Ranade 2017-10-31 22:08:20 Re: Missing Chunk Error when doing a VACUUM FULL operation - DB Corruption?
Previous Message Arjun Ranade 2017-10-31 21:27:41 Re: Missing Chunk Error when doing a VACUUM FULL operation - DB Corruption?