Tommy 碎碎念

Tommy Wu's blog

« 上一篇 | 下一篇 »

自製 Windows 8 All-in-one 安裝光碟
post by tommy @ 30 元月, 2013 10:20

如同之前 Win7 一樣, 我們可以把 Win8 的所有版本, 合併到同一張光碟片中, 安裝時再選擇需要的版本就可以了.

作法是參考這篇文章的內容. 只是 script 的部份有些不同 (不知道為什麼要用 PowerShell 來處理, 裡頭明明都是用一般的指令就可以做到), 以下是以 MSDN 的光碟版本為例.

  • 首先是到微軟的網站抓 Windows 8 ADK 回來, 只要安裝 "部署工具" 就可以 (當然你要裝其他的也可以).
  • 接著建立一個目錄, 例如是 C:\Windows8Root, 然後在下面建立這些子目錄如下:

C:\Windows8Root
C:\Windows8Root\x86
C:\Windows8Root\x64
C:\Windows8Root\Enterprisex86
C:\Windows8Root\Enterprisex64
C:\Windows8Root\Final
C:\Windows8Root\Temp

  • 接著把 x86 (如果用 x64 的版本, 如果到時要安裝到非 x64 的機器上, 會無法使用) 的光碟內容整個 Copy 到 C:\Windows8Root\Final 目錄下.
  • 把每個光碟裡頭的 install.wim (在 sources 目錄下), Copy 到 C:\Windows8Root 底下相對的目錄中.
  • 在 C:\Windows8Root\Final\sources 目錄下建立一個名稱為 EI.cfg 的文字檔如下:

[Channel]
Retail
 
[VL]
0
  • 在 C:\Windows8Root 建立一個批次檔 do_dism.bat, 內容如下:

@echo on
 
setlocal
set MYROOT=%~dp0
set MYTEMP=%MYROOT%Temp
set FINALDIR=%MYROOT%Final
set FINALWIM=%FINALDIR%\sources\install.wim
set FINALISO=%MYROOT%Windows8.iso
 
set X86FILE=%MYROOT%x86\install.wim
set X64FILE=%MYROOT%x64\install.wim
set X86ENTFILE=%MYROOT%Enterprisex86\install.wim
set X64ENTFILE=%MYROOT%Enterprisex64\install.wim
 
if exist %FINALWIM% del %FINALWIM%
if exist %FINALISO% del %FINALISO%
 
Dism /Export-Image /SourceImageFile:%X86FILE% /SourceIndex:2 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8" /compress:maximum
Dism /Export-Image /SourceImageFile:%X86FILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Pro" /compress:maximum
Dism /Export-Image /SourceImageFile:%X86FILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Pro with Media Center" /compress:maximum
Dism /Export-Image /SourceImageFile:%X86ENTFILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Enterprise" /compress:maximum
Dism /Export-Image /SourceImageFile:%X64FILE% /SourceIndex:2 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8" /compress:maximum
Dism /Export-Image /SourceImageFile:%X64FILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Pro" /compress:maximum
Dism /Export-Image /SourceImageFile:%X64FILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Pro with Media Center" /compress:maximum
Dism /Export-Image /SourceImageFile:%X64ENTFILE% /SourceIndex:1 /DestinationImageFile:%FINALWIM% /DestinationName:"Windows 8 Enterprise" /compress:maximum
 
Dism /Mount-Wim /WimFile:%FINALWIM% /index:3 /MountDir:%MYTEMP%
Dism /Image:%MYTEMP% /Set-Edition:ProfessionalWMC
Dism /Unmount-Wim /MountDir:%MYTEMP% /Commit
 
Dism /Mount-Wim /WimFile:%FINALWIM% /index:7 /MountDir:%MYTEMP%
Dism /Image:%MYTEMP% /Set-Edition:ProfessionalWMC
Dism /Unmount-Wim /MountDir:%MYTEMP% /Commit
 
Imagex /Info %FINALWIM% 1 "Windows 8 (32 位元)" "Windows 8 (32 位元)"
Imagex /Info %FINALWIM% 2 "Windows 8 專業版 (32 位元)" "Windows 8 專業版 (32 位元)"
Imagex /Flags ProfessionalWMC /Info %FINALWIM% 3 "Windows 8 專業版 (含 Media Center) (32 位元)" "Windows 8 專業版 (含 Media Center) (32 位元)"
Imagex /Info %FINALWIM% 4 "Windows 8 企業版 (32 位元)" "Windows 8 企業版 (32 位元)"
 
