vmware-archive / vsphere-storage-for-docker

vSphere Storage for Docker
https://vmware.github.io/vsphere-storage-for-docker
Apache License 2.0
251 stars 95 forks source link

Remove the status check of a volume on the plugin side #1230

Open pshahzeb opened 7 years ago

pshahzeb commented 7 years ago

The status of a volume in its meta data (result of GetVolume) is used to check if it is detached or not. Generally we don't make decision based on data in KV file and definitely not inside guest. Disk may be attached to some other VM. If neither refCnt nor mount map suggest disk is attached to this VM then we must issue attach to ESX. If it is already attached, it is a no-op from ESX perspective anyway.

govint commented 6 years ago

@pshahzeb can you quickly confirm that this issue needs fixing, given the current code and the recent changes in the refcnt and mount logic. Setting to rafiki as it should be either fixed or dropped.