Receive the error message "ERROR: HEAP_MOVED_OFF was expected" when attempting a VACUUM FULL:
psql:vacuum_bloated_tables.sql:272: ERROR: HEAP_MOVED_OFF was expected (vacuum.c:3175) (seg51 sdw7.gphd.local:1028 pid=145114) (cdbdisp.c:1326)
The most common causes for this error are:
- There is a separate vacuum running on the table
- The previous vacuum full on the table failed and left in an inconsistent state
An alternative to remove bloat and free up disk space without using VACUUM FULL is to redistribute the table. However, this will only work for user-created tables; catalog tables can not be redistributed.
If the redistribute works, the bloat on the table should no longer be there. Running a VACUUM FULL again will help to ensure that the error is gone.