Moritz8055
Contributor
Contributor

Cant use VMware.ImageBuilder

Jump to solution

So i wan´t to use the VMWare.ImageBuilder Module.

And as soon as i run Add-EsxSoftwareDepot i get this error message:

Could not initialize the VMware.ImageBuilder PowerCLI module. Make sure that Python 3.7 is installed and that you have set the path to the Python executable by using Set-PowerCLIConfiguration -PythonPath. See the PowerCLI Compatibility Matrixes for information on the Python requirements.

 

I´ve downloaded and installed Python3.7 to "I:\Program Files\Python" and then ran the get-pip.py script via Windows Explorer (Run with -> Python.exe) because i couldn´t run it via the cmd

To install the addons six, psutil, lxml and pyopenssl i opened up CMD navigated to the path "I:\Program Files\Python\Scripts" and ran this command: pip3.7 install six psutil lxml pyopenssl

Then i ran the command in admin powershell: Set-PowerCLIConfiguration -PythonPath "I:\Program Files\Python\python.exe"

But still when i wan´t to run the Add-EsxSoftwareDepot Command i get the error message.

Have i done anything wrong?

 

I am creating a own ISO because i wan´t to use ESXi 8.0 with my TP-Link TG-3468 (based on Realtek) Network Card and my Killer E2205 network controller (on mainboard)

 

Thank you for your help!

Greetings,
Moritz

0 Kudos
1 Solution

Accepted Solutions
Moritz8055
Contributor
Contributor

Thank you for your help!

First I´ve deinstalled the current Python (3.7.0) and then followed the blogpost you´ve sent. 

I installed Python 3.7.9 and then ran the get-pip.py with python in cmd (copied get-pip.py in the Python installation folder and then ran: python.exe get-pip.py). 
Then i navigated to the scripts folder, in my case: I:\Program Files\Python\Scripts
an then ran the following command: pip3.7.exe install six psutil lxml pyopenssl

Then i´ve set the python path for the PowerCLI (in my case):
Set-PowerCLIConfiguration -PythonPath "I:\Program Files\Python\python.exe" -Scope User

 

View solution in original post

14 Replies
LucD
Leadership
Leadership

What does the following command return

python --version

  


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

0 Kudos
Moritz8055
Contributor
Contributor

python --version returns following:
"Python could not be found. Run the shortcut with no arguments to install it from the Microsoft Store, or disable this shortcut in"

if i run py --version it returns following:
"Python 3.7.0"

 

(my cmd is in german)

Moritz8055_0-1674669099561.png

 

0 Kudos
LucD
Leadership
Leadership

Have you checked and tried the solutions provided in VMWare.Imagebuilder has issue with Python 3.7 and ... - VMware Technology Network VMTN


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

0 Kudos
Moritz8055
Contributor
Contributor

So updating PIP, Python and then restarting the computer?
And which command should i use to do so? 
I found multiple command for updating python and PIP.

0 Kudos
LucD
Leadership
Leadership

There are quite a few advisories in that thread.
Unfortunately, I don't know/see which one is the solution for you.


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

0 Kudos
Moritz8055
Contributor
Contributor

So i checked if every additional packages are installed (by running the command: pip3.7 install ....)
I haven´t updated pip and python because the error says "make shure python 3.7" is installed, so i guess it´s only running with 3.7

I also rebooted my PC and i am still getting the same error 

0 Kudos
LucD
Leadership
Leadership

When I had the same issue, I followed the steps in the blogpost Kamen pointed to.
That fixed it for me.
Note that I had to uninstall all my previous Python instances from my station before.

If that doesn't help I suggest opening an SR.
If GSS claims PowerCLI is not supported without a Developer Support contract, point them to Online Documentation - PowerCLI 12.3.0 User’s Guide - VMware {code}


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

0 Kudos
Moritz8055
Contributor
Contributor

Thank you, it´s working now. It creates the ISO but still puts out some errors, are these fatal?

Moritz8055_0-1674676257322.png

 

0 Kudos
LucD
Leadership
Leadership

I guess that you will have to create a new image profile (New-ExImageProfile), based on the official ESXi image profile, but where you change the AcceptanceLevel.

I have no clue how to fix the sha-256 gzip checksum error.


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

0 Kudos
Moritz8055
Contributor
Contributor

Ok Thanks,

is it even possible to use Realtek Drivers in ESXi 8.0? Because the realtek driver is a VMKlinux Driver.

0 Kudos
LucD
Leadership
Leadership

I'm afraid I can't answer that.
My knowledge of the subject is rather limited.
The drivers you mention don't seem to be in the compatibility tables, so chances are rather slim I'm afraid.


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

0 Kudos
LucD
Leadership
Leadership

On a side-note, and to help other facing a similar issue, how did you fix the Python issue?


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

0 Kudos
Moritz8055
Contributor
Contributor

Thank you for your help!

First I´ve deinstalled the current Python (3.7.0) and then followed the blogpost you´ve sent. 

I installed Python 3.7.9 and then ran the get-pip.py with python in cmd (copied get-pip.py in the Python installation folder and then ran: python.exe get-pip.py). 
Then i navigated to the scripts folder, in my case: I:\Program Files\Python\Scripts
an then ran the following command: pip3.7.exe install six psutil lxml pyopenssl

Then i´ve set the python path for the PowerCLI (in my case):
Set-PowerCLIConfiguration -PythonPath "I:\Program Files\Python\python.exe" -Scope User

 

Moritz8055
Contributor
Contributor

After a little research I found out that Realtek drivers are no longer supported since ESXi version 6.7.

And since I don't want to install a possibly broken ISO, even though the ISO creation seems to have worked, I have to buy an Intel card to use ESXi 8.0

This one should work:
10Gtek® Gigabit PCIE Desktop Netzwerkkarte für Intel EXPI9301CT -82574L Chip 

It uses the 82574L Chip which is listed in VMware´s Compatibility Guide (but i have to find the correct driver first. didn´t find a download to it yet)

0 Kudos