staples Posted July 11, 2006 Share Posted July 11, 2006 I have been working on a batch file to build Win PE 2.0 but I have not been able to build the ISO. The concept from a blog. Here is my batch file::: for use with BDD 2007 v3.0.41.0::------Clean up.rd /q /s winpe_x86::------Initial PE buildc:cd "c:\program files\windows aik\tools\petools"call copype.cmd x86 c:\winpe_x86 ::------Add additional file to D: in PE (not on the RAM) :: NOTE: These files show up on the “D:” drive after booting into WinPE.:: The reason for putting additional tools here is to reduce the memory footprint of :: WinPE. Everything in the X: drive is loaded into RAM at boot time!::xcopy *.* c:\winpe_x86\iso /s/e/v/yxcopy "C:\program files\Windows AIK\Tools\x86\*.*" c:\winpe_x86\iso /s/e/v/y::------Customize PE::Mount the WinPE WIM file:imagex /apply c:\winpe_x86\winpe.wim 1 c:\winpe_x86\mount ::Install drivers ::peimg /inf=c:\drivers\vmware\vmxnet\win2k\vmware-nic.inf c:\winpe_x86\mount\Windows C:\winpe_x86_2>peimg /inf=c:\drivers\vmware\vmxnet\win2k\vmxnet.inf c:\winpe_x86\mount\Windows ::Install optional components peimg /install=*srt* c:\winpe_x86\mount\windows::shows currently installed optional packages peimg /list c:\winpe_x86\mount\windows::If you want ImageX (or any other utilities) in the RAM disk, put them there now:xcopy "C:\program files\Windows AIK\Tools\x86\*.*" c:\winpe_x86\mount\windows\system32\*.* /s/e/v/y::Prep the PE image peimg /prep c:\winpe_x86\mount\Windows /f::capture the mounted PE instace to a WIMimagex /append c:\winpe_x86\mount c:\winpe_x86\winpe.wim "MyWinPE" /verify::Export the appended image to a bootable WIM file:imagex /boot /export /compress max c:\winpe_x86\winpe.wim 2 c:\winpe_x86\ISO\sources\boot.wim ::Create the Isooscdimg -n –bc:\winpe_x86\etfsboot.com c:\winpe_x86\ISO c:\winpe_x86\winpe_x86.isoIt seems to be failing at the line imagex /boot /export /compress max c:\winpe_x86\winpe.wim 2 c:\winpe_x86\ISO\sources\boot.wimAny help is appreciated. Link to comment Share on other sites More sharing options...
Pyrosoft Posted July 12, 2006 Share Posted July 12, 2006 You applied winpe.wim image 1, and you are compressing winpe.wim image 2.Could this be the problem? Link to comment Share on other sites More sharing options...
fizban2 Posted July 12, 2006 Share Posted July 12, 2006 what is the error that you get when it hits that line? Link to comment Share on other sites More sharing options...
staples Posted July 12, 2006 Author Share Posted July 12, 2006 The error I recieve is "Error 5: Access is denied" from the oscdimg command. This is the output from line (it does not really give a error message but it completes in a split second.... and I think it causes the next line in the batch script to fail). imagex /boot /export /compress max c:\winpe_x86\winpe.wim 2 c:\winpe_x86\ISO\sources\boot.wim "MyWinPE"C:\winpe_x86>imagex /boot /export /compress max c:\winpe_x86\winpe.wim 2 c:\winpe_x86\ISO\sources\boot.wim "MyWinPE"ImageX Tool for WindowsCopyright (C) Microsoft Corp. 1981-2005. All rights reserved.Exporting: [c:\winpe_x86\winpe.wim, 2] -> [c:\winpe_x86\ISO\sources\boot.wim]Progress: 100%Successfully exported image #2.The next line that actually returns a error is:oscdimg -n –bc:\winpe_x86\etfsboot.com c:\winpe_x86\ISO c:\winpe_x86\winpe_x86.isoC:\winpe_x86>oscdimg -n -bc:\winpe_x86\etfsboot.com c:\winpe_x86\ISO c:\winpe_x86\winpe_x86.isoOSCDIMG 2.45 CD-ROM and DVD-ROM Premastering UtilityCopyright (C) Microsoft, 1993-2000. All rights reserved.For Microsoft internal use only.ERROR: Could not delete existing file "c:\winpe_x86\ISO"Error 5: Access is denied. Link to comment Share on other sites More sharing options...
fizban2 Posted July 12, 2006 Share Posted July 12, 2006 i know this will sound stupid but rewrite you command line for OSCDIMG, i had the same error cause i copied in parts of the command line (paths etc) and i got the same error, by typing everything in by hand it worked. don't know why but it did, give it a shot Link to comment Share on other sites More sharing options...
staples Posted July 12, 2006 Author Share Posted July 12, 2006 well that worked, typing it in manually worked... why I don't know ... but now it is working. Thanks fizban2 Link to comment Share on other sites More sharing options...
wrecklesswun Posted July 13, 2006 Share Posted July 13, 2006 possibly because of the vbcrlf in c:\winpe_x86\winpe_x86.iso... Link to comment Share on other sites More sharing options...
davidgoe Posted October 25, 2006 Share Posted October 25, 2006 possibly because of the vbcrlf in c:\winpe_x86\winpe_x86.iso...Actually the problem is that in the command in the document “Getting_Started_ITPro.rtf”, under “To create bootable Windows PE media”, step 5:oscdimg -n –bc:\winpe_x86\etfsboot.com c:\winpe_x86\ISO c:\winpe_x86\winpe_x86.isothe dash before ‘bc’ is not a normal dash (0x2D ansi), but is in fact an ‘En-Dash’ (0X96 ansi, 0x0x2013 unicode). As one might expect, when this is cut and pasted in a command window it looks perfect but oscdimg.exe does not grok it and gives forth:ERROR: Could not delete existing file "c:\winpe_x86\ISO"Error 5: Access is denied.Which is, to say the least, not very helpful... Link to comment Share on other sites More sharing options...
aend Posted August 7, 2009 Share Posted August 7, 2009 Thanks for that Solution. I was doubtful of myself, because i checked again and again.. Thanks Link to comment Share on other sites More sharing options...
rdrussell Posted May 4, 2011 Share Posted May 4, 2011 (edited) I am running Windows 7 enterprise in Oracle VirtualBox . I am logged in as administrator. I have started the Application Manager service. I run the Deployment Kit command line as Administrator. I have adjusted the cmd console so I get the correct -. I am typing the command not pasting. I still get the "Error 5: Access Denied" message. Any other tips on what to do would be much appriciated.The command I was using: oscdimg.exe -n -bc: \winpe\etfsboot.com c: \winpe\ISO c: \winpe\winpe.isoI removed the "-b" files began copying. Then I got a message that read file to large... I then added a "-o" at the end to optimize and compress and this seemed to work.Hope this helps someone else! Woops. Still got the file too large message. Modified the "-o" to "-m" to override the file too large error. Now it really worked, YOOHOO!!! B)OK. None of that worked. But want did work was using the MDT 2010 Update 1. Once I installed that everything worked great. BTW, I don't know who moved my post, but the problem was with Win PE 3.0 not 2.0. Edited May 9, 2011 by rdrussell Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now