VACUUM fails with “Failed to vacuum” error

Drop the SHALLOW CLONE table using DROP command and then run VACUUM.

Written by MuthuLakshmi.AN

Last published at: October 30th, 2025

Problem

Attempting to run VACUUM on a Delta table fails with the following error message in Databricks Runtime 16.1 and below. 

Failed to vacuum <table-name> with error requirement failed: No state defined for this table. Is this really a Delta table? Refusing to garbage collect.

 

Cause

SHALLOW CLONE of the source table was manually deleted by removing its corresponding S3 path instead of using the DROP TABLE statement. 

 

Unity Catalog is not notified to de-register the SHALLOW CLONE when it is removed this way, so VACUUM tries to protect the deleted table by throwing the error.

 

Solution

First, use the DROP TABLE statement to properly remove any SHALLOW CLONE tables associated with the source table you are trying to VACUUM.

   ```sql
   DROP TABLE <shallow-clone-name>;
   ```

 

Then perform VACUUM. For immediate results, ensure the cluster or warehouse running the VACUUM command is using Databricks Runtime 16.2 or above.

   ```sql
   VACUUM TABLE <base-table-name>;
   ```

 

On Databricks Runtime versions 16.1 and below, you may need to wait 25 days after manually dropping a SHALLOW CLONE before running VACUUM on the base table.