Hello,
I have deployed few hundreds VMs but a large number of VMs did not succeed it sysprep and even did not failed sysprep but it is started.
Is it possible to write a script which can find shown below entries from (TASK & Event ) Events of the virtual machines.
Customization of VM <VM NAME> succeeded. Customization log located at C:\Windows\TEMP\vmware-imc\guestcust.log in the guest OS.
Thanks in advance
Try something like this
$entity = Get-VM
$start = (Get-Date).AddDays(-31)
Get-VIEvent -Entity $entity -Start $start |
where {$_ -is [VMware.Vim.CustomizationSucceeded]} |
Select CreatedTime,@{N="VM";E={$_.Vm.Name}},FullFormattedMessage,logLocation
It will return the entries for the last 31 days
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Try something like this
$entity = Get-VM
$start = (Get-Date).AddDays(-31)
Get-VIEvent -Entity $entity -Start $start |
where {$_ -is [VMware.Vim.CustomizationSucceeded]} |
Select CreatedTime,@{N="VM";E={$_.Vm.Name}},FullFormattedMessage,logLocation
It will return the entries for the last 31 days
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thank you LucD