New
#1
ADK 10: Windows Imaging and Configuration Designer
I am going to update the original post below with some later information, including from some of the posts on the thread.
Last edited: 2 August 2016
2 August comment:
New 1607 ADK now available (from the same link as before)
25 July comment:
I see that a lot of this is about to change - apparently with the '1607' release of the ADK there will be 'Siloed Provisioning Packages' which seems interesting, and there are some new help pages .I don't know how to get the latest ADK yet though...
Meanwhile, here are some links:
Link to the ADKSetup for build 10240 of the Assessment and Deployment Kit:
Link to Windows ADK for Windows 10, Version 1607:
http://go.microsoft.com/fwlink/p/?LinkId=526740
from this page:
https://developer.microsoft.com/en-u...deployment-kit, which says:
Note: You must use Windows 10, version 1607 with this version of the ADK.
Link to Windows ADK for Windows 10, Version 1511:
https://go.microsoft.com/fwlink/p/?LinkId=823089
from this page:
https://developer.microsoft.com/en-u...deployment-kitwhich says:
You must use Windows 10, version 1511 with this version of the Windows ADK and the Windows 10 IoT Core ADK Add-Ons for version 1511.
or this one:
https://msdn.microsoft.com/en-us/windows/hardware
Generate a provisioning package (MSDN)
https://msdn.microsoft.com/en-us/lib...=vs.85%29.aspx
Customize using the Windows Provisioning framework (MSDN)
https://msdn.microsoft.com/en-us/lib...=vs.85%29.aspx
I'm going to stick with something I said in February :"It will be nice when it's finished!" (And it will be really nice when the documentation is finished ) Things have moved on since February but there are still some flaky things in this area of code and errors or omissions in the current documentation.
However I offer the following thought:
If you want to understand Customisation, Recovery and Deployment in Windows 10, then you need to know about Provisioning Packages.
I'm not saying I fully understand Provisioning Packages yet, but it's clear that a lot has changed in this area and they're the key to understanding the changes.
Provisioning Packages let you save customisations for use by yourself later (eg. Recovery) or to deploy those customisations to another machine. Customisations can include software and settings. For new Universal Apps you can use the new Windows Imaging and Configuration Designer (Windows ICD) to add customisations to a Provisioning Package. For the traditional Win32 software you can install the software packages onto a machine and then capture them into a Provisioning Package with the scanstate tool, which is part of the User State Migration Toolkit USMT) in the Assessment and Deployment Kit (ADK). This same scanstate tool allow allows you to capture drivers.
Once you have your Provisioning Package, it can be deployed easily on a running Windows installation, or saved on the disk so those customisations are deployed when you do a Reset, or included on a Recovery Drive.
Capture with Scanstate: Capture Win32 software and drivers with scanstate
Video walkthrough of Scanstate Video walkthrough of using Scanstate to capture Provisioning Packages, and test of Reset and Recovery Drive
Video walkthrough of using WICD to Clean Install Video walkthrough of using WICD to create a Clean Installer, and test of Reset
Original Post My original post from Feb
Scanstate is part of the User State Migration Toolkit, within the Windows 10 ADK, and although it has been around in earlier versions, with Windows 10 it has gained some key options.
In particular scanstate /apps /drivers /ppkg will capture your windows software and drivers into a provisioning package for use later.
However there are currently some "gotcha"s
- the documentation has errors at time of writing and
- the scanstate tool relies on files which are in a different folder, and which aren't in the file path
So you need to do the following. It's not clear whether you need to be in 'Audit Mode' to do this - the documentation is (as ever) vague on this point. It seemed to work for when I wasn't in Audit Mode but YMMV. Whatever you do, make sure you're running as an admin-level user rather than a standard user.
- Install the Windows 10 ADK (link at the top of this post), making sure you include the User State Migration Toolkit in the options you select
- Combine the scanstate files with some others into the same folder
- Create (if it isn't already there) folder C:\Recovery\Customizations to hold your package
- Run the scanstate command to capture your setup
The folder C:\Recovery\Customizations has special status and is a key operating system folder. Some care is needed with changing things in this folder! For instance I don't think you should put files which are not .ppkg files there.
My basic script is
(Note that I'm using "x86" as I'm on a 32-bit installation. For 64-bit you'd need to change x86 to amd64 above.)Code:md c:\recovery\customizations md c:\temp\Scanstate cd c:\temp\scanstate xcopy "C:\Program Files\Windows Kits\10\Assessment and Deployment Kit\windows setup\x86\sources" xcopy /s /y "C:\Program Files\Windows Kits\10\Assessment and Deployment Kit\User State Migration Tool\x86\*.*" scanstate /apps /drivers /ppkg c:\recovery\customizations\usmt.ppkg /o /c /v:13 /l:c:\temp\scanstate.log
Or you could use kyhi's script in post 26 of this thread which is much more sophisticated than mine! Use the files from post 26 with the updated script in post 49
Has anyone else tried to use the Windows 10 Assessment and Deployment Kit (ADK), and in particular the new Windows Imaging and Configuration Designer (Windows ICD)?
I've had a play so thought I'd note a few things down in case it helps someone.
The summary is - it will be nice when it's finished! (Or at least when there's better documentation to explain how to make it work.)
I think it should let those of us with a geeky disposition customise our Windows setup, then install onto a computer, making our own recovery partition which will allow a Reset or Refresh back to our own custom settings.
One aim I have is to put Windows 10 TP on my cheap tablet, which came with WIMBoot operating system compression. WIMBoot was new to Windows 8.1, but seems to have been superseded already by a different compressed OS technology in Windows 10. The aim in both cases is to compress the Operating System so it can run on devices like mine (with a 32GB disk) and allow Reset and Refresh to work as well.
There are some new options in DISM to make a Compressed OS, which are
- /Apply-Image with the new /Compact switch, and the totally new
- /Apply-CustomDataImage option.
However I can't figure out how to put them together to make it work - maybe an option isn't there yet?
The ICD needs a .wim file to work with so I thought I'd try and make a custom .wim file. So I fired up VirtualBox created a (lightly) customised version of Windows 9926 (32-bit) as per Kari's tutorial here. All I did to customise was install Firefox and tweak some settings in Explorer, IE and Control Panel.
At part 7 in that tutorial, instead of Macrium, I booted my VM in WinPE (using the WinPE from the new ADK) and used DISM to capture my customised image as a .wim file.
where D:\ is my WinPE disk, which I'd made sure had enough space to hold this, and E:\ is the drive where Windows was running.Code:dism /Capture-Image /CaptureDir:E:\ /ImageFile:D:\CustomInstall.wim /Name:"Windows 8.1 Pro" /Description:"Windows 8.1 Pro"
NoteYou'll note that I set the Name and Description to "Windows 8.1 Pro". When I didn't do this (originally I set Name="DYTest" and left the Description blank) then the setup file created by the ICD didn't work - it gave an error saying 'setup has failed to validate the product key' even before it gives you a chance to enter one. When I put in the Windows 10 TP product key in the xml files it didn't help either.
So I used "Windows 8.1 Pro" because that is how the original 9926 of 10 Preview describes itself. This change made it work; it's possible other values work too.
I then had a play with the ICD, with the aim of creating a Setup file for a new installation of Windows and note the following
- The ICD tool itself worked first time on Windows 10 but on Windows 8.1 it wouldn't work for some reason. I tried restarting, uninstalling, reinstalling and this didn't help. But opening the 'Deployment and Imaging Tools Environment' (as administrator), which is effectively a command prompt plus some settings, navigating to icd.exe and running it did work. Then ICD worked from the start screen with no problem from then on. Maybe a workaround or maybe coincidence...
- The ICD lets you customise many of the settings mentioned in Kari's tutorial when creating an answer file. It also seems to let you add Store apps to a build. However I couldn't figure out how to add non-Store apps like Firefox or to configure settings like view settings in File Explorer. But next time I won't bother with changing most of the settings (like OEM name) when I create the initial image.
- The settings include a 'CopyProfile' setting (within 'Shell').
In W10 build 9926, when I didn't set CopyProfile, then the version of Windows created later had a working Start Menu and Search, and included the Firefox software I'd installed, but lost my user customisations
In W10 build 9926, when I did set CopyProfile, then the version of Windows created later had Firefox, and my user customisations... but no Start Menu or Search.
- Using the option from ICD to create Clean Install Media seems to be quite similar to the option to create Production Media. The Production Media option has an extra option to 'Compress OS'.
- I used the options to copy the media files to a folder (rather than a USB, which I couldn't figure out how to boot in Virtualbox) then made a VHD, copied on the media files and used Diskpart to make it bootable.
- Each time I was trying to set it up, I pointed Virtualbox at two VHDs, one empty one and one holding my bootable media.
- When I booted in VirtualBox from my VHD, it goes through a process of setting up the PC, with no interaction if I'd selected Clean Install. For the files produced with the Production Media option, the setup process sometimes asked me to select a drive letter (not sure how this would work on a blank unformatted disk) so I used Shift-F10 to bring up a command prompt to check which drive was which.
- It did eventually install a running copy of Windows 10, but something had gone wrong with the recovery folders which seem to be on the main boot drive rather than recovery partition (which it did create, but didn't populate).
- Refresh didn't work - unsurprising as the Recovery partition stuff is in the wrong place
- Other working folders such as $Windows.~BT and curiously an empty Windows.old are left behind by the install process.
- I couldn't get it to setup a VM running in EFI mode at all.
Here is what the ICD looks like after I'd tweaked a few settings:
For those interested, the autounattend.xml file created by the ICD process looks like this:
I'm not sure whether I needed to enter the Product Key or not here - it didn't seem to make much difference. Also I just tried enabling all Start Menu options to see if it would bring it back when CopyProfile was true (it didn't).Code:<?xml version="1.0"?> <Settings xmlns="urn:schemas-microsoft-com:windows-provisioning"> <Customizations> <Common> <OEM> <Name>DavidY</Name> <Information> <SupportURL>https://www.tenforums.com</SupportURL> <Model>DY Custom 9926 Try2</Model> <SupportPhone>123456789</SupportPhone> <SupportHours>Never</SupportHours> <Manufacturer>DavidY Inc</Manufacturer> </Information> </OEM> <Computer> <Name>VM_Custom_Try2</Name> </Computer> <Setup> <ProductKey>NKJFK-GPHP7-G8C3J-P6JXR-HQRJR</ProductKey> </Setup> <StartMenu> <UseClassicAppearance>True</UseClassicAppearance> <Enable>True</Enable> <ShowPowerButton>True</ShowPowerButton> </StartMenu> <Shell> <CopyProfile>True</CopyProfile> </Shell> </Common> </Customizations> <UnattendedSetup> <InstallWindows> <WimImage> <Path>install.wim</Path> <ImageIndex>1</ImageIndex> </WimImage> <Destination> <Disk>BootDisk</Disk> <Partition>Automatic</Partition> <ProvisionDisk>Standard</ProvisionDisk> </Destination> </InstallWindows> <EnableCompactOS>True</EnableCompactOS> <RecoveryImage>Install</RecoveryImage> <InitialCustomizationBlob/> <ProductKey>PromptAtOOBE</ProductKey> <Eula>PromptAtOOBE</Eula> </UnattendedSetup> <Provisioning> <ProvisioningPackages> <ProvisioningPackage>ProvisioningPackages\ICD_Customizations.ppkg</ProvisioningPackage> </ProvisioningPackages> </Provisioning> </Settings>
Last edited by DavidY; 02 Aug 2016 at 14:27. Reason: Updated ADK links