Problem
After an Azure Unity Catalog-registered workspace is deleted with the "Delete default workspace storage permanently" option selected, you try to access catalogs created in that workspace from another workspace.
You also notice:
- These catalogs are grayed out in the catalog explorer.
- It is not possible to change the ownership of the affected catalogs.
- Running the
SHOW CATALOGS;
command as a metastore admin does not list or return the affected catalogs.
Cause
Permanent deletion of workspace storage can lead to orphaned catalog entries in the Unity Catalog metastore. The catalogs lose their associated workspace context but remain in the system, now partially registered.
Solution
Force delete the catalogs in your metastore or bind the catalog(s) to a new workspace.
Force delete a catalog
Important
Force deletion requires both metastore owner or admin privileges for the metastore where the catalog resides, and workspace admin on the workspace where you see the grayed out catalogs.
If you are already an account admin, you can make your account a metastore admin. Review the “Assign a metastore admin” section of the Admin privileges in Unity Catalog documentation.
- Download the Databricks CLI to your local machine and authenticate your workspace. Instructions are available in the Install or update the Databricks CLI documentation and the Authentication for the Databricks CLI documentation.
- Run the following command.
databricks unity-catalog catalogs delete --name <catalog-to-delete> --force
Bind a catalog to another workspace
If you want to keep a catalog and assign it to another workspace, a metastore admin or the catalog owner can bind the catalog to this other workspace.
Review the “Bind a catalog to one or more workspaces” section of the Limit catalog access to specific workspaces documentation for instructions.