Installing Python and PyWBEM

I am working with Ingmar Verheij on a SCOM management pack for HP EVA.

This management pack will query real-time data using SMIS-S and it requires the Python scripting language and the PyWBEM library.

In this post I will describe how to install Python and PyWBEM.

First we need to install Python, I took the version 2.6.6 (32 bit version). You can download it from this link.

Note: There are quite some language changes in Python 3.x so if you don’t want to adapt the PyWBEM code choose a 2.x version!

The Python installation is pretty simple, I accepted the default settings:

image image
image image

 

Next step is the installation of pywbem, I used version 0.7 (pywbem-0.7.0.tar.gz) which can be downloaded here. Extract the folder pywbem-0.7.0 somewhere (in my case C:\Beheer\Python) and start a cmd prompt and navigate to this folder.

From this folder launch setup.py (C:\Python26\Python setup.py build), on my system it didn’t build because the module pwd was missing:

image

I worked around this by removing pwd from the import statement in cim_http.py, (change import sys, string, re, os, socket, pwd to import sys, string, re, os, socket)

Now the build is successful:

image

Final step is the installation which is executed with the command C:\Python26\Python setup.py install.

Was once an enthusiastic PepperByte employee but is now working elsewhere. His blogs are still valuable to us and we hope to you too.