こんにちは、6 つの Vspher サーバーがあり、私の Vcenter は Linux ベースで、バージョンは Vsphere 5.5 です。
PowerCLI スクリプトを使用して VMware 環境を自動的に管理しようとしています。
インターネットでスクリプトを取得しましたが、エラーが発生しました。助けてくれたLucdとKunaludapiに感謝します。
これについては助けが必要です。
Move-VM : Cannot convert 'System.Object[]' to the type 'VMware.VimAutomation.Vi
Core.Types.V1.Inventory.VIContainer' required by parameter 'Destination'. Speci
fied method is not supported.
At C:\Scheduled tasks\Vmware DRS Script.ps1:103 char:53
+ $objVM | move-vm -destination <<<< (get-vmhost $strDe
st);
+ CategoryInfo : InvalidArgument: (:) [Move-VM], ParameterBinding
Exception
+ FullyQualifiedErrorId : CannotConvertArgument,VMware.VimAutomation.ViCor
e.Cmdlets.Commands.MoveVM