Re: [HACKERS] WAL logging problem in 9.4.3?

From: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
To: noah(at)leadboat(dot)com
Cc: thomas(dot)munro(at)gmail(dot)com, robertmhaas(at)gmail(dot)com, pgsql-hackers(at)postgresql(dot)org, 9erthalion6(at)gmail(dot)com, andrew(dot)dunstan(at)2ndquadrant(dot)com, hlinnaka(at)iki(dot)fi, michael(at)paquier(dot)xyz
Subject: Re: [HACKERS] WAL logging problem in 9.4.3?
Date: 2020-02-18 10:50:16
Message-ID: 20200218.195016.1845965961888951051.horikyota.ntt@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Oops. I played on a wrong branch and got stuck in slow build on
Windows...

At Tue, 18 Feb 2020 00:53:37 -0800, Noah Misch <noah(at)leadboat(dot)com> wrote in
> On Tue, Feb 18, 2020 at 03:56:15PM +1300, Thomas Munro wrote:
> > CREATE TYPE priv_testtype1 AS (a int, b text);
> > +ERROR: relation 24844 deleted while still in use
> > REVOKE USAGE ON TYPE priv_testtype1 FROM PUBLIC;
> >
> > https://ci.appveyor.com/project/postgresql-cfbot/postgresql/build/1.0.79923
> >
> > It didn't fail on the same OS a couple of days earlier:
> >
> > https://ci.appveyor.com/project/postgresql-cfbot/postgresql/builds/30829686
>
> Thanks for the report. This reproduces consistently under
> CLOBBER_CACHE_ALWAYS (which, coincidentally, I started today). Removing the
> heap_create() change fixes it. Since we now restore a saved rd_createSubid,
> the heap_create() change is obsolete. My next version will include that fix.

Yes, ATExecAddIndex correctly set createSubid without that.

> The system uses rd_createSubid to mean two things. First, rd_node is new.
> Second, the rel might not yet be in catalogs, so we can't rebuild its relcache
> entry. The first can be false while the second is true, hence this failure.
> However, the second is true in a relatively-narrow period in which we don't
> run arbitrary user code. Hence, that simple fix suffices.

I didn't care the second meaning. I thought it is caused by
invalidation but I couldn't get a core dump on Windows 10.. The
comment for RelationCacheInvalidate seems faintly explains about the
second meaning.

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro Horiguchi 2020-02-18 10:59:22 Re: Parallel copy
Previous Message Amit Kapila 2020-02-18 10:29:36 Re: Parallel copy