Jump to content

Dism /Apply-unattend on attached VHD


Recommended Posts

Well, I've applied a previously sys-prepared image (full of custom software installed) to a VHD:

imagex /apply C:\install.wim 1 V:

where V: is attached VHD assigned to letter V using diskpart. Then, to avoid 3-times sysprep limit (and to skip some OOBE passes) I've run this command:

dism /Image:V:\ /Apply-unatted:C:\Unattend.xml

Im' guessing this is not working because firing a virtual machine and booting the VHD OOBE still ask for timezone, protect pc, network config and so on. My Unatted.xml is quite simple:


<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
<settings pass="generalize">
<component name="Microsoft-Windows-Security-SPP" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral"
versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State"]http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"]http://www.w3.org/2001/XMLSchema-instance">
<SkipRearm>1</SkipRearm>
</component>
</settings>
<settings pass="oobeSystem">
<component name="Microsoft-Windows-International-Core" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral"
versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State"]http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"]http://www.w3.org/2001/XMLSchema-instance">
<InputLocale>0410:00000410</InputLocale>
<SystemLocale>it-IT</SystemLocale>
<UILanguage>it-IT</UILanguage>
<UserLocale>it-IT</UserLocale>
</component>
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral"
versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State"]http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"]http://www.w3.org/2001/XMLSchema-instance">
<OOBE>
<HideEULAPage>true</HideEULAPage>
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
<NetworkLocation>Home</NetworkLocation>
<ProtectYourPC>1</ProtectYourPC>
</OOBE>
<TimeZone>W. Europe Standard Time</TimeZone>
</component>
</settings>
</unattend>

Link to comment
Share on other sites


I haven't tested with VHD, but with creating an other partition and without using the OOBE part with sysprep!

I think you can find help here:

New Videos made by ricktendo64:

http://www.wincert.net/forum/index.php?/topic/7384-video-windows-7-aikopk-deployment-101-updated/

http://forums.techarena.in/guides-tutorials/1175447.htm

Unattended Servicing Command-Line Options

Edited by myselfidem
Link to comment
Share on other sites

The only bad thing about using dism on a attached vhd is there is no /discard to undo stuff if you screw up...whatever you do is permanent

You might be able to get around it by using a oobe.xml with all the configurations

Edited by ricktendo64
Link to comment
Share on other sites

  • 9 months later...

When installing drivers with DISM, is there any way to indicate which driver is boot critical and must be added to CriticalDeviceDatabase, and which is not, and shouldn't be added to it?

Dism does that itself. If you watch it process a group you will see it adding to boot-critical
Link to comment
Share on other sites

  • 1 month later...

Perhaps you should do a brand new custom installation and use sysprep audit mode until you get to the final configuration you want, then capture the image and deploy it!

Of course you can try the sysprep audit mode on the existing sysyprepped image, and perform dism modifications on the wim file, and see what you get...

Edited by daremo
Link to comment
Share on other sites

The only bad thing about using dism on a attached vhd is there is no /discard to undo stuff if you screw up...whatever you do is permanent

I'm not sure how to take this statement. If you have an attached VHD, and apply a wim file, and you're not happy with the result, you can always do a quick format of the VHD, modify your wim, and reapply.

If this is a situation where you already had data in the VHD and are applying a wim and not happy with the results, the only UNDO option you have is making use of a differencing VHD:

1. Keep your original data in the parent VHD (parent vhd),

2. create a differencing VHD (child vhd),

3. apply wim on the differencing vhd

4. test results...

If not happy, remove the differencing disk, recreate it, and modify what ever it is you want to modify in your wim, and re-apply the wim on the new differencing disk.

If you're happy with the results, then merge the differencing disk with the parent disk, and then you can remove the old vhd disks, and make use of the new vhd (merged VHD).

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...