Solved

Sysprep and OEMReset_Switch registry entry ?

Posted on 2007-11-19
7
1,669 Views
Last Modified: 2010-04-21
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
Comment
Question by:Vorenus
  • 3
  • 2
  • 2
7 Comments
 
LVL 32

Accepted Solution

by:
and235100 earned 250 total points
Comment Utility
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
 
LVL 4

Author Comment

by:Vorenus
Comment Utility
Hi,

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

Thanks,
0
 
LVL 29

Expert Comment

by:matrixnz
Comment Utility
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
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 4

Author Comment

by:Vorenus
Comment Utility
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
 
LVL 29

Assisted Solution

by:matrixnz
matrixnz earned 250 total points
Comment Utility
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
 
LVL 4

Author Closing Comment

by:Vorenus
Comment Utility
Thanks.
0
 
LVL 32

Expert Comment

by:and235100
Comment Utility
Hope you got your problem sorted. Thanks!
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Recently Microsoft released a brand new function called CONCAT. It's supposed to replace its predecessor CONCATENATE. But how does it work? And what's new? In this article, we take a closer look at all of this - we even included an exercise file for…
A Bare Metal Image backup allows for the restore of an entire system to a similar or dissimilar hardware. They are highly useful for migrations and disaster recovery. Bare Metal Image backups support Full and Incremental backups. Differential backup…
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now