Eğer birden fazla sunucudaki lisanların expire date ve seri numarası bilgilsine ihtiyaç duyarsanız aşağıdaki script ile görüntüleyebilir ve CSV file olarak kayıt edebilirsiniz.
Connect-VIServer -Server vcenter.vmware.lab -User "administrator@vsphere.local" -Password "password" $vSphereLicInfo = @() $ServiceInstance = Get-View ServiceInstance Foreach ($LicenseMan in Get-View ($ServiceInstance | Select -First 1).Content.LicenseManager) { Foreach ($License in ($LicenseMan | Select -ExpandProperty Licenses)) { $Details = "" |Select VC, Name, Key, Total, Used, ExpirationDate , Information $Details.VC = ([Uri]$LicenseMan.Client.ServiceUrl).Host $Details.Name= $License.Name $Details.Key= $License.LicenseKey $Details.Total= $License.Total $Details.Used= $License.Used $Details.Information= $License.Labels | Select -expand Value $Details.ExpirationDate = $License.Properties | Where { $_.key -eq "expirationDate" } | Select -ExpandProperty Value $vSphereLicInfo += $Details } } $vSphereLicInfo | Format-Table -AutoSize $vSphereLicInfo | Export-Csv -Path .\keyler2.csv -NoTypeInformation notepad.exe .\keyler2.csv Disconnect-VIServer -Server * -Confirm:$false