Imagex /Info %FINALWIM% 5 "Windows 8 (64 位元)" "Windows 8 (64 位元)"
Imagex /Info %FINALWIM% 6 "Windows 8 專業版 (64 位元)" "Windows 8 專業版 (64 位元)"
Imagex /Flags ProfessionalWMC /Info %FINALWIM% 7 "Windows 8 專業版 (含 Media Center) (64 位元)" "Windows 8 專業版 (含 Media Center) (64 位元)"
Imagex /Info %FINALWIM% 8 "Windows 8 企業版 (64 位元)" "Windows 8 企業版 (64 位元)"
 
Oscdimg -b%FINALDIR%\boot\etfsboot.com -h -u2 -m -lWindows8 %FINALDIR% %FINALISO%
 
:end
  • 執行 "程式集\Windows Kits\Windows ADK\部署與映像工具環境" 這個程式 (如果有問題, 請用系統管理員的方式去執行)
  • 上頭的指令會出現一個命列提示字元的視窗, 在那個視窗中, 切換到 C:\Windows8Root 的目錄, 然後執行 do_dsim.bat 這個批次指令, 等結束後, 就會產生一個 Windows8.iso 在 C:\Windows8Root 的目錄. 這個 iso 檔案就是整合後的光碟了.

用 MSDN 的版本做出來的光碟, 如果在 EI.cfg 上頭的 Channel 用 Retail 時, 會在選擇 "企業版" 時, 出現的授權訊息是 RC 版的內容, 不過安裝的東西一樣是 RTM 的內容, 應該就只有那個授權畫面不正確而已. 如果把 Channel 改成 Volume, 則在 "企業版" 出現的授權說明是正確的, 不過在其他的版本反而是不正確的.

如果你對上頭那個授權說明一定要是正確的, 可以自行把該版本的 install.wim 用 dism mount 起來, 然後修改裡頭的 Windows\System32\zh-TW\Licenses\_Default 底下對應版本目錄下的 license.rtf 的內容 (可以複製其他目錄底下正確的那一個檔案), 要記得先去取得該檔案的所有權, 再去新增權限才能對該檔案異動. 改好後, 再用 dism umount (使用 commit) 就可以.

Del.icio.us Furl HEMiDEMi Technorati MyShare
commons icon [1] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

請問一下windows8.1也能這樣整合還市那邊需要修改

commons icon [2] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

Windows 8.1 應該是一樣的做法就能整合.

commons icon [3] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

不過我試作了一下不行所以才想跟板大請教一下

commons icon [4] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

我使用 MSDN 的光碟做過 (之前 9 月中的版本), 用 VM 裝看起來是沒問題的. (MCE 的部份不確定, 不過其他的版本是正常的)

你的問題是什麼呢? 沒選單? 還是裝起來的版本不對?

對了, 我是用 Windows 8.1 的 ADK 處理的.

commons icon [5] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

封裝完成沒選單
還有一進去還要輸入序號

commons icon [6] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

沒選單表示沒有 EI.CFG (或寫錯?) 吧.

輸入序號的地方可以忽略 (上頭的文章也沒寫要跳過這部份吧).... 要自動輸入序號... 我沒做過, 自己 Google 看看有沒有教學文吧.

commons icon [7] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

請問一下windows 10整合方法也跟windows 8一樣嗎

謝謝

commons icon [8] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

Windows 10 做法應該一樣.

commons icon [9] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

謝謝您我在試看看嚕

commons icon [10] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

WIN10這段指令不支援
Imagex /Info %FINALWIM% 1 "Windows 10 (32 位元)" "Windows 10 (32 位元)"
就不能把映像檔成加上X86或X64
應該有新的指令代替

commons icon [11] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

我剛剛試過了, 可以正常執行, 並沒有你說的問題.
PS. 我用的 Windows 10 ADK. 另外 Windows 10 應該沒有 WMC 的版本, 所以有關 WMC 的部份應該都不能做.

commons icon [12] Re:自製 Windows 8 All-in-one 安裝光碟 [ 回覆 ]

原來是我沒裝Win10的ADK
用Win10原本內建的CMD可以執行前面的指令
但在Imagex /Info就錯誤了
謝謝你了

迴響
暱稱:
標題:
個人網頁:
電子郵件:
authimage

迴響

  

Bad Behavior 已經阻擋了 93 個過去 7 天試圖闖關的垃圾迴響與引用。
Power by LifeType. Template design by JamesHuang. Valid XHTML and CSS