For tables that experience bulk deletes, loads, or frequent incremental updates, running the VACUUM command can help clean up tables and fight against query performance degradation. We recommend vacuuming your cluster on a weekly basis.
In order to vacuum your cluster, a superuser on your cluster just needs to run “VACUUM;” in Query or a SQL Script. If you want to only vacuum a single table, the syntax is “VACUUM schema.table;”. For more on the VACUUM command, you can check out the Redshift documentation here and here and Postgres documentation here.
VACUUM is a resource-intensive command and should be scheduled to run when there will be minimal activity on the cluster. Vacuuming can only be done by superusers or the table owner.
Comments
0 comments
Please sign in to leave a comment.