1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | # found https://vmscribble.com Write-Host" The script will add a new disk drive on the first SCSI adapter based on the VM memory size times 1.5 " # Connect to your vCenter $vCenter=Read-Host"Enter the vCenter FQDN" Connect-VIServer$vCenter Write-Host" " $textfile=Read-Host"Enter the location and text file name of VMs in scope" $listofvms=Get-Content-path$textfile # change 1.5 to another multiple in line: $size = $thevm * 1.5 foreach($vmin$listofvms) { $thevm=get-vm$vm|Select-Object-ExpandPropertyMemoryGB $size=$thevm*1.5 get-vm$vm|New-HardDisk-CapacityGB$size|Select-ObjectParent,Filename,CapacityGB } # Disconnect from the vCenter Disconnect-VIServer$vCenter-Confirm:$false |