mbanxp
New Contributor III
I solved the issue by deleting all the asignments before deleting the metastore.

1. Access to Databricks CLI and authenticate
2. List metastores
>> databricks account metastores list

3. List wotrkspaces and check assignments
>> databricks account workspaces list
>> databricks account metastore-assignments get <workspace_id>


4. Delete assignments one by one
>> databricks account metastore-assignments delete <workspace_id> <metastore_id>

5. Force deletion of metastore because it still had some catalogs, credentials and different artifacts.
>> databricks account metastores delete <metastore_id> --force

View solution in original post