ADK 10: Windows Imaging and Configuration Designer

Page 1 of 9 123 ... LastLast

  1. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
       #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

     My updated thoughts as of July 2015

    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.

     Some things you can do with Provisioning Packages:


    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




    Capture with Scanstate

     Capture Win32 software and drivers with scanstate


    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
    1. the documentation has errors at time of writing and
    2. 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.
    1. 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
    2. Combine the scanstate files with some others into the same folder
    3. Create (if it isn't already there) folder C:\Recovery\Customizations to hold your package
    4. 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
    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
    (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.)

    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





    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

     Original Post follows below. Some of this is Outdated info now


    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.
    Code:
    dism /Capture-Image /CaptureDir:E:\ /ImageFile:D:\CustomInstall.wim /Name:"Windows 8.1 Pro" /Description:"Windows 8.1 Pro"
    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.

    Note   Note
    You'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
    1. 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...

    2. 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.

    3. 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.

    4. 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'.

    5. 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.

    6. Each time I was trying to set it up, I pointed Virtualbox at two VHDs, one empty one and one holding my bootable media.

    7. 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.

    8. 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).

    9. Refresh didn't work - unsurprising as the Recovery partition stuff is in the wrong place

    10. Other working folders such as $Windows.~BT and curiously an empty Windows.old are left behind by the install process.

    11. 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:
    ADK 10: Windows Imaging and Configuration Designer-2015-02-22_14h46_38.png

    For those interested, the autounattend.xml file created by the ICD process looks like this:
    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>
    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).
    Last edited by DavidY; 02 Aug 2016 at 14:27. Reason: Updated ADK links
      My Computer


  2. Posts : 17,661
    Windows 10 Pro
       #2

    DavidY said:
    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 customisationsIn 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.
    Regarding ICD, SIM and sysprepping Build 9926, this warning from the beginning of my customization tutorial:

    warning   Warning
     Build 9926 Known Issues:


    Use the Enterprise edition for sysprepping Build 9926, normal Pro edition has a bug and sysprep fails every time (subjective piece of information, based only on my own tests). Free Enterprise download at www.microsoft.com/en-us/evalcenter/evaluate-windows-enterprise-technical-preview?i=1

    1.) Build 9926 Pro edition (from Windows Insider) fails the sysprep every time on vm and two thirds of tries on real machine. This seems to be (comical enough!) due Windows Insider app. Checking the error logs there's various errors every time, but always something common:

    "Package Microsoft.InsiderHub_1.1.0.400_x64 was installed for a user, but not provisioned for all users".

    I tried removing the AppxPackage Microsoft.InsiderHub before sysprepping, did not work. Also trying to install offline, vm not connected to network when installing to avoid installing the Hub in the first place did not help, however logical solution that had been.

    2.) Build 9926 Enterprise edition (from TechNet Evaluation Center), sysprep and customizations work every time like a charm as long as you remember to disconnect the computer or vm from the network before starting to install. As soon as you have arrived to desktop in Audit Mode you can reconnect the computer and download ADK and software to be installed. When connected to network while installing, all vm syspreps failed and over half on the real machines. As soon as I tried to install network disconnected, my success rate was 100%.

    Note   Note
    Even if the Sysprep works when done as told above, Enterprise edition installed without Internet connection, it's quite useles as it disables Start Menu, Search and Modern apps. At this point Sysprep can only be used for testing various answer file scenarios but I do not recommend using it to modify or customize a Windows setup you intend to use. Windows is nearly useless without Start and Search not to mention Modern apps like Settings and Mail not working.


    3.) You cannot create a catalog file (Part 5 Step 5.6 in this tutorial) using the install.wim file in Build 9926. Use Windows 8.1 Update, or Windows 10 Builds 9841, 9860 or 9879 install.wim. When you have saved your answer file, open it with Notepad and edit the highlighted part in below example answer file, everything between the double quotes. In this example it is wim:X:\Sources\install.wim#Windows 10 Enterprise, meaning that the Windows install media and its install.wim file used for Sysprepping (which as told above is not the same we use for catalog) are located on drive X:.
    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <unattend xmlns="urn:schemas-microsoft-com:unattend">
        <settings pass="specialize">
            <component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                <OEMInformation>
                    <Manufacturer>TenForums</Manufacturer>
                    <Model>TF-PC001</Model>
                    <SupportHours>24/7</SupportHours>
                    <SupportPhone>+1 (202) 456-1111</SupportPhone>
                    <SupportURL>TenForums.com</SupportURL>
                </OEMInformation>
                <CopyProfile>true</CopyProfile>
                <ComputerName>TF-PC</ComputerName>
                <OEMName>TenForums</OEMName>
                <RegisteredOrganization>TenForums.com</RegisteredOrganization>
                <RegisteredOwner>Kari</RegisteredOwner>
            </component>
        </settings>
        <cpi:offlineImage cpi:source="wim:X:\Sources\install.wim#Windows 10 Enterprise" xmlns:cpi="urn:schemas-microsoft-com:cpi" />
    </unattend>
      My Computer


  3. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
    Thread Starter
       #3

    Kari said:
    Regarding ICD, SIM and sysprepping Build 9926, this warning from the beginning of my customization tutorial:
    Hi Kari,

    Thanks for that - yes I was aware with the problems you posted about 9926 and I was really just playing as practice for when a better build comes along. I didn't check logs for SysPrep errors but it didn't give any obvious errors when I SysPrepped though. (Using 32 bit in a Virtualbox VM.)

    I did notice that having SysPrepped and then using DISM to capture a .wim image (which I only did once), if I used the ICD on the .wim, with CopyProfile set to True, I had the missing start menu /search as you might expect.

    The thing I didn't understand was that if I used the ICD without CopyProfile set, on the same .wim file, it did produce a version of Windows which had a start menu/search working apparently OK. I lost my custom settings, but it did have my added software (Firefox).

    So it seems to be the CopyProfile part of the process which kills the Start Menu, rather than SysPrep itself.

    This sort of makes sense to me because in Audit mode, the built in Administator doesn't have a Start menu, and it seems that CopyProfile is copying that aspect to other users.
      My Computer


  4. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
    Thread Starter
       #4

    For anyone interested in such things, I just noticed the date on the download page is now 11th March... so maybe there's a new version of the ADK?
    Download Windows Assessment and Deployment Kit (Windows ADK) for Windows 10 Technical Preview from Official Microsoft Download Center

    Edit: Just to confirm, the version of DISM has gone up from 10.0.9933.0 (in the January version) to 10.0.9942.0 (using the version I downloaded from the link above). I've not had a chance to play with it properly though and probably won't for a week or two.
    Last edited by DavidY; 17 Mar 2015 at 17:17.
      My Computer


  5. Posts : 17,661
    Windows 10 Pro
       #5

    Thanks for the tip. Waiting if we get a new build in the near future next week this week tomorrow, testing it then :).
      My Computer


  6. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
    Thread Starter
       #6

    Although they do seem to have removed the help file ADK.chm, not sure if they've replaced it with info elsewhere?
      My Computer


  7. Posts : 17,661
    Windows 10 Pro
       #7

    If the ADK is closing to be ready, it could be integrated (Help menu in ADK).
      My Computer


  8. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
    Thread Starter
       #8

    Kari said:
    If the ADK is closing to be ready, it could be integrated (Help menu in ADK).
    Thanks Kari.

    I've not found it though - perhaps I'm looking in the wrong place. There is an ADK 'Getting Started' Guide, but that mainly has links to the website for the Windows 8.1 versions of the ADK components.

    I was really looking for more info on the new DISM commands and switches such as DISM /Apply-CustomDataImage which I admit I don't understand.

    Luckily I still have the last help file but there may be more functionality in the new version.
      My Computer


  9. Posts : 1,524
    Windows 10 Pro (32-bit) 16299.15
    Thread Starter
       #9

    DavidY said:
    For anyone interested in such things, I just noticed the date on the download page is now 11th March... so maybe there's a new version of the ADK?
    Download Windows Assessment and Deployment Kit (Windows ADK) for Windows 10 Technical Preview from Official Microsoft Download Center

    Edit: Just to confirm, the version of DISM has gone up from 10.0.9933.0 (in the January version) to 10.0.9942.0 (using the version I downloaded from the link above). I've not had a chance to play with it properly though and probably won't for a week or two.
    .....and it's gone again! That link no longer works at time of writing, at least for me (anyone else?)

    Maybe another version coming?
      My Computer


  10. Posts : 17,661
    Windows 10 Pro
       #10

    I was expecting the link to disappear as soon as I had tested the ADK and SIM for Windows 10. SIM is an important part of the ADK and it simply did not work, it was impossible to create a catalog file from any image therefore impossible to create an answer file.

    Also the earlier Windows 8.1 or 8 versions of ADK don't work with Windows 10 Build 9926 or 10041 image. In order to create an answer file for these two latest build you have to use a Windows 8.1 install.wim to create the catalog, then manually edit your answer file for the correct Windows version.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 15:13.
Find Us




Windows 10 Forums