seveas / python-hpilo

Accessing the HP iLO XML interface from python
https://seveas.github.io/python-hpilo
Other
321 stars 102 forks source link

From Ansible, when targeting iLO version 5, only hw_eth0 and hw_eth_ilo show details, missing all other hw_ethX. #255

Open metalcated opened 3 years ago

metalcated commented 3 years ago

Summary

When using iLO version 5, only hw_eth0 and hw_eth_ilo show details, missing all other hw_ethx interfaces. When running this with iLO version 4, I get all of the network interfaces as compared to version 5 which is hw_eth0 and hw_eth_ilo only.

Issue Type

Bug Report

Component Name

hplio_info

Ansible Version

  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/user/oneview-ansible/library']
  ansible python module location = /home/user/ansible/lib64/python3.6/site-packages/ansible
  executable location = /home/user/ansible/bin/ansible
  python version = 3.6.8 (default, Apr  2 2020, 13:34:55) [GCC 4.8.5 20150623 (Red Hat 4.8.5-39)]

Configuration

- hosts: localhost
  vars:
     hp_ilo_ip: "ip"
     hp_ilo_login: username
     hp_ilo_password: password

  tasks:
  - name: "Gather facts from HP iLO for {{hp_ilo_ip}}"
    community.general.hpilo_info:
      host: "{{hp_ilo_ip}}"
      login: "{{hp_ilo_login}}"
      password: "{{hp_ilo_password}}"
    delegate_to: localhost
    register: physical_facts

  - debug:
      msg: "{{ physical_facts }}"

OS / Environment

RHEL 7 x86_64 / user running in venv (testing) and also AWX using a venv (production)

Steps To Reproduce

Use the "confguration" sample above and run with the latest version of the module against a HP Blade with iLO 5 (Synergy Gen 10). You will see only the physical hw_ethX interfaces return in the results. I already checked with the folks who maintain the hpilo_info module and they said all that module does is absorb what is coming from this python module.

Expected Results

Expect to see a full list of adapters with the respective information.

Actual Results

ok: [localhost] => {
    "msg": {
        "changed": false,
        "failed": false,
        "hw_bios_date": "XX/XX/XXXX",
        "hw_bios_version": "I42",
        "hw_eth0": {
            "macaddress": "XX:XX:XX:XX:XX:XX",
            "macaddress_dash": "XX-XX-XX-XX-XX-XX"
        },
        "hw_eth_ilo": {
            "macaddress": "XX:XX:XX:XX:XX:XX",
            "macaddress_dash": "XX-XX-XX-XX-XX-XX"
        },

Missing remaining 7 Adapters

metalcated commented 3 years ago

I can donate to whom ever expedites this! 👍