When trying to delete an image from content library and you receive an error of:
“Cannot Delete File [Datastore] /PathtoContentLibraryVMDK”
Solution I found:
- Log into VCenter Server
- Select Content Library
- Right click content library item
- Rename item
- Delete item
I was trying to update some images i had on my home lab and i ran into the issue and issue when trying to delete some old templates from the library. I tried multiple times to delete the template i had stored only to receive the same error.
I investigated and found that the path from the error had no VMDK in it from the content library. That being said I had two options. Delete the folder in the datastore, which could corrupt the content library or rename the library item and try to delete again.
So when I renamed the content library item and deleted the item and it worked like a charm. I could not find a KB article for this particular issue or at least one that was relevant to content library but this worked for me.