The goal for the system_baseline_compliance.py script is twofold: When it does not find JSON baseline files at the current working directory, it connects to the iLO CMU through Python iLO REST library, makes query to the system information, and then downloads the BIOS baseline and the firmware inventory to the local directory. The name of the baseline files shows the system model, the iLO serial number, and the time stamp when it's generated. On the other hand, if there is already JSON baselines present in the current working directory, the script pulls BIOS configs and firmware inventory from iLO, and then compares those data against the latest baseline, such that if there are multiple baselines, the script only compares to the one with the latest time stamp.
The script has been tested on Windows, with Gen9 iLO4 (iLO4 FW 2.61 Jul 27 2018), and Gen10 iLO5 (iLO5 FW 1.37 Oct 25 2018), in production mode.
This script has been tested on Python 3.7.3. Pythons can either be downloaded and installed from https://www.python.org/downloads/. Linux users may need to build from source. Dependencies are listed in requirements.txt. Use Pip to install the dependencies.
The script takes in two parameters, --iloip and --username, and then it would prompt the operator to enter the login password. It then saves the BIOS settings and the firmware inventory to the current working directory.
- --iloip: iLO IP address
- --username: iLO login username
- --password: iLO login password
operator$ python system_baseline_compliance.py -h
usage: system_baseline_compliance.py [-h] -p PASSWORD -i ILOIP -u USERNAME
optional arguments:
-h, --help show this help message and exit
-p PASSWORD, --password PASSWORD
iLO login password
-i ILOIP, --iloip ILOIP
iLO IP address or FQDN (without http:// or https://
and any trailing /)
-u USERNAME, --username USERNAME
iLO login name
operator$ python system_baseline_compliance.py --username administrator --iloip 192.168.0.100 --password adminPwd
iLO serial number: MAX63507MJ
Latests baseline: C:\Users\operator\ilorest_pull_data-master\ProLiant_DL360_Gen9_iLO4_MAX63507MJ_bios_20191118-145243.json
Latests baseline: C:\Users\operator\ilorest_pull_data-master\ProLiant_DL360_Gen9_iLO4_MAX63507MJ_firmware_inventory_20191118-145243.json
Save baselines to C:\Users\operator\ilorest_pull_data-master\ProLiant_DL360_Gen9_iLO4_MAX63507MJ_firmware_inventory_diff_20191118-145740.json
Save baselines to C:\Users\operator\ilorest_pull_data-master\ProLiant_DL360_Gen9_iLO4_MAX63507MJ_bios_20191118-145740.json
Save baselines to C:\Users\operator\ilorest_pull_data-master\ProLiant_DL360_Gen9_iLO4_MAX63507MJ_firmware_inventory_20191118-145740.json