Some times we may need to find out whether VMDK files are shared with some other vms. Using below script we an easily find that. We just need to give the vm name & it will check for all the vmdk paths in all the VMS
$vmname=read-host -Prompt “Enter the VM Name”
if (get-vm $vmname -erroraction SilentlyContinue)
$vdisk=get-vm $vmname |Get-VMHardDiskDrive
foreach ($allvm in $allvms)
if ($allvm.name -ne $vmname)
$vmdiskpath=get-vm $allvm |get-harddisk
foreach($disk in $vdisk)
if ($vmdiskpath.filename -eq $disk.filename)
$msg=”There is a VMDKS sharing with ”
Write-Host $fullmsg -ForegroundColor DarkGreen
Write-Host “VM is not available in the vCenter, please check the vm name”
Operating system clustering is one of the major and popular high availability mechanism in system infrastructure products. Advantage of the os clustering is it can identify the application level failure.
As a systems administrators most of the time we may need to work with MS windows failover clusters. Most of the file servers and SQL clusters are depend on this failover cluster technology. Most of the situation one of the main requirement is this failover cluster is shared lus/disk. Earlier most of the time we sued to have minimum two physical servers for this cluster operation which is directly connect to SAN device(Shared storage). But to get the benefits of virtualization platform and reduce the cost , now we have to use same cluster features on top of the virtualization platform.
1. In my below example Im using two test virtual machines.
2. Now we need to add new scsi controller per this vm
Continue reading “How to use VMDK sharing for Guest OS clustering”