Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e9eWC-0001k3-05 for pgsql-admin@arkaria.postgresql.org; Tue, 31 Oct 2017 21:56:20 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1e9eWB-0005rJ-ER for pgsql-admin@arkaria.postgresql.org; Tue, 31 Oct 2017 21:56:19 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e9eWB-0005rA-0V for pgsql-admin@postgresql.org; Tue, 31 Oct 2017 21:56:19 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e9eW8-0006TW-Ab for pgsql-admin@postgresql.org; Tue, 31 Oct 2017 21:56:17 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v9VLuEEB023997; Tue, 31 Oct 2017 17:56:14 -0400 From: Tom Lane To: Arjun Ranade cc: pgsql-admin@postgresql.org Subject: Re: Missing Chunk Error when doing a VACUUM FULL operation - DB Corruption? In-reply-to: References: <13631.1509479942@sss.pgh.pa.us> Comments: In-reply-to Arjun Ranade message dated "Tue, 31 Oct 2017 17:27:41 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <23995.1509486974.1@sss.pgh.pa.us> Date: Tue, 31 Oct 2017 17:56:14 -0400 Message-ID: <23996.1509486974@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org Arjun Ranade 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 -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin