pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Fabien COELHO <coelho@cri.ensmp.fr>
To: Andres Freund <andres@anarazel.de>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Thom Brown <thom@linux.com>
Cc: Abhijit Menon-Sen <ams@2ndquadrant.com>
Cc: Michael Paquier <michael.paquier@gmail.com>
Cc: Haribabu Kommi <kommi.haribabu@gmail.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: [BUGS] Breakage with VACUUM ANALYSE + partitions
Date: Mon, 2 May 2016 22:00:14 +0200 (CEST)
Message-ID: <alpine.DEB.2.10.1605022146390.927@sto> (raw)
In-Reply-To: <20160502165438.yu6inlsyv4babyie@alap3.anarazel.de>
References: <20160425180521.2g6o4tgpkc3jneyj@alap3.anarazel.de>
	<CA+TgmobdydzhyzsF1gFNu9P=b_uADoM3R-BFGFuF-+heT9OaJw@mail.gmail.com>
	<20160425205720.i2ldnkwj6a2ldz7g@alap3.anarazel.de>
	<CA+Tgmob97m0GniMp82bGkzdZBuLbJWBy2uUbJMtDpAHbm8CRVQ@mail.gmail.com>
	<20160426213207.j3xi2amneejm3ed6@alap3.anarazel.de>
	<CAA-aLv72QazLvPdKZYpVn4a_Eh+i4_cxuB03k+iCuZM_xjc+6Q@mail.gmail.com>
	<20160429235837.b63wkjw4dduf56wt@alap3.anarazel.de>
	<CA+TgmoZirJKnSAkjZHt8cVRW9Y7yHyWFLNENnT-LkFtBi6oBfw@mail.gmail.com>
	<20160502164111.cpupbbkab6ik7wwd@alap3.anarazel.de>
	<CA+Tgmoajiv-4840wHpx0o-LJ7mqSGrnCtRH8MOoJkL2A-GF2Ww@mail.gmail.com>
	<20160502165438.yu6inlsyv4babyie@alap3.anarazel.de>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>


Hello Andres,

> Sure, attached.

For what it is worth, it works for me on head.

I'm wondering that if _mdfd_openseg may return NULL, then ISTM that 
"opened_directly" should logically be false, because it was not opened?

If so, maybe consider something like:

 	opened_directy = (seg != NULL);

Now it does not change the result because the later code seems garded 
against a NULL seg, but it does not look right to have a boolean to say 
that a segment was opened if it was not indeed the case.

Given the comments, I understand that the truncation implementation is a 
shortcut with a sting, as a lot of functions must then take into account 
that something unusual may have happen somewhere and deal with it...

Also, I do not understand why this issue is raised by the flushing patch, 
it seems rather independent.

> I'm not sure this is the best way to go about this.  I can see valid
> arguments for *always* using _mdfd_openseg() in mdsync(); and I'm
> wondering whether we shouldn't make EXTENSION_* into a bitmask
> (extend,extend_recovery,return_null,open_deleted).

I thought about that when I looked at the previous fix, but it seemed that 
not all combinations made sense.

-- 
Fabien.


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (64+ messages)  latest in thread

Message-ID: <alpine.DEB.2.10.1605022146390.927@sto>
Permalink:  ../alpine.DEB.2.10.1605022146390.927@sto/
Also on:    postgresql.org/message-id/alpine.DEB.2.10.1605022146390.927@sto

 · 

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: coelho@cri.ensmp.fr, andres@anarazel.de, robertmhaas@gmail.com, thom@linux.com, ams@2ndquadrant.com, michael.paquier@gmail.com, kommi.haribabu@gmail.com, pgsql-hackers@postgresql.org
  Subject: Re: [BUGS] Breakage with VACUUM ANALYSE + partitions
  In-Reply-To: <alpine.DEB.2.10.1605022146390.927@sto>
  References: <20160425180521.2g6o4tgpkc3jneyj@alap3.anarazel.de> <CA+TgmobdydzhyzsF1gFNu9P=b_uADoM3R-BFGFuF-+heT9OaJw@mail.gmail.com> <20160425205720.i2ldnkwj6a2ldz7g@alap3.anarazel.de> <CA+Tgmob97m0GniMp82bGkzdZBuLbJWBy2uUbJMtDpAHbm8CRVQ@mail.gmail.com> <20160426213207.j3xi2amneejm3ed6@alap3.anarazel.de> <CAA-aLv72QazLvPdKZYpVn4a_Eh+i4_cxuB03k+iCuZM_xjc+6Q@mail.gmail.com> <20160429235837.b63wkjw4dduf56wt@alap3.anarazel.de> <CA+TgmoZirJKnSAkjZHt8cVRW9Y7yHyWFLNENnT-LkFtBi6oBfw@mail.gmail.com> <20160502164111.cpupbbkab6ik7wwd@alap3.anarazel.de> <CA+Tgmoajiv-4840wHpx0o-LJ7mqSGrnCtRH8MOoJkL2A-GF2Ww@mail.gmail.com> <20160502165438.yu6inlsyv4babyie@alap3.anarazel.de> <alpine.DEB.2.10.1605022146390.927@sto>

* 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