pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alexander Lakhin <exclusion@gmail.com>
To: Masahiko Sawada <sawada.mshk@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: Srinath Reddy Sadipiralla <srinath2133@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Fix "unexpected logical decoding status change" error; from concurrent logical decoding activation
Date: Fri, 30 Oct 2026 10:00:00 +0200
Message-ID: <8ccd0497-c914-47e2-804d-299b678863bf@gmail.com> (raw)
In-Reply-To: <CAD21AoDzRTcX-Bb01=24nLoEO5Mkb-ChTzcQ1E01t2W_=Bj25Q@mail.gmail.com>
References: <CAFC+b6oYzmAgp7F0ivrhfZT46-CjvCTrU9pWuMNcem-52YjOTw@mail.gmail.com>
	<CAFC+b6rD3c9-s0ZcodAeJB+UTYTV4tPzrgLzJzzDj0QYuBGZJQ@mail.gmail.com>
	<CAD21AoA_pRC3UOz_x9-iL65V9b5NVVRbcDtJ6MamfnN3ZA0n_Q@mail.gmail.com>
	<CAD21AoDEB99VtNbQdDrNd=1gQupJNGMfW_5kdnxq03Q82EK3ag@mail.gmail.com>
	<CAA4eK1K+eQuqiNJp3KrQS3+yGYUdCWMKLLet3DrwU+cWOFj6FA@mail.gmail.com>
	<CAD21AoAxyQHgwWg4udS1_KhuECEWyNkOsh+jODNyj66gjqV4Ug@mail.gmail.com>
	<CAA4eK1KRwzSOvNuJ8FVFYzzp4L3uUf_Z_iHDbmnT2pG6y6nfwQ@mail.gmail.com>
	<CAD21AoBZGuDVa-ctuko+Oma+X9qYppQbzWo8gNmJ1AiRyAjq7g@mail.gmail.com>
	<CAA4eK1+=spL_j76yVvfx5ZObwxfgg6tNWSQbL+84jHqNKGTP6A@mail.gmail.com>
	<CAD21AoCZY1fKYgfkvHGWGiXpatUKd23FSLnDCL4m9bWFjdXNZw@mail.gmail.com>
	<CAD21AoDFpgsqN0b0tyg6iLJ=F7ntYua_2y6x4UUfk9WQu3WBsA@mail.gmail.com>
	<1714235.1785459166@sss.pgh.pa.us>
	<CAD21AoDzRTcX-Bb01=24nLoEO5Mkb-ChTzcQ1E01t2W_=Bj25Q@mail.gmail.com>

Hello Sawada-san,

31.07.2026 06:49, Masahiko Sawada wrote:
> What does the buildfarm member produce the above logs? Many buildfarm
> members failed with that error due to commit 6a80179f6b0, but I've not
> seen further failures since pushing commit 18f9785e0b3.

It took 3 months for buildfarm animals to discover an instability of the
fixed test:
[03:38:56.925](0.036s) # injection_point 'logical-decoding-activation' is reached
[03:38:56.997](0.072s) ok 37 - the activation process aborted
[03:38:57.013](0.016s) # connect output:
# {
#   'stderr' => 'background_psql: ready
# ',
#   'stdout' => 'background_psql: ready
# '
# }
[03:42:33.612](216.599s) # poll_query_until timed out executing this query:
#
#         SELECT count(*) > 0 FROM pg_stat_activity
#         WHERE backend_type = 'client backend' AND wait_event = 'logical-decoding-activation'
#
# expecting this output:
# t
# last actual query output:
# f
# with stderr:
[03:42:33.613](0.000s) # die: timed out when waiting for client backend to reach wait event 
'logical-decoding-activation' at /home/bf/bf-build/melonworm/HEAD/pgsql/src/test/recovery/t/051_effective_wal_level.pl 
line 515.
[03:42:33.613](0.000s) 1..37
timed out when waiting for client backend to reach wait event 'logical-decoding-activation' at 
/home/bf/bf-build/melonworm/HEAD/pgsql/src/test/recovery/t/051_effective_wal_level.pl line 515.

I can reproduce this reliably with a simple sleep:
@@ -180,6 +180,7 @@ injection_points_cleanup(int code, Datum arg)
         if (!injection_point_local)
                 return;

+pg_usleep(1000000);
         /* Detach all the local points */
         foreach(lc, inj_list_local)
         {

Could you please have a look?

`check-world` with this sleep reveals also other tests suffering from the
same disease:
src/test/modules/test_misc/t/010_index_concurrently_upsert.pl
repack_toast
repack_missingval
repack_temporal
repack_temporal_multirange

[1] https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=melonworm&dt=2026-10-30%2002%3A36%3A29

Best regards,
Alexander

view thread (59+ messages)  latest in thread

Message-ID: <8ccd0497-c914-47e2-804d-299b678863bf@gmail.com>
Permalink:  ../8ccd0497-c914-47e2-804d-299b678863bf@gmail.com/
Also on:    postgresql.org/message-id/8ccd0497-c914-47e2-804d-299b678863bf@gmail.com

 · 

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-hackers@postgresql.org
  Cc: exclusion@gmail.com, sawada.mshk@gmail.com, tgl@sss.pgh.pa.us, amit.kapila16@gmail.com, srinath2133@gmail.com
  Subject: Re: Fix "unexpected logical decoding status change" error; from concurrent logical decoding activation
  In-Reply-To: <8ccd0497-c914-47e2-804d-299b678863bf@gmail.com>
  References: <CAFC+b6oYzmAgp7F0ivrhfZT46-CjvCTrU9pWuMNcem-52YjOTw@mail.gmail.com> <CAFC+b6rD3c9-s0ZcodAeJB+UTYTV4tPzrgLzJzzDj0QYuBGZJQ@mail.gmail.com> <CAD21AoA_pRC3UOz_x9-iL65V9b5NVVRbcDtJ6MamfnN3ZA0n_Q@mail.gmail.com> <CAD21AoDEB99VtNbQdDrNd=1gQupJNGMfW_5kdnxq03Q82EK3ag@mail.gmail.com> <CAA4eK1K+eQuqiNJp3KrQS3+yGYUdCWMKLLet3DrwU+cWOFj6FA@mail.gmail.com> <CAD21AoAxyQHgwWg4udS1_KhuECEWyNkOsh+jODNyj66gjqV4Ug@mail.gmail.com> <CAA4eK1KRwzSOvNuJ8FVFYzzp4L3uUf_Z_iHDbmnT2pG6y6nfwQ@mail.gmail.com> <CAD21AoBZGuDVa-ctuko+Oma+X9qYppQbzWo8gNmJ1AiRyAjq7g@mail.gmail.com> <CAA4eK1+=spL_j76yVvfx5ZObwxfgg6tNWSQbL+84jHqNKGTP6A@mail.gmail.com> <CAD21AoCZY1fKYgfkvHGWGiXpatUKd23FSLnDCL4m9bWFjdXNZw@mail.gmail.com> <CAD21AoDFpgsqN0b0tyg6iLJ=F7ntYua_2y6x4UUfk9WQu3WBsA@mail.gmail.com> <1714235.1785459166@sss.pgh.pa.us> <CAD21AoDzRTcX-Bb01=24nLoEO5Mkb-ChTzcQ1E01t2W_=Bj25Q@mail.gmail.com> <8ccd0497-c914-47e2-804d-299b678863bf@gmail.com>

* 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