主权项 |
1. A method for deleting datastore paths corresponding to deleted virtual machines on a host computer, the method comprising:
obtaining a first set of datastore paths from a datastore, the first set of datastore paths corresponding to a first set of virtual machines; obtaining a second set of datastore paths, the second set of datastore paths corresponding to all existing virtual machines on the host computer, wherein the first and second sets of datastore paths identify locations on one or more physical disks of the datastore; comparing the first set of datastore paths with the second list set of datastore paths; and deleting, based on the comparison, datastore paths in the first set of datastore paths that are not contained in the second set of datastore paths from the one or more physical disks of the datastore, the deleted datastore paths representing mappings to files corresponding to one or more deleted virtual machines, and the deleted one or more virtual machines having been base image virtual machines from which linked clone virtual machines were created prior to deletion. |