zstackio / zstack

ZStack - the open-source IaaS software http://zstack.org (国内用户请至 http://zstack.io)
Apache License 2.0
1.3k stars 393 forks source link

Windows 10 said the disk is not bootable #1310

Open kcwongigs opened 2 years ago

kcwongigs commented 2 years ago

a. Install and configure ZStack Enterprise in a VM in Virtual Box v6.1 (8 CPU, 8196Mb RAM, Enable PAE/NX, Enable Nested VT-x/AMD-V). b. Create a new image with Win 10 ISO. Set BIOS mode to UEFI. c. Create a new VM with said image. d. Boot with the Win10 ISO mounted. e. Win10 installation starts. But when it is time to create a partition: 2

If I choose Legacy as BIOS, then the guest won't boot at all: 1

How can I install a Win10 guest?

AlanJager commented 2 years ago

@kcwongigs

Thanks for your report.

First issue, it's the patch we applied to ovmf influenced the installation. If you are using ZStack with version > 4.3.6 and you do not want to reinstall a lower version. As a workaround, you can manully exit the windows installation and guest will go through UEFI boot again, make sure you press any key to make your guest boot from CD/DVD. Then the guest can be successfully installed.

But I recommand you to use LTS version based on 4.2.x,because this version still use old version ovmf.

Second issue, I'm not quite sure what happened to legacy boot, but I checked our test results, Win10 can be installed with Legacy. So maybe there is any difference with your image or nested virtualization issue. It will be helpful, if you can offer more details about your image and logs under /var/log/libvirt/qemu/your_vm_uuid.log.

kcwongigs commented 2 years ago

I'm using ZStack 4.4.8 (ZStack-Cloud-x86_64-DVD-4.4.8-c76.iso).

Using UEFI, I triggered the issue again. Then I exited Windows installer. That brought me to a black screen and nothing happens. So I went to ZStack web page and rebooted the guest, and reopened the console. The DVD boots again, and got the same error again.

Win10.txt 8dbb51aa57d04a7591e182ea9371e44c.log.txt

MatheMatrix commented 2 years ago

I'm using ZStack 4.4.8 (ZStack-Cloud-x86_64-DVD-4.4.8-c76.iso).

Using UEFI, I triggered the issue again. Then I exited Windows installer. That brought me to a black screen and nothing happens. So I went to ZStack web page and rebooted the guest, and reopened the console. The DVD boots again, and got the same error again.

Win10.txt 8dbb51aa57d04a7591e182ea9371e44c.log.txt

Could you upgrade to the latest version (4.4.24) and then try again?

kcwongigs commented 2 years ago

I upgraded to 4.4.24 and it still didn't work.

If I create a Win10 instance in Legacy mode, I get the same no display yet problem: image

If I create a Win10 instance in UEFI mode, I pressed ENTER when it said press enter to boot with disc, but I still get dumped into UEFI interactive shell. image

map command gives me this: image

MatheMatrix commented 2 years ago

I upgraded to 4.4.24 and it still didn't work.

If I create a Win10 instance in Legacy mode, I get the same no display yet problem: image

If I create a Win10 instance in UEFI mode, I pressed ENTER when it said press enter to boot with disc, but I still get dumped into UEFI interactive shell. image

map command gives me this: image

Is this a vm create in previous zstack version? seems no cd-rom in uefi map

kcwongigs commented 2 years ago

I deleted the VM instance and started from scratch.

  1. Select Win10 UEFI image
  2. Add CD Rom for VirtIO disc

Then upon the first launch of the console, I'm unable to press key to boot from CD fast enough, so I got dumped into UEFI shell and I got this map: image

I rebooted (with UEFI shell's reset command), the press any key to boot from CD appeared and I pressed enter. Then I got this: image

So I close the console tab and reopened it, then I got this: image Some of the items disappeared.

AlanJager commented 2 years ago

@kcwongigs

Sorry for getting back to you late.

In first case, if you boot windows with UEFI and see BLK0, that means your Win guest is not use right Boot Order, you can simply change it as following:

Vm Instances -> Your VM -> Actions -> System Configurations -> Set Boot Order -> Choose CD ROM

and reboot vm by:

Vm Instances -> Your VM -> Actions -> Reboot

Then, vm will boot from your ISO.

The second case, because default CD/DVD enter option only shows in a short time, if you not manually press any key to get into installation a UEFI shell will shows with your screenshot. You can use UEFI shell as following:

FS0: 
cd EFI
cd BOOT
BOOTX64.EFI

to continue your installation.

If your manually reboot guest inside. ZStack will detect if the guest boot from CD ROM and reboot inside guest means "installation finished" so Boot Order will be changed to HardDisk automaticly (which could be checked from details of VM) to make sure windows boot from its OS but not CD ROM again.

So it's not recommanded to manually reboot during installation phase or the result will be quite confused.