myspaghetti / macos-virtualbox

Push-button installer of macOS Catalina, Mojave, and High Sierra guests in Virtualbox on x86 CPUs for Windows, Linux, and macOS
GNU General Public License v2.0
13.5k stars 1.12k forks source link

Unable to complete installation of Catalina on macOS #549

Closed mciarlo closed 2 years ago

mciarlo commented 2 years ago

I'm running into an issue creating the VDI file. You can find the output below. I reviewed other similar issues and the only thing I found was a recommendation to reinstall the script, which I just downloaded today. Any help would be greatly appreciated.

stage: create_nvram_files

stage: create_macos_installation_files_viso
Creating EFI startup script

Creating VirtualBox 6 virtual ISO containing the
installation files from swcdn.apple.com

stage: configure_vm

stage: populate_basesystem_virtual_disk
Converting BaseSystem.dmg to BaseSystem.img

dmg2img v1.6.7 (c) vu1tur (to@vu1tur.eu.org)

Catalina_BaseSystem.dmg --> Catalina_BaseSystem.img

Converting from raw image file="Catalina_BaseSystem.img" to file="Catalina_BaseSystem.vdi"...
VBoxManage: error: Cannot open file "Catalina_BaseSystem.img": VERR_FILE_NOT_FOUND
Failed to create "Catalina_BaseSystem.vdi".
Exiting.
myspaghetti commented 2 years ago

Thanks for the bug report!

dmg2img appears to have failed to covnert Catalina_BaseSystem.dmg to Catalina_BaseSystem.img. Either Catalina_BaseSystem.dmg doesn't exist, or the file is corrupt, or there is some file access issue which might occur if the script runs with elevated privileges (sudo, root, etc).

Please run ./macos-guest-virtualbox.sh troubleshoot and attach the resulting .txt file here.

mciarlo commented 2 years ago

Thanks for the speedy reply!

Here is a gist of the troubleshoot text.

myspaghetti commented 2 years ago

Thanks. Catalina_BaseSystem.dmg appears to be corrupt, which would explain why dmg2img failed to convert it to an img file. On the plus side, Catalina_InstallESDDmg.pkg has the correct hash and so do the rest of the files, so you don't need to re-download everything, just delete Catalina_BaseSystem.dmg and re-run the script.

Lack of file integrity verification is a known issue (#321) so I'm marking this as duplicate.

mciarlo commented 2 years ago

@myspaghetti Thank you so much! Everything seems to be working!