binoche's Posts

I see, thanks
thanks LucD, when logged into the standalone host ui and I can see its history tasks, so I am wondering maybe I did not use the api correctly?
yes , get-taskplus failed due to similar error, so I tried to custom $filter myself, sorry for any confusion PowerCLI C:\> Get-TaskPlus Exception calling "CreateCollectorForTasks" with "1" ... See more...
yes , get-taskplus failed due to similar error, so I tried to custom $filter myself, sorry for any confusion PowerCLI C:\> Get-TaskPlus Exception calling "CreateCollectorForTasks" with "1" argument(s): "The operation is not supported on the object." At line:155 char:7 +       $tCollector = Get-View ($tskMgr.CreateCollectorForTasks($filter ... +       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException     + FullyQualifiedErrorId : VimException You cannot call a method on a null-valued expression. At line:158 char:9 +         $tCollector.ResetCollector() +         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : InvalidOperation: (:) [], RuntimeException     + FullyQualifiedErrorId : InvokeMethodOnNull You cannot call a method on a null-valued expression. At line:165 char:9 +         $tasks = $taskReadOp.Invoke($WindowSize) +         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : InvalidOperation: (:) [], RuntimeException     + FullyQualifiedErrorId : InvokeMethodOnNull PowerCLI C:\>
Dear LucD, thanks for your great get-taskplus, it works well against virtual center, but failed repeatedly against standalone host vSphere 6.5, PowerCLI C:\> $si = Get-View ServiceInstanc... See more...
Dear LucD, thanks for your great get-taskplus, it works well against virtual center, but failed repeatedly against standalone host vSphere 6.5, PowerCLI C:\> $si = Get-View ServiceInstance PowerCLI C:\> $tskMgr = Get-View $si.Content.TaskManager PowerCLI C:\> $filter = New-Object VMware.Vim.TaskFilterSpec PowerCLI C:\> $tCollector = Get-View ($tskMgr.CreateCollectorForTasks($filter)) Exception calling "CreateCollectorForTasks" with "1" argument(s): "The operation is not supported on the object." At line:1 char:1 + $tCollector = Get-View ($tskMgr.CreateCollectorForTasks($filter)) + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException     + FullyQualifiedErrorId : VimException PowerCLI C:\> looks like $filter not correct? do you know how to fix it? thanks
my bad, looks like the previous initialization of powercli failed, once reloaded, I see it! thank you Sir, have a nice day!
thank you Sir! I have got the below 5 items, how to know which one is VMware.Vim.VirtualMachineConfigSpec? really appreciate! PowerCLI C:\> [appdomain]::CurrentDomain.GetAssemblies() | wher... See more...
thank you Sir! I have got the below 5 items, how to know which one is VMware.Vim.VirtualMachineConfigSpec? really appreciate! PowerCLI C:\> [appdomain]::CurrentDomain.GetAssemblies() | where {$_.Location -match 'vSphere PowerCLI'} | %{$_.ExportedTypes}|ForEach-Object {$_.fullname}|Where-Object {$_ -match "VirtualMachineConfigSpec"} RbdApi.VirtualMachineConfigSpec SpbmProxyService.VirtualMachineConfigSpec SmsProxyService.VirtualMachineConfigSpec VsanHealthProxyService.VirtualMachineConfigSpec IntegrityApi.VirtualMachineConfigSpec PowerCLI C:\>
Hi Guru, do you know how I can find out all objects starting with VMware.Vim.? many thanks such as VMware.Vim.VirtualMachineConfigSpec  VMware.Vim.VirtualDeviceConfigSpec I was using freque... See more...
Hi Guru, do you know how I can find out all objects starting with VMware.Vim.? many thanks such as VMware.Vim.VirtualMachineConfigSpec  VMware.Vim.VirtualDeviceConfigSpec I was using frequently, but how to know what other objects starting with VMware.Vim...
Hi Guru, I want to work with PbmServiceInstance using powercli, do you know how I can get this object using powercli? I am looking for something like such as get-view ServiceInstance, thanks i... See more...
Hi Guru, I want to work with PbmServiceInstance using powercli, do you know how I can get this object using powercli? I am looking for something like such as get-view ServiceInstance, thanks in advance
not sure if I understand your question correctly, in windows 2012, powershell its cmdlet get-disk should report disk offline or online?
got it, thank you Sir Simon
thank you Sir, right, I can keep watching this task, but does it mean we are unable to catch this type of exception? Simon
Try { $vmview.ReconfigVM($spec)} Catch{$_.exception.message} it can print the exception message, but how ReconfigVM_Task can? Simon
Hi Guru, I was using ReconfigVM_Task to reconfigure my vm, this task will be running in the background but frequently it could be exception at once, but I was not been informed in the console,... See more...
Hi Guru, I was using ReconfigVM_Task to reconfigure my vm, this task will be running in the background but frequently it could be exception at once, but I was not been informed in the console, I wish I can print such as what type exception in the console, do you know how I should do? many thanks Simon
looks like the below one is changeId, ($newsnapview.Config.Hardware.Device | where { $_.Key -eq 2000 }).backing.changeid
Hi folks, I am learning this function $vmview.QueryChangedDiskAreas(), its 4th parameter changeId, this function works using * as changeId, do you know how I can get a real changeId? thanks... See more...
Hi folks, I am learning this function $vmview.QueryChangedDiskAreas(), its 4th parameter changeId, this function works using * as changeId, do you know how I can get a real changeId? thanks in advance,
just send it in e-mail, thank you Sir, Simon
thank you Sir, could you please post the script importing local ovf file? it still can teach me a lot, thanks Simon
thank you sir, when using vCenter, the import wizard can work with both local windows path and the www url, so I was wondering there could be one api powercli can use? Simon
Hi folks, as I know Import-VApp can import existing ovf to my vc/vsphere and its ovf must be local to windows for example -Source "c:\vApps\WebServer\WebServer.ovf", but the source could b... See more...
Hi folks, as I know Import-VApp can import existing ovf to my vc/vsphere and its ovf must be local to windows for example -Source "c:\vApps\WebServer\WebServer.ovf", but the source could be from www for example http://www.foo.com/samplevm.ovf, so far I have to download samplevm.ovf locally to windows and them import-vapp to import it, I learned ovftool.exe can do this job but could powercli import from www to my vsphere without downloading locally? really appreciate! Simon
my bad, get-vmhost|get-scsilun should return CDROM including its device path already, thanks Simon