ISO_customize module error : "msg": "Failed to delete iso file /boot.cfg with error: Assigned an extent beyond the ISO (214605 > 214603)"}

I am trying to modify the iso file using below code, but getting the error “msg”: “Failed to delete iso file /boot.cfg with error: Assigned an extent beyond the ISO (214605 > 214603)”}

unable to find any article. Can anyone help me to fix the issue?
I am on Centos 9 Stream and Python 3.9.17
pycdlib==1.14.0

  - name: Modify source ISO from {{ file_path }} and copy to destination
    community.general.iso_customize:
      src_iso: "{{ isosrc}}/{{ src_iso_file }}"
      dest_iso: "{{ iso_path }}/{{ item.servername }}.iso"
      delete_files:
        - "boot.cfg"
        - "EFI/BOOT/BOOT.CFG"
      add_files:
        - src_file: "{{ file_path }}/{{ item.servername }}/BOOT.CFG"
          dest_file: "BOOT.CFG"
        - src_file: "{{ file_path }}/{{ item.servername }}/BOOT.CFG"
          dest_file: "EFI/BOOT/BOOT.CFG"
    loop: "{{ hostName }}"
1 Like

Some ISO files (e.g. VMware ESXi) have an unusual path table extent structure, which is the cause of your problem.

This is already addressed in upstream pycdlib repository, but the fix is not released as versioned pip module yet: Assigned an extent beyond the ISO · Issue #106 · clalancette/pycdlib · GitHub

So install latest pycdlib from GitHub and try your playbook again:

pip install git+https://github.com/clalancette/pycdlib.git
2 Likes

Thank you, it worked.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.