You signed in with another tab or window.Reload to refresh your session.You signed out in another tab or window.Reload to refresh your session.You switched accounts on another tab or window.Reload to refresh your session.Dismiss alert
Fix aboriginal mistake in lazy VACUUM's code for truncating away
no-longer-needed pages at the end of a table. We thought we could throw awaypages containing HEAPTUPLE_DEAD tuples; but this is not so, because suchtuples very likely have index entries pointing at them, and we wouldn't haveremoved the index entries. The problem only emerges in a somewhat unlikelyrace condition: the dead tuples have to have been inserted by a transactionthat later aborted, and this has to have happened between VACUUM's initialscan of the page and then rechecking it for empty in count_nondeletable_pages.But that timespan will include an index-cleaning pass, so it's not all thathard to hit. This seems to explain a couple of previously unsolved bugreports.