model-writtenrun 9280 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Tom Lane reported intermittent Windows pg_ctl restart and PID-file failures and identified frontend open/fopen calls lacking the sharing behavior of PostgreSQL's Windows wrappers as a possible cause #1; Badrul Chowdhury volunteered to reproduce the failures #2.
- The frontend wrapper change subsequently landed as 0ba06e0bfb, authored by Laurenz Albe through the patch series in thread #38805, with this thread cited for the pg_ctl concurrency problem.
- In July 2019, Zharkov Roman revived the investigation with a patch that enabled wrappers locally in pg_ctl, renamed lock files before deletion, and waited for the old cmd.exe process to release the log file during stops and restarts #3.
- Tom Lane pointed out that the wrapper change already existed on HEAD, questioned the deletion workaround, and suggested simplifying the shell handling or moving log redirection into the postmaster; Roman acknowledged testing an older branch and asked whether the shell could be eliminated #4 #5.
- Michael Paquier explained that Windows obscures pending-deletion errors, Roman defended renaming before deletion, and Kyotaro Horiguchi explored native Windows interfaces as a possible way to obtain the underlying status but had not made that approach work #6 #7 #9.
- After Michael requested clarification about the tested branch, Roman explained that the earlier wrapper backport had been reverted on REL_11_STABLE; Michael acknowledged the failed backport and favored backpatching the subsequent fixes while investigating any remaining failures on current branches #8 #10 #11.
- Tom identified 0ba06e0bfb as the relevant fix and supported backpatching it with its cleanup, while cautioning that failures persisted; Michael then found two recent buildfarm failures confirming that the problem was reduced but unresolved #12 #14.
- Roman reproduced the hidden pending-deletion failure on REL_12_STABLE with greatly increased pg_ctl polling, then independently reproduced cmd.exe log-file sharing failure there; the thread ends with both remaining races demonstrated and no revised patch or landing of the July proposal recorded #15 #16.