Solved

Sysprep Vista ~ How to delete sysprep.xml file upon sysprep completion

Posted on 2007-04-09
6
1,324 Views
Last Modified: 2008-01-09
I am working to setup a Vista VPC template.  I need the template to AutoJoin the domain (still trying to get this to work).  The sysprep setting responsible for doing this requires that credentials with the proper rights be added to the sysprep xml file.  This was fine in the old version because once sysprep completed the file was deleted so i never had to worry about users finding the file and discovering the account with elevated rights.  But in Vista the file is not deleted and these credetials exist in clear text.  Anyone know of a way around this?
Thanks
0
Comment
Question by:mentok74
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 22

Expert Comment

by:Adam Leinss
ID: 18877572
How about kicking off a script in HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce that deletes the sysprep file?
0
 

Author Comment

by:mentok74
ID: 18878154
Sounds like that would meet my needs but i don't know much about scripting, what would something like that look like?  Any suggested resources for researching such a solution?  Thanks for the reply.
0
 
LVL 22

Expert Comment

by:Adam Leinss
ID: 18878337
Sure...just put the following in a file:
---------------------------------------
del C:\windows\sysprep\* /q
---------------------------------------
Save the file as cleanup.cmd.  Make you have a copy of the sysprep files before you run this command.  Go into regedit and drill to the location given above.  If you had the script say in C:\temp, you would make a new key (name can be anything) and make a new string value of "C:\temp\cleanup.cmd"  Now sysprep the machine.  On the very first login, it should delete the sysprep files and should only run once.  

Let me know if that works for you.
0
Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

 
LVL 22

Accepted Solution

by:
Adam Leinss earned 500 total points
ID: 18878345
Sorry, I thought I editted that, it should be "del C:\windows\SYSTEM32\sysprep* /q"
0
 

Author Comment

by:mentok74
ID: 18909028
Hey Aleinss,
I finally got around to trying your solution and it worked!!!  I have little to no experience with scripts so i really appreciate you taking the time to outline it for me.  A million thanks!!!
0
 
LVL 22

Expert Comment

by:Adam Leinss
ID: 18909049
No problem.  From my reading, it appears that Microsoft assumes you will be using KMS for activation, therefore the product key security is less of an issue and thus they do not delete the sysprep directory/file anymore.  In your case, it's the credentials embedded within the sysprep file which is also a security concern.
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

So who is this article for? If you are like most of the computer users out there, you probably only realize the meaning of 'System maintenance' after something goes wrong. This article is for you if you care about keeping your system working opti…
When you try to extract and to view the contents of a Microsoft Update Standalone Package (MSU) for Windows Vista, you cannot extract the files from the MSU. Here we are going to explain how to extract those hotfix details without using any third pa…
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

617 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