Changes between Version 5 and Version 6 of opsi/winpe
- Timestamp:
- Mar 11, 2021, 6:57:48 PM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
opsi/winpe
v5 v6 5 5 Used to install Windows >= 7 with OPSI. 6 6 7 Gern erl Information about WinPE at http://en.wikipedia.org/wiki/Windows_Preinstallation_Environment7 Gernal Information about WinPE at http://en.wikipedia.org/wiki/Windows_Preinstallation_Environment 8 8 9 Since Windows 8, WinPE 4.0 is available. However, Windows 8 can also be installed using WinPE 3.x. 9 == Preparing WinPE from Linux == 10 10 11 == WinPE 3.x == 11 The (excellent) OPSI documentation describes at length, how to prepare a full OS Windows installation (see https://download.uib.de/opsi4.1/documentation/html/en/opsi-getting-started-v4.1/opsi-getting-started-v4.1.html#opsi-getting-started-firststeps-osinstall-fill-base-packages-nt6). 12 12 13 Since Windows 7. 13 This can be archived quicker, especially, the preparing WinPE can be done directly on the Linux OPSI server, instead of using Windows and the need to install WAIK (or ADK): 14 14 15 see http://download.uib.de/opsi4.0/doc/html/opsi-getting-started/opsi-getting-started.html#opsi-getting-started-firststeps-osinstall-fill-base-packages-nt6 16 17 Alternativly use following commands: 18 19 Install Windows WAIK 15 Have your Windows installation ISO available. We assume, it is named {{{/tmp/Win10_x64.iso}}}. 20 16 21 17 {{{ 22 c: 18 # 19 # Variables. Adapt them to your needs. 20 # 21 WINDOWS_ISO=/tmp/Win10_x64.iso 22 PROD=win10-x64 23 23 24 rem Create Initial winpe directory 25 c:\Program Files\Windows AIK\Tools\PETools\copype.cmd amd64 c:\winpe64 24 # 25 # install required software 26 # 27 apt install wimtools syslinux p7zip-full 28 # CentOS/SUSE: yum install wimtools syslinux p7zip p7zip-plugins 26 29 27 copy c:\winpe64\winpe.wim c:\winpe64\ISO\sources\boot.wim 30 # 31 # Install required OPSI product 32 # 33 opsi-package-updater install ${PROD} 34 cd /var/lib/opsi/depot/${PROD} 28 35 29 # set variables 30 set wim=c:\winpe64\ISO\sources\boot.wim 31 set md=c:\winpe64\mount 36 # 37 # Copy ISO content to installfiles 38 # 39 7z x ${WINDOWS_ISO} installfiles 32 40 33 rem Mount and modify WinPE boot image 41 # 42 # Create winpe 43 # 44 mkdir -p winpe-overlay/Windows/System32 45 printf "%s\r\n" "c:\opsi\startnet.cmd" > winpe-overlay/Windows/System32/startnet.cmd 46 mkwinpeimg --windows-dir=installfiles --overlay=winpe-overlay winpe.img 47 7z x winpe.img -owinpe/ 34 48 35 cd c:\winpe64 36 dism /Get-WIMInfo /WimFile:%wim% 37 38 dism /cleanup-wim 39 40 dism /Mount-Wim /WimFile:%wim% /index:1 /MountDir:%md% 41 42 type C:\winpe64\mount\Windows\System32\startnet.cmd 43 echo c:\opsi\startnet.cmd > %md%\Windows\System32\startnet.cmd 44 45 dism /unmount-Wim /MountDir:%md% /Commit 49 # 50 # Adapt produkts 51 # 52 opsi-admin -d method updateWIMConfig ${PROD} 46 53 }}} 47 54 48 More customazations are explained at wiki:opsi/dism 55 Using {{{7z x ${SRC} -o${DEST}}}} is a shortcut to avoid mounting the ISO or disk image files. 56 If you prefer, you can use this: 57 {{{ 58 TMP=$(mktemp -d) 59 sudo mount ${SRC} ${TMP} 60 cp -a ${TMP}/. ${DEST]/. 61 sudo umount ${TMP} 62 }}} 49 63 50 64 51 Copy ISO subdirectory as winpe Directory to OPSI server: 52 53 {{{ 54 cp ISO/. /var/lib/opsi/depot/win*\winpe/. 55 }}} 56 57 Hint: The boot.wim file is also accessable by the 7z archiving programm (at least for WinPE versions <4.0) 65 = Outdated approaches = 58 66 59 67 == WinPE 4.0 == 60 61 Currently this is not supported by OPSI. Modifying this images works, but driver integration fails (create_driver_links.py tries to extract drivers using 7z, which does not work for WinPE >= 4.0).62 68 63 69 === Modify WinPE for OPSI === … … 104 110 }}} 105 111 112 113 114 == WinPE 3.x == 115 116 Since Windows 7. 117 118 see http://download.uib.de/opsi4.0/doc/html/opsi-getting-started/opsi-getting-started.html#opsi-getting-started-firststeps-osinstall-fill-base-packages-nt6 119 120 Alternatively use following commands: 121 122 Install Windows WAIK 123 124 {{{ 125 c: 126 127 rem Create Initial winpe directory 128 c:\Program Files\Windows AIK\Tools\PETools\copype.cmd amd64 c:\winpe64 129 130 copy c:\winpe64\winpe.wim c:\winpe64\ISO\sources\boot.wim 131 132 # set variables 133 set wim=c:\winpe64\ISO\sources\boot.wim 134 set md=c:\winpe64\mount 135 136 rem Mount and modify WinPE boot image 137 138 cd c:\winpe64 139 dism /Get-WIMInfo /WimFile:%wim% 140 141 dism /cleanup-wim 142 143 dism /Mount-Wim /WimFile:%wim% /index:1 /MountDir:%md% 144 145 type C:\winpe64\mount\Windows\System32\startnet.cmd 146 echo c:\opsi\startnet.cmd > %md%\Windows\System32\startnet.cmd 147 148 dism /unmount-Wim /MountDir:%md% /Commit 149 }}} 150 151 More customazations are explained at wiki:opsi/dism 152 153 154 Copy ISO subdirectory as winpe Directory to OPSI server: 155 156 {{{ 157 cp ISO/. /var/lib/opsi/depot/win*\winpe/. 158 }}} 159 160 Hint: The boot.wim file is also accessable by the 7z archiving programm (at least for WinPE versions <4.0) 161 106 162 = Other = 107 163