dell / dellemc-openmanage-ansible-modules

Dell OpenManage Ansible Modules
GNU General Public License v3.0
340 stars 164 forks source link

dellemc_boot_to_network_iso fails with "Cannot fetch OSD Job status" #32

Closed qwertzlbert closed 5 years ago

qwertzlbert commented 5 years ago

System: VxRail E560 iDRAC Firmware: OS: esxi 6.7

"dellemc_boot_to_network_iso" will return with the error message "Cannot fetch OSD Job status" if you are logged into the iDRAC and the virtual console is started, when the call is executed.

ansible_requirements.txt

digifuchsi commented 5 years ago

System: PowerEdge R740xd iDRAC Firmware: 3.21.23.22 OS: ESXi 6.7

I get the same error even with resetting and not accessing the iDRAC before calling the module every other time. Maybe it is a timing issue between creating the Job and monitoring the execution of the LC Job?

eviden-simon-hill commented 5 years ago

I have been having the same issue 9 out of 10 times I try to deploy using this module.
I agree with @digifuchsi it appears to be a timing issue. I have found a workaround by adding a sleep to omdrivers/lifecycle/iDRAC/iDRACJobs.py before it tries to get the job id. I have created a pull request for this workaround hopefully it will be merged or someone will find a better fix. https://github.com/dell/omsdk/pull/8

ibt23sec5 commented 5 years ago

Reproduced too.

Model: PowerEdge R640 Firmware version: 3.34.34.34 Playbook:

- name: Get LC status
  dellemc_get_lcstatus:
    idrac_ip: "{{ idrac_ip }}"
    idrac_user: "{{ idrac_user }}"
    idrac_pwd: "{{ idrac_password }}"
  register: lc_status

- name: Show LC status
  debug:
    msg: "LC Status: {{ lc_status.msg.LCStatus }} Ready: {{ lc_status.msg.LCReady }}"

- name: Set generated ISO as a boot CD
  dellemc_boot_to_network_iso:
    idrac_ip: "{{ idrac_ip }}"
    idrac_user: "{{ idrac_user }}"
    idrac_pwd: "{{ idrac_password }}"
    share_name: "{{ nfs_image_path }}"
    iso_image: "{{ paths.dest_iso_image }}"

Output:

ok: [xxxxxxxxxxxxxx]

TASK [Show LC status] **********************************************************
ok: [xxxxxxxxxxxxxx] => {
    "msg": "LC Status: Ready Ready: True"
}

TASK [Set generated image as a boot CD] *************************
fatal: [xxxxxxxxxxxxxx]: FAILED! => {"changed": false, "msg": {"Message": "Cannot fetch OSD Job status", "Status": "Failed", "file": "nfs-share:/data/nfs-share/debian-netinst.iso", "retval": false}}
rajeevarakkal commented 5 years ago

@ibt23sec5 Comments has been added in the omsdk PR - dell/omsdk#8

rajeevarakkal commented 5 years ago

@qwertzlbert; fix in omsdk - dell/omsdk#8 is merged and closing this issue