Saturday, March 5, 2016

VMware PowerCLI move powered on vm to a specific Folder

$vmm=Get-VMHost jockey-host01 | Get-VM | Where-Object {$_.PowerState -eq "PoweredOn"} |select name


foreach($nvm in $vmm)
{

Move-Vm -VM $nvm.name -Destination(Get-Folder -Name PowerON-VMS)

}

1 comment:

Thanks for showing interest in tech-jockey.

Content of this blog has been moved to GITHUB

Looking at current trends and to make my content more reachable to people, I am moving all the content of my blog https://tech-jockey.blogsp...