mirror of
https://github.com/postgres/postgres.git
synced 2025-04-22 23:02:54 +03:00
Avoid 'FATAL: out of free buffers: time to abort !" error
during WAL recovery. Recovery failure is always serious.
This commit is contained in:
parent
b200d0993d
commit
50e3c60b95
@ -198,6 +198,8 @@ XLogReadBuffer(bool extend, Relation reln, BlockNumber blkno)
|
|||||||
Assert(InRecovery);
|
Assert(InRecovery);
|
||||||
while (lastblock <= blkno)
|
while (lastblock <= blkno)
|
||||||
{
|
{
|
||||||
|
if (buffer != InvalidBuffer)
|
||||||
|
ReleaseBuffer(buffer); /* must be WriteBuffer()? */
|
||||||
buffer = ReadBuffer(reln, P_NEW);
|
buffer = ReadBuffer(reln, P_NEW);
|
||||||
lastblock++;
|
lastblock++;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user