Is port 902 open between the ESXi node that hosts the VM and the VM?
You could test with a ssh over port 902.
Did you check the vmware.log (in the VM's folder) for clues?Blog: http://lucd.info | Twitter: @LucD22 | PowerCLI Reference co-author: http://tinyurl.com/hkn4glz
Thanks for the suggestion. Port 902 and it is closed on our side but reviewing the documentation it refers to this requirement only being applicable to ESX v5.0 and below and we are running ESX v6.0 in the environment. None the less after days of frustration I eventually installed VMware-PowerCLI-6.5.0-4624819.exe. This works without issues although I needed to copy the modules to my PowerShell directory and for now need to import them before running the script.
It seems that none of the modules from the PowerShell Gallery work in our environment, at least not as far as Invoke-VMScript and Copy-VMGuestFile are concerned.
Hopefully this will help some other poor souls struggling with this.
Thanks again for the feedback and suggestions.
I have seen that propSet error once before, it was caused by a faulty installation.
Did you remove the old, MSI based PowerCLI version completely, before installing one of the Gallery versions?
You need to do the Uninstall from Programs and Features, but also remove any PowerCLI folder remaining under C:\Program Files (x86)\VMware\Infrastructure\.
You can find a more detailed in Welcome PowerCLI to the PowerShell Gallery – Install Process UpdatesBlog: http://lucd.info | Twitter: @LucD22 | PowerCLI Reference co-author: http://tinyurl.com/hkn4glz
Prior to posting to this forum I never had any PowerCLI MSI installed. The testes were all conducted using only the Powershell gallery installations.
After installing the MSI though I did try installing a few version from the gallery again but it failed same as before.
I would prefer to be using the latest version in the Gallery but I am uncertain at this point how to get them working or what the difference between the two are.
It may just be a compatibility with our version of ESX in the environment.
Will have another crack at it using the suggested guide and let you know.