Can I please get your help on getting a PowerCLI script with the ability to select the date I want? for example I know that one of the HBAs on some hosts were offline two weeks ago. it is resolved now but I want to be able to obtain the data and also choose the date I want for all the fibre channel HBAs and WWNs and WWPNs for each ESXi host in vCenter.
Thank you
Get-Cluster clustername | Get-VMhost | Get-VMHostHBA -Type FibreChannel | Select VMHost,Device,@{N="WWN";E={"{0:X}" -f $_.PortWorldWideName}} | Sort VMhost,Device
Moderator: Moved to PowerCLI
If I understand the question correctly, you want a kind of 'timemachine' to run the Get-VMHostHba and Get-ScsiLun cmdlet for any point in time.
I'm afraid that is not possible with those cmdlets.
They always return the current situation.
What you could do is have a look at the events and look for indirect events like LUN getting an APD status at that time.
Another option is search the logs.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thank you bewe. But I need to get it dated two weeks ago. LucD mentioned that it is not possible.
Thank you so much LucD
Appreciate it.