![]() |
||
Major Member
![]() 加入日期: Apr 2007
文章: 201
|
Windows 10 評定與部署套件 與 詳論DISM
[1]安裝ADK
Windows 10 評定與部署套件 (Assessment and Deployment Kit, ADK) 正式版本下載 http://isite.tw/2015/07/15/13409 安裝: ![]() ![]() ![]() ![]() ![]() ![]() adk所安裝的程式集: ![]() 我建的桌面捷徑: ![]() 以系統管理員身分執行 ![]() 設定環境變數 Windows Preinstallation Environment下有三個cmd: ![]() 先以系統管理員身分執行:部署與映像工具環境 ![]() 切到Windows Preinstallation Environment下 然後 copype amd64 d:\WinPE_amd64 or copype x86 d:\WinPE_x86 MakeWinPEMedia /UFD d:\WinPE_amd64 i: or MakeWinPEMedia /UFD d:\WinPE_x86 i: 這就是WinPE的基本步驟,但是還不能使用,因為沒有要執行的東西。 就請看下一後面 [2]DISM 部署映像服務與管理技術參考 Windows 10 評定與部署套件 (Assessment and Deployment Kit, ADK) 其中有一部分是說DISM部署映像服務與管理(Deployment Imaging and Servicing Management)的 請先參考http://cryptocurrency.tw/viewtopic.php?f=11&t=3016 然後再看 DISM 部署映像服務與管理(Deployment Imaging and Servicing Management) 技術參考 部署映像服務與管理 (DISM) 是在部署前用來掛接和服務 WindowsR 映像的命令列工具。您可以使用 DISM 映像管理命令來掛接 Windows 映像 (.wim) 檔案或虛擬硬碟 (VHD) 以及取得相關資訊。您也可以使用 DISM 來擷取、分割和管理 .wim 檔案。 WindowsR 8 中的 ImageX 工具已經過時,而且已經用 DISM 取代來管理映像。 您也可以使用 DISM 來安裝、解除安裝、設定和更新 Windows 功能、套件、驅動程式,以及 .wim 檔案中的國際設定或使用 DISM 服務命令的 VHD。 DISM 概觀 (部署映像服務與管理) 描述 DISM 系統需求、優點、常見的服務與管理案例以及限制。 https://msdn.microsoft.com/zh-tw/library/hh825236.aspx DISM 使用方法主題 (部署映像服務與管理) 提供使用 DISM 的 how-to 指示。 https://msdn.microsoft.com/zh-tw/library/hh825176.aspx DISM 參考 (部署映像服務與管理) 提供 DISM 的參考資訊,包括命令列選項、最佳做法及支援的平台。 https://msdn.microsoft.com/zh-tw/library/hh824915.aspx [3]DISM部分與gui 若你只想做簡單的加入一些驅動,可能只要知道部分的DISM就可以了,但要更完整就需ADK了。 如下只是擷取部分的DISM: 相關DISM 與 Dism++Beta 10.1.2.2(內含Dism++幫助文檔——2015-09-03.mht繁體版) http://pan.baidu.com/s/1sjqtrOT GUI for Dism 6.2 (Win8) http://theoven.org/index.php?PHPSES...3.0;attach=2631 ![]() DISM GUI 4.0(請放入DISM目錄內) https://dismgui.codeplex.com/downloads/get/913554 關於DISM ++ (最新WinSxS清理.CompactOS壓縮工具)請看: http://www.mobile01.com/topicdetail.php?f=300&t=3757708 我對DISM ++ 清理功能不是很樂觀,對圖形介面可能較吸引我 windows 7 c ![]() ![]() 結果只是25k,哈哈!,可備份與還原!但似乎無法取代DISM,我還是要用DISM與DISM GUI 。 ![]() [4]Windows 7 usb patch boot.wim 及 install.wim 分別的功能是? 舉例如 : Windows 7 Os的啟動過程 1.Systemis powered on 2.The MBR is located on the system drive. 3.The Boot Sector is located, BOOTMGR is loaded 4.BOOTMGR looks for an active partition on sector 0. 5.BOOTMGR then reads the BCD file 6.BOOTMGR transfers control to WINLOAD.EXE contained in Boot.wim (In the case of a resume operation, WINRESUME.EXE) 7.WINLOAD.EXE initializes memory and loads drivers set to start at boot, and then transfers control to the kernel. Install.wim contains several sysprepped images of Windows 7, ready to be deployed. The setup process extracts the wim to the drive. Windows 7 並沒有內建原生的 USB 3.0 驅動程式,當只有USB 3.0的port時,mouse與keyboard都不能用,那要如何安裝?(看看你主機板是否有ps/2的接頭?) 因此我們知道主機板提供之 USB 3.0 驅動程式,必須都加入boot.wim 及 install.wim 中, 但是所謂的windows 7主機板 patch ,實際上有沒加到boot.wim 及 install.wim 中,請自行檢察。 我不知道? 這不一定是沒驅動的關係,應該要看主機板的BIOS能否正確的模擬出來usb 2.0 or ps/2的動作? 沒DOS的原生驅動,不模擬是不會動作的。(接在usb 3.0的mouse與keyboard,要變成ps/2?不知) 總之還好我沒買skylake的主機板,要自備ps/2 mouse or keyboard,這不是花錢來買罪受的! Boot.wim是有 2 index: index 1 winpe index 2 windows setup ![]() 所以指令: dism /mount-wim /wimfile:boot.wim /index:2 /mountdir:mount dism /image:mount /add-driver:"usb3" /recurse dism /image:mount /Get-Drivers /all >text1.txt (輸出driver list to text1.txt來參考) dism /unmount-wim /mountdir:mount /commit install.wim 中 dism /Get-WimInfo /WimFile:install.wim 得知 Image Index: 1 Windows 7 HOMEBASIC Image Index: 2 Windows 7 HOMEPREMIUM Image Index: 3 Windows 7 PROFESSIONAL Image Index: 4 Windows 7 ULTIMATE 所以for Windows 7 ULTIMATE 指令: dism /mount-wim /wimfile:install.wim /index:4 /mountdir:mount dism /image:mount /add-driver:"usb3" /recurse dism /unmount-wim /mountdir:mount /commit 如何檢查USB 3.0 驅動程式是否加入? 我用DISM GUI 來試驗 ![]() 複製出來看看?有沒有? ![]() 別忘了dismount ![]() [5]WinPE: Mount and Customize Common customizations: • Add device drivers (.inf files) Mount the Windows PE image Dism /Mount-Image /ImageFile:"D:\WinPE_x86\media\sources\boot.wim" /index:1 /MountDir:"D:\WinPE_x86\mount" Add the device driver to the Windows PE image. Dism /Add-Driver /Image:"D:\WinPE_x86\mount" /Driver:"D:\SampleDriver\driver.inf" Verify that the driver packages are part of the image: Dism /Get-Drivers /Image:"D:\WinPE_x86\mount" Unmount the Windows PE image. Dism /Unmount-Image /MountDir:"D:\WinPE_x86\mount" /commit Create bootable media, such as a USB flash drive. MakeWinPEMedia /UFD D:\WinPE_x86 I: • Add optional components (packages or .cab files) Dism /Add-Package /Image:"d:\WinPE_x86\mount" /PackagePath:"D:\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs\WinPE-HTA.cab" Dism /Add-Package /Image:"d:\WinPE_x86\mount" /PackagePath:"D:\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs\zh-tw\WinPE-HTA_zh-tw.cab" 最後有:List of Optional Components https://technet.microsoft.com/en-us...y/hh824926.aspx • Add a language 如加入zh-tw: Dism /Add-Package /Image:"D:\WinPE_x86\mount" /PackagePath:"D:\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs\zh-tw\lp.cab" Dism /Add-Package /Image:"D:\WinPE_x86\mount" /PackagePath:"D:\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs\zh-tw\WinPE-HTA_zh-tw.cab" Dism /Add-Package /Image:"D:\WinPE_x86\mount" /PackagePath:"D:\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs\WinPE-FontSupport-ZH-TW.cab" Dism /Set-AllIntl:zh-tw /Image:"C:\WinPE_x86\mount" • Add a startup script By default, Windows PE includes a Startnet.cmd script located at %SYSTEMROOT%\System32 of your customized Windows PE image. Startnet.cmd starts Wpeinit.exe. Wpeinit.exe installs Plug and Play devices, processes Unattend.xml settings, and loads network resources. 例如: Wpeinit –unattend:"C:\Unattend-PE.xml" 詳參考 https://technet.microsoft.com/en-us...y/hh825191.aspx • Add an app md "D:\WinPE_x86\mount\windows\<MyApp>" Xcopy C:\<MyApp> "D:\WinPE_x86\mount\windows\<MyApp>" • Add temporary storage (scratch space) Windows PE reserves memory on the X: drive to unpack the Windows PE files, plus additional temporary file storage, known as scratch space, that can be used by your applications. By default, this is 512MB for PCs with more than 1GB of RAM, otherwise the default is 32MB. Valid values are 32, 64, 128, 256, or 512: Dism /Set-ScratchSpace:128 /Image:"D:\WinPE_x86\mount" • Replace the background image Change the security permissions of the Windows PE background image file (\windows\system32\winpe.jpg). This allows you to modify or delete the file. • Add answer file settings 詳參考 https://technet.microsoft.com/en-us...y/hh825191.aspx • WinPE how to add registry keys ? In startnet.cmd reg add [6]WinPE 範例研究 Hard Disk Manager 15 Premium 10.1.25.772 WiN10 Advanced Recovery CD x86x64 https://kat.cr/paragon-hard-disk-ma...-t11039631.html ![]() ![]() Command line that ran is dism.exe /image:M:\mount /Get-Packages Deployment Image Servicing and Management tool Version: 10.0.10240.16384 Image Version: 10.0.10240.16384 Packages listing: Package Identity : Microsoft-Windows-WinPE-LanguagePack-Package~31bf3856ad364e35~amd64~en-US~10.0.10240.16384 State : Install Pending Release Type : Language Pack Install Time : 2015/7/30 上午 07:55 Package Identity : Microsoft-Windows-WinPE-Package~31bf3856ad364e35~amd64~~10.0.10240.16384 State : Install Pending Release Type : Foundation Install Time : 2015/7/10 上午 10:31 Package Identity : WinPE-FMAPI-Package~31bf3856ad364e35~amd64~~10.0.10240.16384 State : Install Pending Release Type : Feature Pack Install Time : 2015/7/30 上午 07:55 Package Identity : WinPE-SecureStartup-Package~31bf3856ad364e35~amd64~en-US~10.0.10240.16384 State : Install Pending Release Type : Language Pack Install Time : 2015/7/30 上午 07:55 Package Identity : WinPE-SecureStartup-Package~31bf3856ad364e35~amd64~~10.0.10240.16384 State : Install Pending Release Type : Feature Pack Install Time : 2015/7/30 上午 07:55 Package Identity : WinPE-WMI-Package~31bf3856ad364e35~amd64~en-US~10.0.10240.16384 State : Install Pending Release Type : Language Pack Install Time : 2015/7/30 上午 07:55 Package Identity : WinPE-WMI-Package~31bf3856ad364e35~amd64~~10.0.10240.16384 State : Install Pending Release Type : Feature Pack Install Time : 2015/7/30 上午 07:54 The operation completed successfully. 這是完全support of GPT/uEFI boot startnet.cmd內容 最後執行explauncher.exe 你可自行修改這x86與x64兩版內容,整合下一例的東西 G3258一樣要修正 -------------------------------------------------------------------------------- @echo off wpeinit rem reg for NTLM reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa" /v lmcompatibilitylevel /t reg_dword /d 00000001 /f rem start silent.exe for configure hardware cd "%systemdrive%\programs\Paragon Software\program" ren esxwrap2.dll esxwrap2_.dll cd "%systemdrive%\programs\Paragon Software\program" ren esxwrap.dll esxwrap_.dll cd "%systemdrive%\Programs\Paragon Software\program" move cxplugins cxplugins_ %systemdrive%\custom\Runner\silent.exe rem echo Stop windows firewall and related services net stop MpsSvc > %WinDir%\temp\log.log net stop IKEEXT > %WinDir%\temp\log.log net stop BFE > %WinDir%\temp\log.log rem echo Parse \custom storage if not exist %systemdrive%\custom goto continue cd /D %systemdrive%\custom :interfaces ipconfig /all > lans.lst if errorlevel 1 goto error :netconfig echo apply settings for network adapters set NETWORK_MANUAL_FLAG=false if exist network.ini ( call netcfg.bat ) else ( echo start network manually set NETWORK_MANUAL_FLAG=true cd "%systemdrive%\programs\Paragon Software\program" call netconfig.exe cd /D "%systemdrive%\custom") if errorlevel 1 goto error :mount rem echo mount shared folder if it's defined in configuration cd /D %systemdrive%\custom if exist share.bat ( call share.bat ) else if "%NETWORK_MANUAL_FLAG%"=="false" ( echo start mount network share manually cd "%systemdrive%\programs\Paragon Software\program" call netconfig.exe cd /D "%systemdrive%\custom") if "%MC_SHARED_FOLDER%"=="" goto continue if "%MC_USER%"=="" goto guest :user rem echo mount command : net use Z: "%MC_SHARED_FOLDER%" /USER:"%MC_USER%" start /MIN net use Z: "%MC_SHARED_FOLDER%" /USER:"%MC_USER%" "%MC_PASSWORD%" if errorlevel 1 goto error goto continue :guest rem echo mount command : net use Z: %MC_SHARED_FOLDER% start /MIN net use Z: "%MC_SHARED_FOLDER%" :error echo Error occurred :continue cd /d %systemdrive%\windows\system32 set flag= diskpart /s diskpart_script.txt >out1.txt FIND /I "winpe" out1.txt > out2.txt FOR /F "tokens=2,3*" %%i in (out2.txt) do ( if not "%%j"=="" ( set flag=%%j goto do_autotest ) ) :do_autotest rem verify gate for autotest if not "%flag%"=="" ( if EXIST "%flag%:\ParagonAutoTest1234\autotest4321.cmd" ( %flag%:\ParagonAutoTest1234\autotest4321.cmd %flag% goto end ) ) rem cd /D X:\Programs\ rem echo ####exit >X:\Programs\splash_mes.txt cd "%systemdrive%\programs\Paragon Software\program" echo Start ExpLauncher explauncher.exe :end -------------------------------------------------------------------------------- [7]WinPE 範例研究 download winpe 10 v10.0.10240.16384 x86 eng : https://kat.cr/winpe-10-v10-0-10240...-t11458222.html ![]() To identify the Windows PE release that you are running -------------------------------------------------------------------------------- 1. At a Windows PE command prompt, type regedit 2. Locate this registry key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinPE The Version registry value shows the Windows PE version 1. Paragon Hard Disk Manager 15 (v10.1.25.772) Professional: http://www.paragon-software.com/home/hdm-professional/ 2. Symantec Ghost 12.0.0.8010 Corporate Edition: http://en.wikipedia.org/wiki/Ghost_(software) 3. StorageCraft ShadowProtect 5.2.4.37298: http://www.storagecraft.com/product...t-shadowprotect 4. Paragon Alignment Tool 4.0 Professional: http://www.paragon-software.com/hom...tion-alignment/ 5. HDClone 6.0.5 Enterprise Edition: http://www.miray.de/products/sat.hdclone.html#ente 6. EaseUS Todo Backup 8.8: http://www.todo-backup.com/business...rver-backup.htm 先copype x86 D:\WinPE_x86 建立完整目錄,再將w10pe_x86_en.iso中\sources\boot.wim copy至D:\WinPE_x86\media\sources\下 取代原先的boot.wim 接著 Dism /Mount-Image /ImageFile:"D:\WinPE_x86\media\sources\boot.wim" /index:1 /MountDir:"D:\WinPE_x86\mount" 這時可觀看 在windows/system32下startnet.cmd內容,大概就知道在做甚麼 並修改符合所需的,如G3258 ![]() ------------------------------------------------------------ @echo off wpeinit :start echo. echo. echo. echo. echo. echo. echo.1. Paragon Hard Disk Manager 15 (v10.1.25.772) Suite GUI: echo. echo.2. Paragon Hard Disk Manager 15 (v10.1.25.772) Suite: echo. echo.3. Symantec Ghost 12.0.0.8010 Corporate Edition: echo. echo.4. StorageCraft ShadowProtect v5.2.4.37298: echo. echo.5. Paragon Alignment Tool 4.0 Professional: echo. echo 6. HDClone 6.0.5 Enterprise Edition: echo. echo.7. EaseUS Todo Backup 8.8: echo. echo 8. Quit echo. echo. echo. echo. choice /n /c:123456789 Select Number(1,2,3,4,5,6,7 or 8) if %errorlevel%==8 goto quit if %errorlevel%==7 goto pe if %errorlevel%==6 goto hd if %errorlevel%==5 goto align if %errorlevel%==4 goto sp if %errorlevel%==3 goto ghost if %errorlevel%==2 goto pg if %errorlevel%==1 goto gui :gui cls paragon goto quit ![]() cls pg goto quit :ghost cls ghost goto quit :sp cls sp goto quit :align cls align goto quit :hd cls hd goto quit ![]() cls pe goto quit :quit cls ------------------------------------------------------------------------ paragon.cmd : ------------------------------------------------------------------------ @echo off "%systemdrive%\programs\Paragon Software\program\explauncher.exe" ------------------------------------------------------------------------ 最後 Dism /Unmount-Image /MountDir:"D:\WinPE_x86\mount" /commit 完成後,再寫入隨身碟 MakeWinPEMedia /UFD D:\WinPE_x86 i: ------------------------------------------------------------------------ ps 別忘了G3258要改內容才能使用,在 http://cryptocurrency.tw/viewtopic.php?f=11&t=2858 or http://www.mobile01.com/topicdetail.php?f=300&t=4577808 已詳述了 |
|||||||
![]() |
![]() |
Major Member
![]() 加入日期: Apr 2007
文章: 201
|
新增
------------------------------------------------------------------------ [7]WinPE 範例研究 Active@ Data Studio 10.1.0.0 + Key (windows 8.1 winpe) https://kat.cr/active-data-studio-1...-t11419895.html Rufus v2.5 http://rufus.akeo.ie/ 首先安裝軟體在\Program Files\LSoft Technologies\Active@ Data Studio知下 取出BootDisk.ISO,先mount BootDisk.ISO,再取出boot.wim 由DismGui mount boot.wim ![]() 修改BOOTDISK.KEY ![]() unmount ![]() 更新BootDisk.ISO內的boot.wim 由Rufus v2.5做成usb boot disk ![]() ![]() ------------------------------------------------------------------------ |
||
![]() |
![]() |
Major Member
![]() 加入日期: Apr 2007
文章: 201
|
都有新增,請參考:
Windows 10 評定與部署套件 http://cryptocurrency.tw/viewtopic.php?f=11&t=3016 詳論DISM http://cryptocurrency.tw/viewtopic.php?f=11&t=3015 |
![]() |
![]() |
New Member
加入日期: Feb 2005 您的住址: 台北目標紐西蘭
文章: 9
|
有持續追蹤
感謝分享~~
DISM是很強大的工具,小弟也只是半懂,因為公司主力是在2008r2架AD+WDS+DNS+DHCP+MDT+WIN10 ADK派送系統,所以在ISO檔上的著墨並不多,反倒是調整應答檔+驅動程式分類群組佈署+客製化環境製作....等等等...一言難盡(感覺就是疊床架屋) 拜讀所撰文件又有一番體悟,感謝您!!(DISM文件大部分都是英文資源,辛苦板大了) |
![]() |
![]() |
Major Member
![]() 加入日期: Nov 2001
文章: 200
|
這是不是製作Windows PE光碟的教學文呢?
|
![]() |
![]() |
Regular Member
![]() ![]() 加入日期: Nov 2005 您的住址: PCDVD
文章: 75
|
訂閱先!訂閱先!
__________________
———————————————————————————— 命中有時終須有 命中無時莫強求 ![]() 但... 再給自己一次機會 敢夢就是你的 ![]() 順路買彩券 圓夢趁現在 ![]() |
![]() |
![]() |
Junior Member
![]() ![]() ![]() 加入日期: Apr 2003
文章: 751
|
這篇不推不行阿
|
![]() |
![]() |