pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Matthias Apitz <guru@unixarea.de>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: lifetime of the old CTID
Date: Tue, 05 Jul 2022 18:19:18 +0200
Message-ID: <f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at> (raw)
In-Reply-To: <YsReJL8fvHK0D8On@c720-r368166>
References: <20220705075119.GA23@sh4-5.1blu.de>
	<03ca00a881de408016a907e31d832175b04aeac7.camel@cybertec.at>
	<20220705102201.GA9@sh4-5.1blu.de>
	<1c03b94b606f493bc6448b8559c4cccf806d3607.camel@cybertec.at>
	<YsReJL8fvHK0D8On@c720-r368166>

On Tue, 2022-07-05 at 17:52 +0200, Matthias Apitz wrote:
> El día martes, julio 05, 2022 a las 04:17:41p. m. +0200, Laurenz Albe escribió:
> 
> > > > Another explanation could be that the HOT chain was pruned while you were away.
> > > 
> > > I've read now about HOT and understand that autovacuum will prune the
> > > HOT chain. But also a simple SELECT seems to remove it:
> > > 
> > > sisis=# SELECT currtid2('d01buch'::text, '(29036,11)'::tid);
> > >  currtid2  
> > > -----------
> > >  (29036,7)
> > > 
> > > 
> > > sisis=# select ctid, d01gsi from d01buch where d01gsi = '0240564';
> > >    ctid    |           d01gsi            
> > > -----------+-----------------------------
> > >  (29036,7) | 0240564                    
> > > 
> > > 
> > > sisis=# SELECT currtid2('d01buch'::text, '(29036,11)'::tid);
> > >   currtid2  
> > > ------------
> > >  (29036,11)
> > 
> > Right.  Heap-Only tuples can also vanish without autovacuum; that is why I
> > suspected it might have been that.
> 
> Hi Laurenz, ist there any way to keep/freeze such tuples until the run
> of the next autovaccum? Some kind of config value in 13.x or 14.x? Or
> even a code change for this? We compile on Linux from the sources and
> have already some code changes in place...

That should be possible, but why do you want that?  Perhaps there is a better
solution for your problem.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com





view thread (25+ messages)  latest in thread

Message-ID: <f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at>
Permalink:  ../f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at/
Also on:    postgresql.org/message-id/f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at

 · 

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-general@postgresql.org
  Cc: laurenz.albe@cybertec.at, guru@unixarea.de
  Subject: Re: lifetime of the old CTID
  In-Reply-To: <f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at>
  References: <20220705075119.GA23@sh4-5.1blu.de> <03ca00a881de408016a907e31d832175b04aeac7.camel@cybertec.at> <20220705102201.GA9@sh4-5.1blu.de> <1c03b94b606f493bc6448b8559c4cccf806d3607.camel@cybertec.at> <YsReJL8fvHK0D8On@c720-r368166> <f363b79595205d42764ad7485aa46ab534f2d318.camel@cybertec.at>

* 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