- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear,
Kindly share a PowerCLI script to find out the Fiber Channel HBA Firmware Version, Driver Version, BIOS version and FCODE version.
Regards
Rajesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Have a look at Re: Host Hardware info with HBA and nic driver information
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you actually try the script I pointed to ?
As far as I can tell, it has all that information.
If not, let me know which info is missing
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear,
Appricite your efforts.
I have run the script and found all the details inside. Is there any way to have the details in a table format so that it is easy to have in exel.
Thanks
Rajesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
To save the result to a CSV file, you can use the Export-Csv cmdlet.
Something like this
$report = Get-Datacenter | % {
$datacenter=$_
foreach($esx in Get-VMhost -Location $datacenter){
$esxcli = Get-EsxCli -VMHost $esx
$nic = Get-VMHostNetworkAdapter -VMHost $esx | Select -First 1 | select -ExpandProperty Name
$hba =Get-VMHostHBA -VMHost $esx -Type FibreChannel | where {$_.Status -eq "online"} | Select -First 1 |select -ExpandProperty Name
Get-VMHostHBA -VMHost $esx -Type FibreChannel | where {$_.Status -eq "online"} |
Select @{N="Datacenter";E={$datacenter.Name}},
@{N="VMHost";E={$esx.Name}},
@{N="HostName";E={$($_.VMHost | Get-VMHostNetwork).HostName}},
@{N="version";E={$esx.version}},
@{N="Manufacturer";E={$esx.Manufacturer}},
@{N="Hostmodel";E={$esx.Model}},
@{Name="SerialNumber";Expression={$esx.ExtensionData.Hardware.SystemInfo.OtherIdentifyingInfo |Where-Object {$_.IdentifierType.Key -eq "Servicetag"} |Select-Object -ExpandProperty IdentifierValue}},
@{N="Cluster";E={
if($esx.ExtensionData.Parent.Type -ne "ClusterComputeResource"){"Stand alone host"}
else{
Get-view -Id $esx.ExtensionData.Parent | Select -ExpandProperty Name
}}},
Device,Model,Status,
@{N="WWPN";E={((("{0:X}"-f $_.NodeWorldWideName).ToLower()) -replace "(\w{2})",'$1:').TrimEnd(':')}},
@{N="WWN";E={((("{0:X}"-f $_.PortWorldWideName).ToLower()) -replace "(\w{2})",'$1:').TrimEnd(':')}},
# @{N="Fnicvendor";E={$esxcli.software.vib.list() | ? {$_.Name -match ".*$($hba.hbadriver).*"} | Select -First 1 -Expand Vendor}},
@{N="Fnicvendor";E={$esxcli.hardware.pci.list() | where {$hba -contains $_.VMKernelName} |Select -ExpandProperty VendorName }},
@{N="fnicdriver";E={$esxcli.system.module.get("fnic").version}},
@{N="enicdriver";E={$esxcli.system.module.get("enic").version}},
# @{N="Enicvendor";E={$esxcli.software.vib.list() | ? {$_.Name -match ".net.*"} | Select -First 1 -Expand Vendor}}
@{N="Enicvendor";E={$esxcli.hardware.pci.list() | where {$nic -contains $_.VMKernelName} |Select -ExpandProperty VendorName }}
#@{N="Enicvendor";E={$esxcli.network.nic.list() | where {$vmnic.name -eq $_.vmnic1} | select -First 1 -ExpandProperty Description }}
}
}
$report | Export-Csv report.csv -NoTypeInformation -UseCulture
Last year QLogic acquired some of the Broadcom ethernet assets.
I suspect you might be seeing the driver provided vendor and the card manufacturer.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you replace 'fnic' and 'enic' with the modules you have on your HW ?
Run the following to get an overview of what PCI devices are present, and to get the correct names.
$esxName = 'MyEsx'
$esxcli = Get-EsxCli -VMHost $esxName
foreach($dev in $esxcli.hardware.pci.list()){
if($dev.ModuleName -ne 'None'){
$esxcli.system.module.get($dev.ModuleName) |
Select @{N='Device';E={$dev.DeviceName}},@{N='DeviceClass';E={$dev.DeviceClassName}},Module,Version
}
}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You will have to change 'MyEsx' with the name of your ESXi host/
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Based on that output it looks like you need replace the enic and fnic with elxnet and qlnativefc.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Excellent.
I got the required details.
Regards
Rajesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You are a genius!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Luc, once again great script!! However one critical piece of information that is missing is the firmware version of the HBA.
I know I can get the firmware via SSH by using the following methods:
## Brocade (BR-xxx) ##
cd /proc/scsi/bfa
ls -h
cat # | grep Version
## Qlogic & Emulex ##
/usr/lib/vmware/vmkmgmt_keyval/vmkmgmt_keyval -a | more
Is there anyway via PowerCli (maybe $esxcli.xxxx ???) to obtain the HBA firmware versions without the use of plink?
Thanks!!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Afaik, not at this point in time.
The only way I know is through the use of plink.exe (SSH) I'm afraid.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
looking for guidance on powercli one-liner for retrieving the HBA firmware version ..it can be retrieved from ESxi shell # esxcli –server=”servername or IP” –user=”username” –password”root password” ssacli cmd -q “controller slot=0 show config detail”
Source reference : https://support.hpe.com/hpsc/doc/public/display?sp4ts.oid=420496&docLocale=en_US&docId=emr_na-c05331...
Another source below shows he is close to get it , but I m even struck too not able to get the output with powercli #$esxcli.ssacli.cmd('"-q "controller all show status""')
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you try like this?
If that doesn't work, I advise to ask the question on the HP forum, this is a HP extension, nothing to do with PowerCLI
$esxcli = Get-EsxCli -VMHost MyEsx
$esxcli.hpssacli.cmd('"-q "controller slot=0 show config detail""')
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This is providing only the driver version, have any of you guys used this to get firmware version of the HBA?