model-writtenrun 9158 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Yuli Khodorkovskiy reported that early syslogger startup triggered a shared-memory assertion with EXEC_BACKEND and logging_collector enabled, then proposed moving shared-memory initialization earlier in #1 and #2.
- Tom Lane objected that the proposed ordering weakened early logging and might affect postmaster.pid readers, suggesting shared-memory detach handling instead; Michael Paquier implemented a merger of the detach routines in #3 and #5.
- Tom explained that an inherited shared-memory address does not mean an EXEC_BACKEND child is attached, so the routines needed distinct semantics; Michael replaced the merger with assertion removals and reported Windows testing in #6 and #7.
- Michael discovered that existing tests could pass despite syslogger failure and that temporary-file cleanup could delete the child's parameter file before it was read; Tom proposed separating root-directory cleanup from other temporary files in #8, #12, and #13.
- Michael's expanded patch avoided reserving Windows shared memory for children that would not use it and split temporary-file cleanup, but further recovery-test failures led him to recommend reverting the original early-start change before beta in #15.
- Tom agreed that Windows assumptions and races made a trustworthy beta fix impractical, while sketching explicit shared-memory state and child startup instructions as a possible future design in #18 and #19.
- Tom announced the revert in #22 and committed 8334515529, restoring the previous startup sequence rather than landing the assertion-removal patches.
- Tom identified that the logrotate test checked only a file created by the postmaster, proposed checking actual logged errors and timestamp-based rotation in #23, and implemented that discussion directly in 9d5c22d28f, announcing completion in #25.
- Michael's subsequent test showed that the improved test still missed an initial syslogger crash followed by successful restart; Tom explained that restart occurred after shared memory existed in #27 and #29.
- Tom's analysis of orphan backends established that shared-memory initialization must precede potentially destructive directory operations, leading to a new patch that postponed socket opening until after syslogger startup in #29 and #30.
- Michael raised external-PID compatibility concerns in #31, and Peter Eisentraut supported deferring the work beyond PostgreSQL 12; Tom retained the patch for a later commitfest in #32 and #33.
- After several months, Tom refreshed the patch once port-independent shared-memory keys were available, checked pg_ctl's assumptions, documented flexible PID-file ordering, and delayed recording postmaster options until sockets were open in #34.
- Michael reviewed and tested the refreshed patch on Windows and renewed his external-PID ordering concern; Tom preserved socket-before-external-PID ordering and placed potentially slow temporary-file cleanup afterward in #35, #36, and #38.
- Final EXEC_BACKEND testing exposed the parameter-file cleanup race again, so Tom split out early cleanup of that directory and committed the revised final patch as 9a86f03b4e; his closing message #40 reports the fix and landing, with no further patch pending.