Re: [WIP]Vertical Clustered Index (columnar store extension) - take2 - Mailing list pgsql-hackers

From Timur Magomedov
Subject Re: [WIP]Vertical Clustered Index (columnar store extension) - take2
Date
Msg-id b0183172fbe8fbf4260d10df50a57127753eba68.camel@postgrespro.ru
Whole thread Raw
In response to Re: [WIP]Vertical Clustered Index (columnar store extension) - take2  (Peter Smith <smithpb2250@gmail.com>)
List pgsql-hackers
Hello Peter!
There is a code in vci_ros.c that initializes xl_heap_inplace xlrec.
Comment says this code was taken from src/backend/access/heap/heapam.c.
It was fine for Postgres 17 and earlier however struct xl_heap_inplace
has 6 fields, not one since commit 243e9b40f1b2. So nmsgs field of
xlrec has some random uninitialized value from stack. It goes to WAL
and in case of big nmsgs it can cause segfault during server startup.

Here are backtrace of a segfault while applying WAL on server startup
and a patch that initializes all necessary fields of xlrec to avoid bad
WAL records.

--
Regards,
Timur Magomedov


Attachment

pgsql-hackers by date:

Previous
From: Álvaro Herrera
Date:
Subject: Re: splitting src/bin/scripts/vacuumdb.c
Next
From: Tom Lane
Date:
Subject: Re: [PATCH] GROUP BY ALL