Jump to content

Need Help With Creating Bootable Windows 7 x64 PE RAM Disk


barnold

Recommended Posts

Hi,

Gonna give you the quick bottom line but please do read on for more detail.

I need to standardize a method to capture/apply Windows 7 x64 images for my company.

I imaged a box with Windows 7 x64 and need to to run D:\Windows\System32bcdboot.exe D:\Windows to setup the boot environment (before rebooting into the OS). This needs to be done in a 64 bit Window PE environment (I think) because the OS is x64. I need help creating a Windows PE disk that will run in an x64 environment

Can anyone help me do this? Please read on and I apologize ahead of time for the babble

This is a long story but please bear with me cause I need help!!

I’ve been using Barts disks to upload/deploy .wim images of XP and Vista systems to/from network shares for quite a while now. Now I need to do the same with Windows 7. The first obstacle I noticed with Windows 7 is that it created the 200mb system partition. I didn’t know if it was necessary to the OS (still don’t understand really) or if I had to image it in addition to the primary partition, and then restore them both? I found lots of info about how to get rid of this partition but nothing about how to image it…until I found this guide: (http://blog.rileytech.net/post/2009/08/14/End-to-End-wim-image-creation-with-Windows-7-and-Windows-AIK.aspx) ! What a relief I thought. The author explains that you need to use DiskPart to recreate the additional file structure for the OS to load correctly.

Here’s an exerpt from the author:

There's an additional partition Win7 installs in front of the OS.

So you must re-create this file structure for the OS to load correctly.

Diskpart

list disk (get the drive number) (Note: This is available in the Win7 WAIK)

select disk #

clean

create partition primary size=200

select partition 1

format fs=ntfs quick label="system"

assign letter=c

active

create partition primary

select partition 2

format fs=ntfs label="Windows" quick

assign letter=d (if this fails, give it any drive letter)

exit

For Windows 7, I always restart after setting the partitions because the drive letters may not line up but when you restart, they do. Vista/2k3 there's no need to. Ok, now ... to image our desktop! Remember, for windows 7 we image to D, all others, C (in this example, I'm still imaging a windows 7 box)

imagex /apply z:\Dev_Win7_x86.wim 1 d:

The image is now flowing down to your desktop.

For Windows 7, before you're done, navigate into D:\Windows\System32 and run bcdboot.exe D:\Windows. This will tell the bootloader "hey, go here and run this". Otherwise you'll get a the nasty error message I mentioned in the previous post.

OK, it’s me again. So, my problem is with the bcdboot.exe command. After I imaged captured the .wim image to a network share and then reapplied it to the d: drive I ran the bcdboot command as the author instructed:

D:\Windows\System32 and run bcdboot.exe D:\Windows

Then I get an error something like this: “This command cannot be run in a win32 environment”

Ok, that is understandable. I am running this within Barts and I should be running it within a Microsoft PE environment as the author said. He recommends that I create a bootable PE USB Ram Disk as explained here: http://technet.microsoft.com/en-us/library...530(WS.10).aspx but I got a USB boot error so I decided to make a bootable PE Ram Disk on CD instead.

This article is in the WAIK and explains how to do it:: http://technet.microsoft.com/en-us/library...303(WS.10).aspx and I was able to make the X86 architecture disk boot fine but when I ran D:\Windows\System32\bcdboot.exe D:\Windows it threw this error:

This version of g:\windows\system32\bcdboot.exe is not compatible with the version of Windows you're running. Check your computer's system information to see whether you need a x86 (32-bit) or x64 (64-bit) version of the program, and then contact the software publisher.

OK. This makes sense because the OS is Windows 7 x64. So, I’ll make an x64 architecture PE Ram Disk on CD using the same article as above.

To make the PE .iso you have to run the OSCDIMG command.

For the x86 disk it is: oscdimg -n -bC:\winpe_x86\etfsboot.com C:\winpe_x86\ISO C:\winpe_x86\winpe_x86.iso THIS WORKS

For the x64 disk it is oscdimg -n -bC:\winpe_x64\etfsboot.com C:\winpe_x64\ISO C:\winpe_x64\winpe_x64.iso

THIS DID NOT WORK.

ERROR: Could not open boot sector file "C:\winpe_x64\etfsboot.com"

Error 2: The system cannot find the file specified.

For some reason the etfsboot.com file is not included in the ia64 architecture of the PE Tools of the WIN7 WAIK. (It is in the ia86 architecture)

Should be here: C:\Program Files\Windows AIK\Tools\PETools\ia64\boot\etfsboot.com

So I guess I need help creating a bootable Window PE RAM CD that will support Windows 7 x64.

Also If anyone has any general advice or recommended methods for imaging Windows 7 boxes (specifically x64 - this is what my company is deploying) I would love some guidance.

Thanks so much!

brian

Link to comment
Share on other sites


Hi Brian,

Not sure where to start. The 32-bit edition of WinPE can only run 32-bit applications and the the 64-bit one only 64-bit ones. Every usage, that differs is not supported and results in the error message you mentioned. BCDEdit is used to modify the boot settings, which are not dependant on 32 or 64-bit, so it doesn't matter, if you edit the settings of a 64-bit Windows with the 32-bit edition of BCDEdit. This applies also to OSCDIMG. From my point of view, it would be the easiest to only use the 32-bit editions of the tools and stick with either WinPE 32 bit.

If you really need the 64-bit edition you should be able to build the WinPE from the WAIK. The image for AMD64 is included in the packet. In this case the build instructions are basically the same. Just keep 64-bit in mind and include the 64-bit edition of the mentioned tools (BCDEdit, OSCDIMG) to the image. The included documentation should help you.

For some reason the etfsboot.com file is not included in the ia64 architecture of the PE Tools of the WIN7 WAIK. (It is in the ia86 architecture)

Should be here: C:\Program Files\Windows AIK\Tools\PETools\ia64\boot\etfsboot.com

Do not mix IA64 which is used for Intel Itanium (I don't think, there is a Windows 7 edition for that) and AMD64, which is the common one for current Intel Core and AMD processors. IA64 does use EFI, that is why the CD boot loader is not included here, look at the AMD64 folder.

Link to comment
Share on other sites

OK

Thanks for the reply. I'll try to create a new disk with the AMD64 architechture (The "AMD" nomenclature fooled me - I assumed it was for AMD processors).

I'll let you know how that goes.

Since I know I have a reader :-) - now that you have a basic idea of how I am trying to deploy this Win7 x64 image, does it sound correct to you? Is this how you would deploy a Window 7 image or can you recommend a different method?

Other readers - please chime in too!

Thanks!

Link to comment
Share on other sites

I'm not an expert in deploying technologies, but rather interested in what WinPE can help me with. If you use that howto for a 32-bit deployment, it should also work for a WIM containing a 64-bit installation. My guess is, that you should be able to use the 32-bit WinPE and eventually substitute some commands. If BCDBoot (sorry, misread that tools name before) can't be used, use 32-bit BCDEdit and generate a new entry for the 64-bit installation on drive D:. Another way might be to start d:\windows\syswow32\BCDBoot.exe.

Link to comment
Share on other sites

Just wanted to let you know that the AMD64 disk worked perfectly! I was able to boot and run the BCEdit command successfully :-)

My image unfortunately did not load perfectly, but I will save that issue for another thread.

Thanks again!

brian

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...