VMware Cloud Community
tgbennett
Enthusiast
Enthusiast
Jump to solution

AutoDeploy Add-EsxSoftwareDepot from networked location

I am trying to implement AutoDeploy on Cisco UCS servers using the script from alanrenouf as the basis. I want any of my co-workers to be able to run the script from thier local workstation. Where i run into a problem is with the  Add-EsxSoftwareDepot cmdlet with the depot on a network share. The depot is a custom image built with ImageBuilder that lives on MyVC.

If I use a UNC i get the error

PowerCLI C:\> Add-EsxSoftwareDepot "\\MyVC\ImageBuilder\ESXi-5.0.0-469512-standard-UCS.zip"

Add-EsxSoftwareDepot : Could not download from depot at zip:C:\ImageBuilder\ESXi-5.0.0-469512-standard-UCS.zip?

index.xml, skipping (('zip:C:\\ImageBuilder\\ESXi-5.0.0-469512-standard-UCS.zip?index.xml', '', "Error extracti

ng index.xml from C:\\ImageBuilder\\ESXi-5.0.0-469512-standard-UCS.zip: [Errno 2] No such file or directory: 'C

:\\\\ImageBuilder\\\\ESXi-5.0.0-469512-standard-UCS.zip'"))

At line:1 char:21

+ Add-EsxSoftwareDepot <<<<  "\\MyVC\ImageBuilder\ESXi-5.0.0-469512-standard-UCS.zip"

    + CategoryInfo          : ReadError: (System.String[]:String[]) [Add-EsxSoftwareDepot], Exception

    + FullyQualifiedErrorId : ConnectDepotError,VMware.ImageBuilder.Commands.AddDepot

If I use a psdrive V:

new-psdrive -name V -psprovider filesystem -root \\MyVC\imagebuilder

i get the error

PowerCLI C:\> Add-EsxSoftwareDepot "v:\ESXi-5.0.0-469512-standard-UCS.zip"
Add-EsxSoftwareDepot : Could not download from depot at zip:V:\ESXi-5.0.0-469512-standard-UCS.zip?index.xml, sk
ipping (('zip:V:\\ESXi-5.0.0-469512-standard-UCS.zip?index.xml', '', "Error extracting index.xml from V:\\ESXi-
5.0.0-469512-standard-UCS.zip: [Errno 2] No such file or directory: 'V:\\\\ESXi-5.0.0-469512-standard-UCS.zip'"
))
At line:1 char:21
+ Add-EsxSoftwareDepot <<<<  "v:\ESXi-5.0.0-469512-standard-UCS.zip"
    + CategoryInfo          : ReadError: (System.String[]:String[]) [Add-EsxSoftwareDepot], Exception
    + FullyQualifiedErrorId : ConnectDepotError,VMware.ImageBuilder.Commands.AddDepot

I get the same error if I cd to V:\ first.

If I copy the same depot,ESXi-5.0.0-469512-standard-UCS.zip, local to the C:\ drive it works fine.

Does anyone know what might be going on here or have some insight?

thanks,

Tim

Reply
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

I know that a local file path or an URL is supported, not sure about an UNC or PSDrive.

Afaik those last 2 are not supported


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

Reply
0 Kudos
4 Replies
LucD
Leadership
Leadership
Jump to solution

I know that a local file path or an URL is supported, not sure about an UNC or PSDrive.

Afaik those last 2 are not supported


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos
tgbennett
Enthusiast
Enthusiast
Jump to solution

thanks for your super fast reply. Along the same lines. Is there a way to get my custom SoftwareDepot exposed as a URL on my vC?

Reply
0 Kudos
LucD
Leadership
Leadership
Jump to solution

Sorry, haven't tried if that is possible from the vCenter without installing additional SW on there.

But shouldn't you be able to do this from any web server you have in your environment ?

The web server just has to offer the ZIP file I assume


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

tgbennett
Enthusiast
Enthusiast
Jump to solution

interesting thought. Might try that. Thanks.

Reply
0 Kudos