Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1724
  • Last Modified:

Sysprep and OEMReset_Switch registry entry ?

Hi,

I'm currently working with sysprep for a WinXP SP2 image.
For some reasons, I need to script the sysprep reseal execution through command-line.
However, the default behavior is that it reboots after the reseal is completed, which I do not want since I have a couple of minor things to do after that.

So, I have seen that sysprep provides the noreboot command-line switch.

However, I found the documentation to be a bit confusing and alarming.

-noreboot - Modifies registry entries (SID, OemDuplicatorString, and other registry entries) without the computer restarting or preparing for duplication. This parameter is mainly used for testing, specifically to see if the registry is modified correctly. Microsoft does not recommend this option because making changes to a computer after the Sysprep.exe file has run may invalidate the preparation that was completed by the Sysprep.exe file. Do not use this parameter in a production environment.

So, I wanted to make sure that the GUI (from the GUI, you can choose to simply close sysprep after the reseal) and command-line version were doing the same.

So I made a snapshot on my virtual machine and resealed using both the command-line version and GUI version (everytime recovering from my snapshot of course to not reseal twice) and exported the whole registry to a reg file and made comparisons using WinMerge (a diffing utility).

It was 99% the same, however I noticed an entry named OEMReset_Switch with a blank value under "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion".

I googled for this entry but it couldn't find anything on it. I'm not sure what it does and if it is important for my sysprep deployment ?
Since MS said in their docs to not use the -noreboot switch, I prefer to make sure that this entry is not important.

Does anyone know what is its meaning ?

Thanks in advance.
0
Vorenus
Asked:
Vorenus
  • 3
  • 2
  • 2
2 Solutions
 
and235100Commented:
http://www.castlecops.com/s2582-OEMCLEANUP_or_OEMRESET.html

This is an entry that upon a reboot will restore OEM settings - i.e. the entry is put in by sysprep simply because your haven't rebooted.

A reboot is required to ensure the consistency of the sysprep image.
0
 
VorenusAuthor Commented:
Hi,

I'm not sure, I have neither of these executables on my master machine...

Thanks,
0
 
matrixnzCommented:
Hi Vorenus

"However, the default behavior is that it reboots after the reseal is completed, which I do not want since I have a couple of minor things to do after that."

Can you expand on this?  Normally with Sysprep you shouldn't make any changes once you've set it motion, if you do need to make changes then it's best if you script this during the mini install, i.e. these can be added to the $OEM$ within the %SystemDrive%\SysPrep\i386 Directory by using cmdlines.txt for System Account installations or
[GuiRunOnce]

Normally use the following switches with Sysprep, which will shutdown the machine allowing reimaging:
C:\Sysprep\Sysprep.exe -RESEAL -MINI -PNP -QUIET

After restoring on a new computer Sysprep Mini Setup starts, installing registry keys, misc software, etc..

Hope that helps.

Cheers
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
VorenusAuthor Commented:
Hi Matrix,

Thanks for your answer.
I'm just restoring a registry key that gets removed by SysPrep on my Administrator account :

[HKEY_CURRENT_USER\Software\Microsoft\Active Setup\Installed Components\{89820200-ECBD-11cf-8B85-00AA005B4383}]
"Version"="7,0,5730,13"
"Locale"="en"

It makes the IE4Uinit executable launched by the "Active Setup" feature of Windows to mess with some Explorer.exe settings of my Administrator accounts : for example, I get big toolbars while I had setup small ones.
It doesn't happen for my newly created users however, but I don't want these settings on my Administrator account to be changed.
By the way, I wrote my Sysprep.inf file so that my Administrator profile doesn't get copied to the Default one on reseal (I already apply my registry changes to the default users profile through scripts that load the Default user hive and merge reg files onto it) and my Administrator accounts gets different customizations than the default users will get :

 ; A value of 1 means that the Administrator profile will be copied to the Default User
; profile on reseal (requires KB887816)
UpdateServerProfileDirectory=0

I can not run restore this Active Setup entry on the $OEM$ phase of sysprep since my Administrator account isn't loaded at that time.

But well, that's not really what worries me anyway since I managed to get all of this to work fine : I'm curious about what the OEMReset_Switch registry entry is for and how related to sysprep it may be.

Thanks.
0
 
matrixnzCommented:
Hi Vorenus

As and235100 pointed out OEMReset, resets OEM installation settings at bootup, I believe the files are part of the Microsoft System Builder Kit which certified OEM Builders use in the factory to build there systems.  The key should have no effect on your build.

With regards to the $OEM$ phase, I use something like:
REG LOAD HKU\Administrator "C:\Documents and Settings\Administrator\NTUser.dat"
Then in my registry files I use something like:
[HKEY_USERS\Administrator\Software\Microsoft\Active Setup\Installed Components\{89820200-ECBD-11cf-8B85-00AA005B4383}]
"Version"="7,0,5730,13"
"Locale"="en"
Then unload the hive:
REG UNLOAD HKU\Administrator

Cheers
0
 
VorenusAuthor Commented:
Thanks.
0
 
and235100Commented:
Hope you got your problem sorted. Thanks!
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 3
  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now