04-07-2022 07:23 PM
I am trying to use python script to auto claim 1000+ IMC servers with Intersight. I have followed Dave Soper article - Automated Intersight Device Claim - Cisco Community - Automated Intersight Device Claim - Cisco Community
I have cloned entire Automated Intersight Device Claim depository "intersight-python-master" to my local folder.
When I run the script in Git Bash:
py claim_device.py -a intersight_api_params -d devices
I am getting 2 different errors, depends on the path I use to run the script.
If I run it from "intersight-python-master" path:
I have error : ModuleNotFoundError: No module named 'device_connector' of
$ py claim_device.py -a intersight_api_params -d devices
Traceback (most recent call last):
File "claim_device.py", line 10, in
import device_connector
ModuleNotFoundError: No module named 'device_connector'
if I run in from intersight-python-master\examples path
I have a different error: No module named 'intersight.intersight_api_client'
$ py claim_device.py -a intersight_api_params -d devices
Traceback (most recent call last):
File "claim_device.py", line 8, in
from intersight.intersight_api_client import IntersightApiClient
ModuleNotFoundError: No module named 'intersight.intersight_api_client
$ python -V
Python 3.7.0
$ pip list
Package Version
certifi 2021.5.30
cffi 1.14.5
chardet 4.0.0
cryptography 3.4.7
idna 2.10
intersight 1.0.9.5808
pem 21.2.0
pip 22.0.4
pycparser 2.20
pycryptodome 3.14.1
pycryptodomex 3.14.1
PySimpleGUI 4.45.0
python-dateutil 2.8.2
requests 2.25.1
setuptools 62.0.0
six 1.16.0
tabulate 0.8.9
urllib3 1.26.5
wheel 0.37.1
Any help appreciated.
Derek
04-08-2022 07:32 AM
See if the newer repo & examples help:
https://github.com/CiscoDevNet/intersight-python-utils/tree/master/config_targets
I think the CiscoUCS repo is being deprecated, could be the old examples not working with the new SDK
04-08-2022 09:59 PM
How did you installed intersight python module? From pip repository or github?
Thanks,
Sergiu
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide