Currently working on a project to decommission a very old non updated vcloud infrastructure for a customer who wants to move back to vsphere. They don’t really utilize the full vCloud feature set as it was put in as part of a larger project that never came to fruition. Part of the first step should be to see what chain linked virtual machines we have, as if not when we attempt to migrate them away we are just going to give ourselves a world of pain. The PowerCLI below should identify all the virtual machines within the VDC’s and how long the chain length is.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | if( (Get-Module -Name "VMware.VimAutomation.Cloud" -ErrorAction SilentlyContinue) -eq $null) {Import-Module VMware.VimAutomation.Cloud} Connect-CIServer -Server "your vcloud director fqdn" -ErrorAction Stop $VApps = Get-CIVApp Foreach($vapp in $VApps){ $vms = $vapp.ExtensionData.children.vm foreach($vm in $vms){ $CL = $vm.VCloudExtension.any.VirtualDisksMaxChainLength if($CL -gt 1){ $info = $vm.Name + " chain length=" + $CL $info} }} |
Leave a Reply