maharmstone / quibble

Quibble - the custom Windows bootloader
GNU Lesser General Public License v3.0
2.11k stars 81 forks source link

Windows 10 22H2 hangs at "Booting Windows" #88

Open 2W10 opened 1 year ago

2W10 commented 1 year ago

Windows 10 with Quibble-2023-04-08-18-47-16 Hi,

When I try to boot Windows 10 22H2, it hangs at "Booting Windows". How can I get around this?

2W10 commented 1 year ago

I am using VMware 16 Workstation Pro btw.

rbhorse commented 1 year ago

I'm having the same issue and seems like https://github.com/maharmstone/quibble/issues/87 is too. Same result on VMware 17 Workstation Pro and Virtualbox 7.0.8. It appears that Quibble is unable to boot 22H2 at the moment. I am booting from NTFS. image

maharmstone commented 1 year ago

It looks like, due to the Spectre/Meltdown mitigation, recent versions of Windows behave slightly differently on different processors - it's something I'm looking into.

Possibly it's that it works on AMD but not on Intel, but I don't know if it's that straightforward.

rbhorse commented 1 year ago

@maharmstone hi, thanks for the quick response. I'm on a AMD Ryzen 7 4800h CPU so I doubt this issue is limited to Intel. I have also tried to boot Quibble with Spectre disabled using inSpectre. It appears that it will not allow me to disable Meltdown, possibly because my CPU is immune to it. However it appears that the problem with Booting Windows... still persists. Let me know if you would like me to run any other tests to help provide more info. image

pog5 commented 1 year ago

Is there any fix I can manually do for this? Both Spectre and Meltdown Mitigations are disabled on my PC.

willzyx-hub commented 1 year ago

Is there any fix I can manually do for this? Both Spectre and Meltdown Mitigations are disabled on my PC.

without developer help and without programming skills it's not possible

SzczurekYT commented 1 year ago

For me it doesn't work too with 22H2, on AMD CPU, on QEMU with virt-manager, on Nobara 38 (fedora linux optimized for games). So I think it doesn't matter if it's AMD or Intel. But even if it doesn't work for me, I'm still impressed.

HueponiK commented 1 year ago

Same problem, downloaded latest 22H2, installed in VM, converted to btrfs as offline disk from another VM, copied quibble in EFI folder in the EFI system partition. After reboot, it gets stuck at "Booting windows"

I use Arch (btw), and virt-manager quemu-kvm-based VM with Q35 chipset on UEFI firmware.

image

Thanks for working on such "cursed" project @maharmstone!

HueponiK commented 1 year ago

Tested the same disk image on m1 mac with emulated x86_64 machine using UTM. Slow AF, but it gets past Booting Windows..., and I was finally able to boot windows on btrfs using quibble.

SzczurekYT commented 1 year ago

Interesting, so it depends on cpu? Or what do you think the problem is?

HueponiK commented 1 year ago

Interesting, so it depends on cpu? Or what do you think the problem is?

Something to do with KVM, maybe? On my main core i7 rig, if I replace <domain type="kvm"> with <domain type="qemu"> I get similar situation (slightly faster).

maharmstone commented 1 year ago

On my desktop (AMD Ryzen 7), it works with KVM in Qemu but not on bare metal. On my Intel laptop, it doesn't work at all. There's some sort of complicated heuristic it uses to determine whether to do the mitigations, which obviously depends in part on the CPU.

SzczurekYT commented 1 year ago

Oh ok, I'm wanto to test this on my bare metal, but it seems like my bios (uefi) doesn't support directly loading efi files, so I'm trying to chainload from grub, but I get stuck Error opening freeldr.ini, EFI_NOT_FOUND error, so I need to try fix that first.

jonhermansen commented 1 year ago

Finally I was able to get Quibble to boot Win10 22H2 in virt-manager...

@HueponiK helped narrow down the problem. If I set my VM to use KVM, it won't boot. If I switch to pure qemu, the same disk will boot to the desktop using Quibble... though the VM runs pretty slow, due to no acceleration.

# diff -u win10.xml-broken win10.xml-quibble-working
--- win10.xml-broken    2023-07-30 12:02:45.926936053 +0000
+++ win10.xml-quibble-working   2023-07-30 09:45:23.893490323 +0000
@@ -5,7 +5,7 @@
 or other application using the libvirt API.
 -->

-<domain type='kvm'>
+<domain type='qemu'>
   <name>win10</name>
   <uuid>f49f09a5-774d-445a-86e2-8010310a8d31</uuid>
   <metadata>

In case it is also relevant, here's the CPU type I used in both tests:

  <cpu mode='custom' match='exact' check='none'>
    <model fallback='forbid'>qemu64</model>
  </cpu>

Maybe this information can further help to debug issues with booting on physical systems too.

SzczurekYT commented 1 year ago

Finally I was able to get Quibble to boot Win10 22H2 in virt-manager... ... Maybe this information can further help to debug issues with booting on physical systems too.

I tested this on my virt-manager, and it didn't help, still stuck on booting windows.

jonhermansen commented 1 year ago

@SzczurekYT Did you also change the CPU to qemu64?

EDIT: Here is my XML file for comparison: https://gist.github.com/jonhermansen/44f68ac9db331b2343fe79671ea64c95

SzczurekYT commented 1 year ago

@SzczurekYT Did you also change the CPU to qemu64?

EDIT: Here is my XML file for comparison: https://gist.github.com/jonhermansen/44f68ac9db331b2343fe79671ea64c95

Yes I did that, here mine: https://gist.github.com/SzczurekYT/7a15c3c61e405c52b1ad5159100ebea9

jonhermansen commented 1 year ago

@SzczurekYT Did you also change the CPU to qemu64? EDIT: Here is my XML file for comparison: https://gist.github.com/jonhermansen/44f68ac9db331b2343fe79671ea64c95

Yes I did that, here mine: https://gist.github.com/SzczurekYT/7a15c3c61e405c52b1ad5159100ebea9

@SzczurekYT Ok, I should note that it takes about 2 minutes for Windows to load up after "Booting Windows" message is printed... so you need to wait long enough.

I tried with your XML but I had to make a few modifications, I disabled OpenGL in the Spice Server component, and swapped the GPU from Virtio to QXL. It boots with Quibble on my machine!

Running Debian Trixie (testing) here, booted in UEFI mode, secure boot disabled both on host and guest.

Kernel: localhost 6.4.7-x64v3-xanmod1 x86_64 (should work on stock Debian kernel too)

Kernel command-line parameters: BOOT_IMAGE=/boot/vmlinuz-6.4.7-x64v3-xanmod1 root=UUID=8dccb279-abb0-4501-8fb5-6b6fc66ad53e ro kvm_intel.unrestricted_guest=0 mitigations=off quiet splash resume=UUID=55860a93-6615-4171-94c7-7ebf84f99115 (should work without kvm_intel.unrestricted_guest=0 mitigations=off, was just trying various things)

CPU: Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz

Here's an edited version of your XML that boots on my machine: https://gist.github.com/jonhermansen/38736cb4d174ff8b6c28f8624ccb7deb

SzczurekYT commented 1 year ago

I left that in the background, when I made that comment and nowe came back to check aaand: it works! I think. Let me try to reboot the vm, and confirm that. Yee, it works, even with opengl enabled. So you were right, I just didn't wait long enough. This should be noted somewhere or this issue will be getting false positives.

0x1337F00D commented 1 year ago

I'm attempting to run Quibble on bare-metal without a VM and keep getting stuck at the "Booting Windows" step. Any insights or updates on this issue? I'm on Windows 11 build 23536. I would be glad for any pointers and insights, @maharmstone ;)