I am having some trouble installing a VIB (HP HSPA driver) via PowerCLI.. can someone tell me what I am missing here? Thanks!
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> Get-Esxcli -vmHost xx
===========================
EsxCli: xx
Elements:
---------
device
esxcli
fcoe
graphics
hardware
iscsi
network
sched
software
storage
system
vm
vsan
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $hspavibpath="/vmfs/volumes/xx/scsi-hpsa-5.5.0.60-1OEM.550.0.0.1331820.x86_64
.vib"
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.install($hspavibpath)
You cannot call a method on a null-valued expression.
At line:1 char:29
+ $esxcli.software.vib.install <<<< ($hspavibpath)
+ CategoryInfo : InvalidOperation: (install:String) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
Are you connected to the ESXi server, and not the vCenter ?
See Re: Installing driver vib with get-esxcli
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Yeah.. that was actually my first mistake
Does
$esxcli.software.vib.list()
work and return anything ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Just noticed, you have to pass $null for the other parameters on the method.
See the other thread I linked to
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I get this same error.. How do I know how many $null entries I need?
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.list()
You cannot call a method on a null-valued expression.
At line:1 char:26
+ $esxcli.software.vib.list <<<< ()
+ CategoryInfo : InvalidOperation: (list:String) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
If you do
$esxcli.software.vib.install.OverloadDefinitions
it will list all the parameters.
And you can count/copy them from the other thread
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I get nothing back when I run that command
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.install
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
Sorry, should have been
$esxcli.software.vib.install.OverloadDefinitions
But why don't you just copy the parameters from that other thread, it is the same type of method call ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Still nothing..
Name Port User
---- ---- ----
x 443 root
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.install.OverloadDefinitions
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
I tried copying the parameters.. same error.
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> Get-Esxcli -vmHost x
===========================
EsxCli: x
Elements:
---------
device
esxcli
fcoe
graphics
hardware
iscsi
network
sched
software
storage
system
vm
vsan
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $hspavibpath="/vmfs/volumes/x/scsi-hpsa-5.5.0.60-1OEM.550.0.0.1331820.x86_64
.vib"
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.install($null,$null,$null,$null,$null,$null,$null,$null,$hspav
ibpath)
You cannot call a method on a null-valued expression.
At line:1 char:29
+ $esxcli.software.vib.install <<<< ($null,$null,$null,$null,$null,$null,$null,$null,$hspavibpath)
+ CategoryInfo : InvalidOperation: (install:String) [], RuntimeException
+ FullyQualifiedErrorId : InvokeMethodOnNull
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
Is that against an ESXi 5.5 server ?
Can you try the following, and see where it fails
$esxcli
$esxcli.software
$esxcli.software.vib
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
All I get is a blank like on each.. lol
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
That would mean that your Get-EsxCli did not work correctly.
You did do a
$esxcli = Get-EsxCLi -VMHost MyESXi
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
HA! *facepalm*
Making progress now.. I think the issue is I am not sure what parameters I need to define for this vib.. i.e. all the nulls
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli = Get-EsxCLi -VMHost x
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $hspavibpath="/vmfs/volumes/x/scsi-hpsa-5.5.0.60-1OEM.550.0.0.1331820.x86_64
.vib"
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI> $esxcli.software.vib.install($null,$null,$null,$null,$null,$null,$null,$null,$hspav
ibpath)
Message : Host is not changed.
RebootRequired : false
VIBsInstalled :
VIBsRemoved :
VIBsSkipped : {Hewlett-Packard_bootbank_scsi-hpsa_5.5.0.60-1OEM.550.0.0.1331820}
PowerCLI C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI>
Hello. I tried with that code and work succesfully
first..i leave my bundle vib on a datastore, to be access for all my host
then set the variable $ZIP with the path
$zip="/vmfs/volumes/TEMPLATES_WINDOWS_BUETY/VIB/QLG-NetXtremeII-6.0-offline_bundle-3234961.zip"
and for the last use this command
$esxcli.software.vib.install($zip, $null, $null, $null, $null, $null, $null, $null, $null)
and.. Bingo!!!
PowerCLI D:\> $esxcli.software.vib.install($zip, $null, $null, $null, $null, $null, $null, $null, $null)
Message : The update completed successfully, but the system needs to be
rebooted for the changes to be effective.
RebootRequired : true
VIBsInstalled : {QLogic_bootbank_misc-cnic-register_1.712.70.v55.1-1OEM.550.0.
0.1331820,
QLogic_bootbank_net-bnx2_2.2.5k.v55.1-1OEM.550.0.0.1331820, QL
ogic_bootbank_net-bnx2x_2.712.70.v55.3-1OEM.550.0.0.1331820, Q
Logic_bootbank_net-cnic_2.712.70.v55.3-1OEM.550.0.0.1331820...
}
VIBsRemoved : {Broadcom_bootbank_misc-cnic-register_1.710.30.v55.1-1OEM.550.
0.0.1331820,
Broadcom_bootbank_net-bnx2_2.2.5f.v55.6-1OEM.550.0.0.1331820,
Broadcom_bootbank_net-bnx2x_2.710.39.v55.2-1OEM.550.0.0.133182
0, Broadcom_bootbank_net-cnic_2.710.35.v55.5-1OEM.550.0.0.1331
820...}
VIBsSkipped :