I am trying to deploy an ova/ovf located on the datastore. I have mapped the datastore drive using New-PSDrive -Location $dataStore -Name ds -PSProvider VimDatastore -Root "\"
Then using Import-vApp -Source "ds:\BaseServer.ova" -Datastore $dataStore -VMHost $vmHost -Name "BaseServer" -Force
gives me an error "Import-VApp File'ServerAddress@443\hs-datacenter\Datastore\BaseServer.ova' doesn't exist
if you go to the location via
cd ds: and list the directory the file is there.
Moderator edit by wila: Moved post from VMware {code} to VMware PowerCLI discussions
Importing an OVF via a PSProvider drive is currently not supported.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hi LucD,
Is there another to deploy the ovf from the datastore via powercli?
Thanks
Not that I know of.
You can download the OVF from the Datastore to local storage, via that PSProvider.
And then import the OVF from that local storage.
An alternative is to store the OVF in a ContentLibrary.
Since PowerCLI 12.2 you can use New-VM with an OVF in a ContentLibrary.
See New Release – VMware PowerCLI 12.2
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hi LucD,
I have powercli 12.2 installed.
When I tried to create a new content library using New-ContentLibrary -Datastore $dataStore -Name 'OVF'
an error occurred while trying to create new local content library.
Is this the correct method?
Regards
Trung
Which error?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
on calling New-ContentLibrary the actual error message was
An error occurred while trying to create new local content library.
What does the following return after the error?
$error[0].exception | select *
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
The error is clear, your vCenter is a pre-v6 version
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hi Luc,
I found that vcenter wasn't running at the time due to upgrade.
My next problem is on calling Get-ContentLibrary gives the error saying that 'vSphere single sign-on failed'.
Is there a way of doing this without single sign-on?
If not, can we setup a SSO without AD and DNS?
Regards
Trung
Running vSphere without DNS is not really an option.
Leaving out AD is no problem.
I don't see how you envisage leaving out SSO?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference