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.53k stars 1.12k forks source link

Script fails at populate_bootable_installer_virtual_disk #423

Closed benng-at-wecasa closed 3 years ago

benng-at-wecasa commented 3 years ago

macOS3_troubleshoot.txt macOS3-2021-03-18-10-30-02.log

Here are the logs : any ideas ?

00:00:00.942905 !! {xhci}
00:00:00.942905 !!
00:00:00.942907 usb-xhci#0: PCI MMIO=ffffffffffffffff IRQ=0 MSI=off R0=true  RC=false
00:00:00.942909 USBCMD: 0:
00:00:00.942909 USBSTS: 1: HCH
00:00:00.942910 DNCTRL: 0   CONFIG: 0 (0 slots)
00:00:00.942910 DCBAA ptr: 0000000000000000
00:00:00.942911 CRCR ptr : 0000000000000000
00:00:00.942911 Port 01 (USB2): PORTSC:    206A1: CCS PLS=5 PP SPD=1 CSC
00:00:00.942913 Port 02 (USB2): PORTSC:    206A1: CCS PLS=5 PP SPD=1 CSC
00:00:00.942914 Port 03 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942915 Port 04 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942916 Port 05 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942916 Port 06 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942917 Port 07 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942918 Port 08 (USB2): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942918 Port 09 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942919 Port 10 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942920 Port 11 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942921 Port 12 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942921 Port 13 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942922 Port 14 (USB3): PORTSC:      2A0: PLS=5 PP SPD=0
00:00:00.942923 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
00:00:00.942957 emR3Debug: rc=VERR_INVALID_STATE
00:00:00.946794 ERROR [COM]: aRC=NS_ERROR_INVALID_ARG (0x80070057) aIID={4680b2de-8690-11e9-b83d-5719e53cf1de} aComponent={DisplayWrap} aText={Argument aWidth is invalid (must be aWidth != 0 && aWidth <= 32767)}, preserve=false aResultDetail=0
FrodeSolheim commented 3 years ago

I've seen a similar error in VirtualBox (not specifically related to macos-virtualbox). The problem turned out to be that I was running other virtualization software in the background - in particular, Canonical's multipass. And that seemed to prevent VirtualBox from starting (and gave that rather unhelpful error message).

myspaghetti commented 3 years ago

@benng-at-wecasa thanks for the bug report!

If you wouldn't mind, please include the file *_troubleshoot.txt (macOS_troubleshoot.txt by default) generated by ./macos_guest_virtualbox.sh troubleshoot

Running the command after VirtualBox fails to start (or providing the VBox.log file generated after VirtualBox fails to start) will provide the most relevant information.

I suspect FrodeSolheim is correct and VirtualBox is crashing because it can't access VT-x/AMD-V that's being used by other software.

benng-at-wecasa commented 3 years ago

Thank you for your answer ! I have just updated the issue with the log files

myspaghetti commented 3 years ago

According to this thread on the VirtualBox forums, some QEMU/KVM network devices might be blocking VirtualBox from using VT-x. Assuming you're not using them, delete these network devices (they should have qemu in their device name) and that should free up VT-x for VirtualBox.

benng-at-wecasa commented 3 years ago

I use : sudo apt remove qemu-kvm and it works :tada: then it get me through the other error which is

Attempting automated recognition of virtual machine graphical user interface.
Please waitVBoxManage: error: Argument aWidth is invalid (must be aWidth != 0 && aWidth <= 32767)
VBoxManage: error: Details: code NS_ERROR_INVALID_ARG (0x80070057), component DisplayWrap, interface IDisplay, callee nsISupports
VBoxManage: error: Context: "TakeScreenShotToArray(iScreen, width, height, BitmapFormat_PNG, ComSafeArrayAsOutParam(saScreenshot))" at line 1880 of file VBoxManageControlVM.cpp
myspaghetti commented 3 years ago

Are you perhaps running the script from a pipe? This makes VirtualBox act strangely. The script should be executed plainly (or explicitly with bash) from a shell (./macos-guest-virtualbox.sh)

benng-at-wecasa commented 3 years ago

I execute the script from zsh like this : ./macos-guest-virtualbox.sh

Le mar. 23 mars 2021 à 16:42, Jack @.***> a écrit :

Are you perhaps running the script from a pipe? This makes VirtualBox act strangely. The script should be executed plainly (or explicitly with bash) from a shell (./macos-guest-virtualbox.sh)

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/myspaghetti/macos-virtualbox/issues/423#issuecomment-805008694, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASQFOKH56G2NXGJURVVDWLDTFCZFXANCNFSM4ZKMDAHA .

myspaghetti commented 3 years ago

Would you mind generating another macOS3_troubleshoot.txt file and attaching it here?

benng-at-wecasa commented 3 years ago

Hi ! here is the file

macOS3_troubleshoot.txt

myspaghetti commented 3 years ago

Awright, here's another guess: you have an 11th-gen Intel CPU, and this pull request says that switching from MacOS1013_64 to MacOS_64 should make the VM boot on newer Intel CPUs (because VirtualBox changes the guest CPU profile when you do that).

You can either edit the script on line 390, replacing MacOS1013_64 with MacOS_64 (and also on line 394 if you're pedantic) or by manually changing the setting in the VirtualBox GUI (Settings > General > Version > Mac OS X (64-bit)), and then resuming the script from the aborted stage as described in the documentation.

benng-at-wecasa commented 3 years ago

nope :)

macOS3_troubleshoot.txt

myspaghetti commented 3 years ago

Good to know. It changed the guest CPU architecture to Penryn so now I can close the pull request because that will definitely do more harm than good.

Congrats, you solved one of my issues.

Sorry, I don't think I can solve yours. Most likely CPU incompatibility, maybe there's a magic CPUID that you can enter into VirtualBox's --cpuidset option that'll make it compatible.

benng-at-wecasa commented 3 years ago

OK no worries thanks for the help