From a4d65cb737ab57defe3070ac6d4b479bba4406ff Mon Sep 17 00:00:00 2001 From: bin456789 Date: Fri, 14 Jun 2024 21:45:26 +0800 Subject: [PATCH] =?UTF-8?q?windows:=20=E5=8F=AA=E5=9C=A8=E5=8D=95=E6=A0=B8?= =?UTF-8?q?=E6=97=B6=E6=89=8D=E6=94=B9=E5=8A=A8=20win11=20=E7=9A=84=20Inst?= =?UTF-8?q?allationType?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- trans.sh | 11 +++++++---- windows-setup.bat | 5 +++++ windows.xml | 2 +- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/trans.sh b/trans.sh index 5235bd4..ad089d9 100644 --- a/trans.sh +++ b/trans.sh @@ -2873,11 +2873,14 @@ install_windows() { echo "Product Type: $product_type" echo "Product Version: $product_ver" - # 解除 win11 硬件限制 - # 24h2 26100 IoT 没有限制 TPM,但强制要求 2c2g + # win11 要求 1GHz 2核(1核超线程也行) + # 用注册表无法绕过 + # https://github.com/pbatard/rufus/issues/1990 # https://learn.microsoft.com/windows/iot/iot-enterprise/Hardware/System_Requirements - if [[ "$image_name" = "Windows 11"* ]]; then - wiminfo "$install_wim" "$image_name" --image-property WINDOWS/INSTALLATIONTYPE=Server + if [ "$product_ver" = "11" ]; then + if [ "$(grep -c '^processor' /proc/cpuinfo)" -le 1 ]; then + wiminfo "$install_wim" "$image_name" --image-property WINDOWS/INSTALLATIONTYPE=Server + fi fi # 变量名 使用场景 diff --git a/windows-setup.bat b/windows-setup.bat index 402b705..c59a5da 100644 --- a/windows-setup.bat +++ b/windows-setup.bat @@ -108,6 +108,11 @@ move /y %tempFile% %file% rename X:\setup.exe.disabled setup.exe +rem https://github.com/pbatard/rufus/issues/1990 +for %%a in (RAM TPM SecureBoot) do ( + reg add HKLM\SYSTEM\Setup\LabConfig /t REG_DWORD /v Bypass%%aCheck /d 1 /f +) + rem 设置 set EnableEMS=0 set ForceOldSetup=1 diff --git a/windows.xml b/windows.xml index c9068a5..369a18c 100644 --- a/windows.xml +++ b/windows.xml @@ -31,7 +31,7 @@