Patching Images in a WIM File
October 23, 2007
Q. I've patched all the images in a Windows Imaging Format (WIM) file but even after replacing files on all the images, the WIM size hasn't shrunk.
A. It would seem logical that if you apply an update to every image in a WIM file, then the files that are now not referenced in the WIM would be removed, but this is not the process. The WIM contains a catalog of files from which each image links to. If no image links to a file anymore, the file isn't removed from the WIM file. To shrink the size of the WIM you need to export all the images from the WIM to a new WIM file. To do so, you can use the following sample command:
D:OS ImagesVista>imagex /export install.wim * install2.wim "Lean Vista"
In this example, the * specifies to export all images. You could instead put a number to export a specific image from the source WIM (install.wim). The exported WIM will contain only the files used by the exported images.
— John Savill
About the Author
You May Also Like