Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VlyZn-0007uP-GW for pgsql-bugs@arkaria.postgresql.org; Thu, 28 Nov 2013 10:12:03 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1VlyZm-0005OR-R7 for pgsql-bugs@arkaria.postgresql.org; Thu, 28 Nov 2013 10:12:02 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VlyZl-0005NW-O5 for pgsql-bugs@postgresql.org; Thu, 28 Nov 2013 10:12:01 +0000 Received: from moutng.kundenserver.de ([212.227.17.9]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VlyZi-00081Z-Jg for pgsql-bugs@postgresql.org; Thu, 28 Nov 2013 10:12:01 +0000 Received: from anarazel.de (p5DDC69E9.dip0.t-ipconnect.de [93.220.105.233]) by mrelayeu.kundenserver.de (node=mreu1) with ESMTP (Nemesis) id 0Lg4q7-1VIiMJ0m43-00pNJi; Thu, 28 Nov 2013 11:11:56 +0100 Received: by anarazel.de (Postfix, from userid 1000) id 877C0101873; Thu, 28 Nov 2013 11:11:55 +0100 (CET) Date: Thu, 28 Nov 2013 11:11:55 +0100 From: Andres Freund To: Alvaro Herrera Cc: strahinjak@nordeus.com, pgsql-bugs@postgresql.org Subject: Re: BUG #8632: file "pg_subtrans/CEC0" doesn't exist, reading as zeroes Message-ID: <20131128101155.GP31748@awork2.anarazel.de> References: <20131128025653.GD5513@eldon.alvh.no-ip.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20131128025653.GD5513@eldon.alvh.no-ip.org> X-Provags-ID: V02:K0:T+Ee+br5CSyh0FDDQWXydtlbDaXykQSwjtbsncYzetn MhSd6ncnP93VYNWuvL/D6Tbqi9we1LLOscq7NyHZNbiKPHE9u7 8RoaOdzrxNxhXYXf4HhtusjBD3GeslX/ZQBZnSyFMIqUcnGvOA TXRDcZKVMtAc7O7Fe1nx349p2HwuMVXmLr5nmcMZ7NfX/bQ9zr zVvUTZUNHDVIY5nSlCXmIbvf3fFPJ4b1L1ekfXD0UrsKXDxPLz O0+dSZ1yoyVxpIL6Upz7CtD3EmQGxTTXqXTXf8l+R6mONEsn4x uMMjOjdabJepqY46C/auU8Wwqnk/HGI73LsDiXS/uqH5rAJ8z5 iI47htcTi0ixLRZUy01kWWmAR4LXvXCyaG3Z+OXeB X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org On 2013-11-27 23:56:54 -0300, Alvaro Herrera wrote: > strahinjak@nordeus.com wrote: > > Uh, this is a bit funny. It failed to find the file for a long time and > didn't think to error out, instead choosing to read the requested page > as zeroes: > > > 2013-11-26 12:24:54 CET [6393]: [7-1]LOG: file "pg_subtrans/CEC0" doesn't > > exist, reading as zeroes > > 2013-11-26 12:24:54 CET [6393]: [8-1]CONTEXT: xlog redo xid assignment xtop > > 3468737450: subxacts: 3468738448 3468738450 3468738453 3468738455 3468738457 > > 3468738459 3468738461 3468738463 3468738465 3468738467 3468738469 3468738471 > > 3468738473 3468738475 3468738477 3468738479 3468738481 3468738483 3468738485 > > 3468738487 3468738489 3468738491 3468738493 3468738495 3468738497 3468738499 > > 3468738501 3468738503 3468738505 3468738507 3468738530 3468738532 3468738534 > > 3468738536 3468738538 3468738540 3468738542 3468738544 3468738546 3468738548 > > 3468738550 3468738552 3468738554 3468738556 3468738558 3468738560 3468738562 > > 3468738564 3468738566 3468738568 3468738570 3468738572 3468738574 3468738576 > > 3468738578 3468738580 3468738582 3468738584 3468738586 3468738588 3468738590 > > 3468738592 3468738595 3468738597 > > But as soon as the pg_subtrans file existed, any other error (seek or > read failure) is fatal: > > > 2013-11-26 12:24:57 CET [6393]: [103-1]FATAL: could not access status of > > transaction 3468818432 > > 2013-11-26 12:24:57 CET [6393]: [104-1]DETAIL: Could not read from file > > "pg_subtrans/CEC1" at offset 253952: Success. > > Both these things happen in SlruPhysicalReadPage(). I think those hard > failures are a mistake. In other words, we should do something like > this, which matches what happens if ENOENT: Hm. I actually would rather remove the "reading as zeroes" paths alltogether. Imo its more than likely they are actually hiding bugs - like this case - than anything else. Heikki suggested WAL-logging subtrans extensions/truncations. That would remove the need for that set of hacks altogether. It should already never be required when you're in HS (modulo bugs). Greetings, Andres Freund -- Andres Freund http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs