Anyone using a Python script to monitor CPU usage on a Windows machine ? i've google for some time but have not been able to find any usable script. could you guys show me some example of what you're using ?
Here is the errors i got.
Traceback (most recent call last): File "test.py", line 1, in import wmi File "c:\Python26\lib\site-packages\wmi.py", line 141, in from win32com.client import GetObject, Dispatch ImportError: No module named win32com.client
Us psutil module, it provides for memory, cpu, netowrk, etc usages. Visit their project webpage http://code.google.com/p/psutil/ .
Lucky ol' you gets to dig around in WMI. Check out the Python module 'wmi' which is about as good as I've seen.
You are missing the python win32 extensions which you can find here.
This blog entry shows some code: