dockur / windows

Windows inside a Docker container.
MIT License
29.62k stars 2.02k forks source link

gen_helper_out_func: code should not be reached and forcefully terminating #794

Open milkTeahm opened 1 month ago

milkTeahm commented 1 month ago

Operating system

centos 7

Description

When I installed the Windows 10 ltsc image, the following error was reported during the system installation phase, and I tried it on two servers, and it was the same error. Do not know “gen_helper_out_func: code should not be reached” what is the meaning of this paragraph, can not find the relevant information in various places

Docker compose

version: "3" services: windows: image: dockurr/windows container_name: windows10 environment: VERSION: "ltsc10" LANGUAGE: "Chinese" DISK_SIZE: "20G" RAM_SIZE: "6G" CPU_CORES: "4" USERNAME: "admin" PASSWORD: "123456" MANUAL: "N" KVM: "N" volumes:

Docker log

2024-10-11T16:37:14.431448308Z ❯ Extracting Windows 10 image... 2024-10-11T16:38:08.416401479Z ❯ Adding drivers to image... 2024-10-11T16:38:22.398550335Z ❯ Adding win10x64-ltsc.xml for automatic installation... 2024-10-11T16:38:24.565135275Z ❯ Building Windows 10 image... 2024-10-11T16:39:14.874578717Z ❯ Creating a 30G growable disk image in raw format... 2024-10-11T16:39:35.308666731Z ❯ Booting Windows using QEMU v9.1.0... 2024-10-11T16:39:39.367185990Z [=3h [=3h [=3h BdsDxe: failed to load Boot0002 "UEFI QEMU QEMU HARDDISK " from PciRoot(0x0)/Pci(0xA,0x0)/Scsi(0x0,0x0): Not Found 2024-10-11T16:39:39.479994707Z BdsDxe: loading Boot0001 "UEFI QEMU DVD-ROM QM00013 " from PciRoot(0x0)/Pci(0x5,0x0)/Sata(0x0,0xFFFF,0x0) 2024-10-11T16:39:39.488877215Z BdsDxe: starting Boot0001 "UEFI QEMU DVD-ROM QM00013 " from PciRoot(0x0)/Pci(0x5,0x0)/Sata(0x0,0xFFFF,0x0) 2024-10-11T16:40:05.880815381Z [=3h ❯ Windows started succesfully, visit http://localhost:8006/ to view the screen... 2024-10-11T17:22:08.180452352Z ** 2024-10-11T17:22:08.180703976Z ERROR:target/i386/tcg/translate.c:748:gen_helper_out_func: code should not be reached 2024-10-11T17:22:11.093267947Z ❯ ERROR: Forcefully terminating Windows, reason: 0... 2024-10-11T17:22:15.461248620Z ❯ Shutdown completed!

Screenshots (optional)

Snipaste_2024-10-12_01-40-27

image

kroese commented 1 month ago

This looks like a bug in TCG (the part of QEMU that emulates the CPU). Maybe it was introduced in version 9.1.0 of QEMU.

The best solution is to remove KVM: "N" from your compose, and use KVM. Because TCG will be extremely slow (even if it works).

If for some reason you are really unable to enable KVM, you could try to use an older version of the container that uses an older QEMU version, for example:

image: dockurr/windows:3.13