> > The same problem exists in 8.1 too. See this thread
> > http://archives.postgresql.org/pgsql-bugs/2006-04/msg00177.php
> > Tom and Magnus tracked down a cause, but I don't think a
> fix was ever
> > implemented.
>
> Thomas seems to have two different issues there: the "could
> not rename file" problem on the pg_xlog file is probably
> explained by the mechanism we identified back then (and I'm
> not sure why no fix has been installed), but there is no
> known reason other than antivirus software for the "could not
> fsync" problem.
>
> As for fixing the problem we do understand: ISTM it's just an
> awful idea for pgrename and pgunlink to be willing to loop
> forever. I think they should time out and report the failure
> after some reasonable period (say between 10 sec and a minute).
>
> If we simply made that change, then the behavior when there's
> an idle backend sitting on a filehandle for an old xlog
> segment would be that checkpoints would fail at the
> MoveOfflineLogs stage, which would not be fatal, but it'd be
> annoying. We'd probably want to further tweak
> InstallXLogFileSegment so that rename failure isn't an ERROR,
> at least not on Windows. (I think we could just make it
> return false, which'd cause the caller to try to delete the
> xlog segment, which should work even though rename doesn't.)
>
> I'm not in a position to test this though. Magnus or Bruce?
I haven't reproduced this on my box. But if you can give me a patch to
try I can build binaries for Thomas to test, if he can do testing but
not building.
//Magnus
---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?
http://www.postgresql.org/docs/faq