root@lxd2:/iso# distrobuilder repack-windows Win10_20H2_English_x64.iso Win10_distro.iso --debug
2021-05-18T04:53:00Z INFO distrobuilder/main_repack-windows.go:132 Mounting Windows ISO
2021-05-18T04:53:00Z INFO distrobuilder/main_repack-windows.go:190 Mounting driver ISO
Error: Failed to retrieve wim file information: Failed to run: wimlib-imagex info /var/cache/distrobuilder.189775707/overlay/sources/install.wim: [ERROR] Error reading data from WIM file: Input/output error
ERROR: Exiting with error code 50:
Could not read data from a file
I just got the Windows 10 iso from M$ and had to specify --windows-version w10. I get a similar error, cant read a file, although different error code. Here is the tail of the debug output:
2021-05-19T18:19:14Z DEBUG distrobuilder/main_repack-windows.go:566 Updating Windows registry {"hivefile": "DRIVERS"}
2021-05-19T18:19:14Z DEBUG distrobuilder/main_repack-windows.go:573 Updating Windows registry {"hivefile": "SYSTEM"}
2021-05-19T18:19:15Z DEBUG distrobuilder/main_repack-windows.go:580 Updating Windows registry {"hivefile": "SOFTWARE"}
Error: Failed to retrieve wim file information: Failed to run: wimlib-imagex info /var/cache/distrobuilder.617109801/overlay/sources/install.wim: [ERROR] Can't open "/var/cache/distrobuilder.617109801/overlay/sources/install.wim" read-only: No such file or directory
ERROR: Exiting with error code 47:
Failed to open a file.
I’ve tried this on both an ext4 partition and on zfs, same result. Ran watch on /var/cache/distrobuilder.*/overlay and it stays empty, no sources folder even. So it appears I am either missing some file(s) using --classic only (didn’t use edge per instructions), or something doesn’t get extracted or copied due to some permissions, but I didn’t see any specific warning or error.
Created an Ubuntu 20 LTS droplet on DIgitalOcean, to get as clean an install as I could, apt update, apt upgrade, did a snap install of distrobuilder and apt install of requirements.
I then proceeded to try to repack and I got:
sudo distrobuilder repack-windows Windows.iso Windows-repacked.iso --windows-version w10
INFO Mounting Windows ISO
INFO Downloading drivers ISO
INFO Mounting driver ISO
INFO Modifying WIM file {“file”: “boot.wim”, “index”: 2}
Error: Failed to retrieve wim file information: Failed to run: wimlib-imagex info /var/cache/distrobuilder.106266254/overlay/sources/install.wim: [ERROR] Can’t open “/var/cache/distrobuilder.106266254/overlay/sources/install.wim” read-only: No such file or directory
ERROR: Exiting with error code 47:
Failed to open a file.
@fdion we added a --disable-overlay option to distrobuilder. Would you mind trying running the distrobuilder edge snap with that option? This is just to rule out any issues with overlayfs.
I have this problem
Windows iso files from the media creation tool have install.esd instead of install.wim
I think unless you have Volume Licencing/MSDN/Insider/Academic option then you must use this tool.
So then for these iso files must an intermediate step be performed on a windows machine to convert install.esd → install.wim?
or can distrobuilder be modified to check for this alternative iso
In our experience, the Windows download website gives .iso to anyone who’s not using Windows. There also likely is some kind of way to get a regular .iso while using WIndows (ideally without modifying your browser’ user agent).
I believe you get install.esd when your ISO is effectively hand-assembled locally by that Windows tool. My guess is that this tool then can minimize the needed download by re-using files that you already have on your local system.