Mads Krag Dam - Homepage - MadsD.dk

A part of iSites.dk
Home
Blog
My IT
Husband
Family
Games
Pictures
Contact

DISM Add-Package, Updates, Windows 7 Deployment and I


Written by: Mads Dam - 30.03.2010 - 2 comments

So, how to slipstream updates to a Windows 7 image??? What a lovely quest I was on there :D

In the old days, it was called slipstreaming updates and service packs into Windows images. But no more - Now it's called servicing an offline image by adding packages! Oh my xxx, that is annoying. Anyway, in Windows 7 we have the wonderful tool dism.exe - It's command-line only at the moment, but I read somewhere that MS is working on a GUI-version of the tool. Joy?

UPDATED 6 May 2010: Added Add-Drivers (+ expand-section)

First, you need to have some folders on your harddrive, I have:
C:\image
C:\image\mount
C:\image\updates
C:\image\drivers

Next, I have my image-file lying in C:\image, and I run all commands from that folder in a commandpromt with administrative priviledges.

  • Mount your image!
    dism /Mount-Wim /WimFile:Windows7_20100330.wim /index:1 /MountDir:mount

  • Apply your downloaded MSU-packages (www.microsoft.com/downloads and search for kb-numbers) one by one:
    dism /image:.\mount /Add-Package /PackagePath:.\Updates\xxxxx.msu

  • Apply your downloaded drivers (preferably WHQL-certified!)
    dism /image:.\mount /Add-Driver /Driver:.\drivers /Recurse

  • Unmount and commit the image!
    dism /Unmount-Wim /MountDir:mount /commit

That's it! The image is updated and ready to be deployed, wohoo.

Here's some more info:

  • Windows Defender update has the same KB-article number every time. It's an EXE-file and cannot be added like other updates

  • Malicious Software Removal tool has the same annoying flaws as Windows Defender (save the KB-number) and is also an EXE-file.

  • You can make a batch-file: fx updateall.cmd which can enumerate all files in the updates-folder and apply them all to the mounted image. I use this:
    for %%g in (.\Updates\*.msu) do dism /Image:.\mount /Add-Package /PackagePath:%%g

  • Drivers in subdirectories of the C:\image\drivers-folder are already applied recursively because of the /recurse-switch. So it doesn't matter that you seperate all drivertypes into subfolders named fx; lan, wlan, audio, video and so on.

  • Regarding drivers, you might have to use the expand-command to expand files ending with an underscore. Expand to a temporary directory, then take those files and replace them with the originals. (You might notice larger filesizes on the expanded files in the temporary directory). Here's the command:
    expand *.*_ C:\image\temp (I don't know if you have to create the temp-folder first.)

Thanks for reading! Hope you can use it!


Comments



ELDI wrote:


20.11.2010 20:30 - heldigard.blogspot.com

GDism ELDI last version in:

http://heldigard.blogspot.com/2010/09/gdism-eldi.html


ELDI wrote:


08.11.2010 21:37 - heldigard.blogspot.com

I make this small program in java for use the Dism.exe present in Windows 7 with GUI or Visual Mode,

Download Link:
GDism ELDI v2.2 Final:
mediafire : ?uvxd4dk6kuv9ian (...fire.com/?uvx...)
Commands you can use on GUI or Visual Mode:
* Mount-Wim
* Commit-Wim
* Unmount-Wim
* Get-WinInfo
* Get-MountedWinInfo
* CleanUp-Wim
* Get-Packages
* Add-Package
* Remove-Package
* Get-Drivers
* Get-DriverInfo
* Add-Driver
* Remove-Driver
* Make ISO
You must need the JRE installed (Java Runtime Enviroment).

@ByELDI

v2.2
Progress Bar
Time Counter

v2.1
Fixed iso making
Menu translated
Button Cancel Process

v2.0
Better Interface for results text
Make iso image with oscdimg
Support WAIK
Support x64
Better Config File
Size reduced

v1.4
Fixed Process on wait list
Config File

v1.3
Translate English-Espanol
Multiples Process Waiting

v1.2
Fixed Drivers Functions

http://www.mediafire.com/?uvxd4dk6kuv9ian



Write a comment


Name:
Website: *no http://
Comment: