Quantcast
Channel: VMware Communities : All Content - All Communities
Viewing all articles
Browse latest Browse all 179681

PowerCLI Script to get ESXi Network/Storage Firmware and Driver Version

$
0
0

Hi Admin,

 

Found this script which gets me firmware and driver info.

 

-------

$vmhosts = Get-Cluster "clust01" | get-vmHost

 

 

$report = @()

 

 

foreach( $ESXHost in $vmhosts) {

 

 

$HWModel = get-vmHost $ESXHost | Select Name, Model

$esxcli = Get-ESXcli -vmhost $ESXHost

 

 

if($HWModel.Model -eq "ProLiant BL460c Gen9")

{

 

 

$info = $esxcli.network.nic.get("vmnic0").DriverInfo | select Driver, FirmwareVersion, Version

$ModuleName = "$($info.Driver)"

$Firmware = "$($info.FirmwareVersion)"

$Driver = "$($info.Version)"

$elxnet = $esxcli.software.vib.list() | where { $_.name -eq "elxnet"}

$report += $info | select @{N="Hostname"; E={$ESXHost}},@{N="Hardware-Model"; E={$HWModel.Model}},@{N="Adapter-Firmware"; E={$Firmware}}, @{N="Network-Driver"; E={$Driver}}, @{N="FC-Driver"; E={$elxnet.version.substring(0,14)}}

 

 

}

 

}

 

$report | out-gridview

-------

 

Above works fine for my blade servers with CNAs.

 

But on some om my VMhost I have separate FC HBAs , and to get the driver info I use something like this :
$esxcli.system.module.get("lpfc") | Select-object @{N="VMHostName";E={$VMHostName}}, Module, Version

 

Possible to combine this line with my script someway?  

 

Thanks

Johan


Viewing all articles
Browse latest Browse all 179681

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>