Alexander Korotkov <aekorotkov@gmail.com> writes:
> I've one note not directly related to buffering build. While I debugging
> buffering GiST index build, backend was frequently crashed. After recovery
> partially built index file was remain. Do we have some tool to detect such
> "dead" files? If not, probably we need some?
Well, it's not that hard to check for orphan files (I think
contrib/oid2name can do that, or perhaps could be extended to). I don't
like the idea of the postmaster automatically removing such files, if
that's where you were headed. Too much risk of deleting important data.
regards, tom lane