Re: PG17.6 zstd handling bug

From: "badfilez(at)gmail(dot)com" <badfilez(at)gmail(dot)com>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: pgsql-pkg-yum(at)lists(dot)postgresql(dot)org
Subject: Re: PG17.6 zstd handling bug
Date: 2025-10-20 08:51:04
Message-ID: ef94252c-f0f5-45f4-87e3-94385a1c8f3f@gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

After more debugging,

replica recovery creates corrupted index file from wal
the operation on which segfault happens is
rmgr: Btree len (rec/tot): 3758/ 5774, tx: 1711720455, lsn: 1F36/30E3C7B8, prev 1F36/30E3C760, desc: SPLIT_L level: 0, firstrightoff: 140, newitemoff:
140, postingoff: 0, blkref #0: rel 1663/16385/151181595blk 63203FPW, blkref #1: rel 1663/16385/151181595blk 112208, blkref #2: rel
1663/16385/151181595blk 108144FPW

the wal segment containing the instruction attached

unfortunately debuginfo packages are unavailable

PostgreSQL 17 for RHEL / Rocky / AlmaLinux 8 - x86_64 - Debuginfo                                                     3.3 kB/s | 659  B     00:00
PostgreSQL 17 for RHEL / Rocky / AlmaLinux 8 - x86_64 - Debuginfo                                                     2.4 MB/s | 2.4 kB     00:00
Importing GPG key 0x08B40D20:
 Userid     : "PostgreSQL RPM Repository <pgsql-pkg-yum(at)lists(dot)postgresql(dot)org>"
 Fingerprint: D4BF 08AE 67A0 B4C7 A1DB CCD2 40BC A2B4 08B4 0D20
 From       : /etc/pki/rpm-gpg/PGDG-RPM-GPG-KEY-RHEL
...
Could not find debuginfo package for the following installed packages: postgresql17-server-17.6-1PGDG.rhel8.x86_64
Could not find debugsource package for the following installed packages: postgresql17-server-17.6-1PGDG.rhel8.x86_64

On 18/10/2025 18:56, badfilez(at)gmail(dot)com wrote:
> Hi all,
>
> Postgres from offitial repo on RHEL8
>
>
> Postgres likely created uncompressable data somewhere inside attached WAL (wal_compression zstd)
>
> on replica, I get
>
> 2025-10-18 15:40:50.843 MSK [1448] LOG:  entering standby mode
> 2025-10-18 15:40:50.865 MSK [1448] LOG:  redo starts at 1F35/D08DE298
> 2025-10-18 15:41:14.553 MSK [1381] LOG:  startup process (PID 1448) was terminated by signal 11: Segmentation fault
> 2025-10-18 15:41:14.553 MSK [1381] LOG:  terminating any other active server processes
> 2025-10-18 15:41:14.555 MSK [1381] LOG:  shutting down due to startup process failure
> 2025-10-18 15:41:14.677 MSK [1381] LOG:  database system is shut down

Attachment Content-Type Size
0000000600001F3600000030.gz application/gzip 13.1 MB

Browse pgsql-bugs by date

  From Date Subject
Next Message Marco Boeringa 2025-10-20 09:34:19 Re: Potential "AIO / io workers" inter-worker locking issue in PG18?
Previous Message Dilip Kumar 2025-10-20 02:30:26 Re: BUG #19074: pg_dump from v18 loses the NOT NULL flag in the inherited table field when dumping v17-databases