none
After Sysprep, System Restore is turned off -- how to stop that from happening?

    Question

  • So, as I work through my unattend.xml file, I'm finding that SystemRestore is being turned off in Windows 8 using the same unattend.xml file that I started with for Windows 7.

    I tried adding this to the Windows 8 unattend.xml file:

            <component name="Microsoft-Windows-SystemRestore-Main" 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">
                <DisableSR>0</DisableSR>

    But that has no effect -- SystemRestore is still turned off after I sysprep the system.

    The policy settings related to Windows 8 are the same as they are on Windows 7:

    "Turn off System Restore" -- is set to "Not configured" -- on both Windows 7 and 8

    and the "Microsoft Software Shadow Copy Provider" service is set to "Manual" on both Operating Systems as well.

    Am I missing a new Registry Setting in Windows 8 that I need to toggle to keep System Restore turned on after the sysprep is done?

    Tuesday, September 25, 2012 3:18 PM

Answers

  • To answer my own question, I needed to add this this:

       

                <FirstLogonCommands>
                    <SynchronousCommand wcm:action="add">
                        <Description>Enable System Restore</Description>
                        <Order>1</Order>
                        <CommandLine>C:\Windows\System32\wbem\wmic /namespace:\\root\default path SystemRestore call Enable %SystemDrive%\</CommandLine>
                    </SynchronousCommand>
               </FirstLogonCommands>

    And then system restore is turned on after sysprep

    • Marked as answer by steve maser Friday, September 28, 2012 1:33 PM
    Wednesday, September 26, 2012 4:19 PM

All replies

  • I should note that there does appear to be a new (?) registry setting in:

    HKLM\Software\Microsoft\WindowsNT\CurrentVersion\SystemRestore\Setup  (which contains a "Generalize" and "Unattend" option -- both with a DisableSR set to 0 in them)

    That is not there on my Windows 7 master image...

    Tuesday, September 25, 2012 3:22 PM
  • To answer my own question, I needed to add this this:

       

                <FirstLogonCommands>
                    <SynchronousCommand wcm:action="add">
                        <Description>Enable System Restore</Description>
                        <Order>1</Order>
                        <CommandLine>C:\Windows\System32\wbem\wmic /namespace:\\root\default path SystemRestore call Enable %SystemDrive%\</CommandLine>
                    </SynchronousCommand>
               </FirstLogonCommands>

    And then system restore is turned on after sysprep

    • Marked as answer by steve maser Friday, September 28, 2012 1:33 PM
    Wednesday, September 26, 2012 4:19 PM
  • Hi,

    Please check if the following registry exists. If so, please delete it for a test.
    HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\SystemRestore

    Meanwhile, set DisableSR to 1 under following registry:
    HKLM\Software\Microsoft\WindowsNT\CurrentVersion\SystemRestore\Setup


    Niki Han

    TechNet Community Support

    Friday, September 28, 2012 8:20 AM
    Moderator
  • Hi,

    Please check if the following registry exists. If so, please delete it for a test.
    HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\SystemRestore

    Meanwhile, set DisableSR to 1 under following registry:
    HKLM\Software\Microsoft\WindowsNT\CurrentVersion\SystemRestore\Setup

    The SystemRestore registry under Policies -- did not exist on this clean-install Windows 8 64-bit

    \SystemRestore\Setup -- does not have DisableSR in it.

    However \SystemRestore\Setup\Generalize -- does.   So I set that to "1" and resysprepped.    That made no difference -- System Restore was still turned off after I sysprepped (it was turned on prior to running sysprep...)

    My workaround for adding the wmic command above seems to be sticking, so I'll work with that going forward.

    Friday, September 28, 2012 2:04 PM