Jump to content











Photo
- - - - -

booting vista/2008/w7 from usb sub folder


  • Please log in to reply
175 replies to this topic

#101 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 19 August 2010 - 04:44 PM

Link doesn't work very well???? Can you point me at the relevant post please? I thought about adding a default timeout to menu.lst to boot from (hd0,0), but I don't know which HDD partition is active..

#102 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 19 August 2010 - 04:57 PM

Link doesn't work very well???? Can you point me at the relevant post please? I thought about adding a default timeout to menu.lst to boot from (hd0,0), but I don't know which HDD partition is active..


The thread is this one:
http://www.msfn.org/...ll-xp-from-usb/

But the actual explanation/early tests are in the "historical" thread:
http://www.msfn.org/...l-from-usb-key/
(you'lll have to find it, it's somewhere in there, but if I remember correctly, the solution was specific to 2K/XP/2003 setup and involved BOOT.INI mods)

So, I don't think you can use it "as-is", but the general idea is:
  • leave BIOS booting order the default (USB, internal HD, etc.)
  • boot from USB, remap drives as if the boot disk was the internal hard disk
  • boot first time from the install on USB
  • boot second time from the internal hard disk

You exchange drive in grub4dos:

map (hd0) (hd1)
map (hd1) (hdo)
map --hook


Then, on first instance you chainload the whatever is on the USB stick, and on next instance you chainload the internal hard disk MBR (you need NOT to know which partition is active if you chainload the MBR).

"triggering" between "first instance" and "second" instance can be done in several ways, using the "default" provisions of grub4dos, by checking a "tag file", etc., but it can surely be done.

I am not at all familiar with Vista :( and 7 install, nor with the methods you have developed till now, so I cannot be more exact in suggesting you a possible solution.

:)
Wonko

#103 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 20 August 2010 - 11:20 PM

@sushil1576 - you could try adding this to front of your menu.lst - after 5 seconds it will default to booting from your hard disk - so you can leave the USB drive in even is USB is first boot device ????



color black/cyan yellow/cyan
timeout 5
default 0

title Boot to system Hard Disk
map (hd0) (hd1)
map (hd1) (hd0)
map --hook
chainloader (hd0)+1
rootnoverify (hd0)

title Reboot
reboot

title Switch Off
halt

#104 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 21 August 2010 - 10:03 AM

Hi

Just tried this using a USB HDD and Server 2008 32-bit. I set the boot order to HDD first and USB HDD 2nd. Then used F10 to select USB HDD from the boot menu to start it all off. I also had an OEM folder set up on the USB drive folder structure.

It all worked perfectly! I left the USB HDD connected the whole time - no lockups, just went ahead on reboot and booted from HDD into server 2K8. OEM folder worked too!

Good to know that it works on real hardware.well the only reason now i think why i had to remove USB drive is that i was doing all the tests in vmware and i was booting the usb with the help of 'PLOP BOOT CD'..so may be thats the reason but still can't understand why it worked after removing the usb drive...As you can see my virtual HDD was the first boot device in the vmware..so i don't think by using that grub menu will help..maybe on real machine i won't get that problem..but right now i don't have a spare hard disk for testing.

#105 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 22 August 2010 - 10:54 AM

latest Beta now 2.1.5 :)

#106 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 23 August 2010 - 07:34 PM

HI,
Finally i did install Server 2008 64bit on a REAl Hard drive,and everything went on smoothly...So i guess the problem during installation was because of Virtual installation or may be because i was using PLOP Boot CD..And yes even the OEM works perfectly...

Now i have got one more enhancement for this method,..To make this method fully unattended,we can use the "/unattend:answer_file" switch as well..So once we make our "unattended.xml" we can simply put that in the sub folder and the install will become fully unattended install.. ;)..So our new "mysetup.cmd" will look like this..

@echo off

SET DD=W732

for %%I in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %%I:\%DD%\install.wim set DVDdrive=%%I:

If NOT "%DVDDrive%"=="" echo Found Install.wim at %DVDdrive%\%DD%\install.wim

IF "%DVDdrive%"=="" (

echo ERROR - COULD NOT FIND INSTALL.WIM in %DD% folder!

pause

pause

goto :EOF

)





REM look for whole sources folder copied over

If exist %DVDdrive%\%DD%\setup.exe  (

%DVDdrive%

REM setup will use its path to find the install.wim

%DVDdrive%\%DD%\setup.exe /m:%DVDdrive%\%DD%\OEM /unattend:%DVDdrive%\%DD%\unattended.xml

goto :RBT

)



if not exist X:\Setup.exe goto :BAD

REM if not then just call setup in root of boot.wim

X:\setup.exe /installfrom:%DVDdrive%\%DD%\install.wim /m:%DVDdrive%\%DD%\OEM /unattend:%DVDdrive%\%DD%\unattended.xml

goto :RBT





:BAD

dir X:\ /b

echo Cannot find X:\Setup.exe !

@echo Press a key to reboot now...

pause



:RBT

wpeutil reboot

pause


#107 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 23 August 2010 - 07:52 PM

Does it not work without the switch if you use the \svr2k864 folder to store your unattend.xml ???

#108 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 27 August 2010 - 12:24 PM

Does it not work without the switch if you use the \svr2k864 folder to store your unattend.xml ???

Hi
Sorry for a little late reply,..I tried to install without "/unattend:%DVDdrive%\%DD%\unattend.xml" but the setup just couldn't use it..So i guess we have to use this switch if we want unattended install..And i also found that we have to use a dummy "OEM" folder even if don't want to use "OEM" option for the install...If we use the "/m:%DVDdrive%\%DD%\OEM" as the windows 7 setup did complain about the missing OEM folder..Even though it doesn't matter once the "completing installation" stage starts...

#109 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 27 August 2010 - 03:21 PM

Hi
Sorry for a little late reply,..I tried to install without "/unattend:%DVDdrive%\%DD%\unattend.xml" but the setup just couldn't use it..So i guess we have to use this switch if we want unattended install..And i also found that we have to use a dummy "OEM" folder even if don't want to use switch "OEM" option for the install if we use the "/m:%DVDdrive%\%DD%\OEM" as the windows 7 setup did complain about the missing OEM folder..Even though it doesn't matter once the "completing installation" stage starts...

Thanks, I have updated the download with these mods. Thanks for all your help, I hope others will benefit from this now. :)

#110 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 27 August 2010 - 05:31 PM

Thanks, I have updated the download with these mods. Thanks for all your help, I hope others will benefit from this now. :)

Well i have not tested,but the setup will also ask for "unattended.xml" file in the sub folder if we put "/unattend:" switch in "mysetup.cmd"..so i think it would be better to provide two versions of the download..One with "/unattend:" switch and another one without that switch as most normal users would not like to use "/unattend:" switch..Its just a suggestion... :) ..But thanks to you,this is now just proving to be an "AIO Windows Install"..Not easy but once sorted out,its just too good and very easy to install.. :)

EDIT: I found that the unattend.xml file is named differently in "mysetup.cmd" from "Multiwin7.zip"...the filename of the unattend.xml suggested in the tutorial must match that with that of the unattend.xml filename in the "mysetup.cmd"..

#111 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 27 August 2010 - 06:33 PM

how about this??
if exist %DVDdrive%\%DD%\unattend.xml SET UN=/unattend:%DVDdrive%\%DD%\unattend.xml

if exist %DVDdrive%\%DD%\OEM\nul SET OEM=/m:%DVDdrive%\%DD%\OEM



REM look for whole sources folder copied over

If exist %DVDdrive%\%DD%\setup.exe  (

%DVDdrive%

REM setup will use its path to find the install.wim

%DVDdrive%\%DD%\setup.exe %OEM% %UN%



goto :RBT

)



if not exist X:\Setup.exe goto :BAD

REM if not then just call setup in root of boot.wim

X:\setup.exe /installfrom:%DVDdrive%\%DD%\install.wim  %OEM% %UN%

goto :RBT





:BAD

dir X:\ /b

echo Cannot find X:\Setup.exe !

@echo Press a key to reboot now...

pause



:RBT

wpeutil reboot

pause


#112 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 27 August 2010 - 06:59 PM

how about this??

if exist %DVDdrive%\%DD%\unattend.xml SET UN=/unattend:%DVDdrive%\%DD%\unattend.xml

if exist %DVDdrive%\%DD%\OEM\nul SET OEM=/m:%DVDdrive%\%DD%\OEM



REM look for whole sources folder copied over

If exist %DVDdrive%\%DD%\setup.exe  (

%DVDdrive%

REM setup will use its path to find the install.wim

%DVDdrive%\%DD%\setup.exe %OEM% %UN%



goto :RBT

)



if not exist X:\Setup.exe goto :BAD

REM if not then just call setup in root of boot.wim

X:\setup.exe /installfrom:%DVDdrive%\%DD%\install.wim  %OEM% %UN%

goto :RBT





:BAD

dir X:\ /b

echo Cannot find X:\Setup.exe !

@echo Press a key to reboot now...

pause



:RBT

wpeutil reboot

pause


This code looks much better..In fact i think this is the best solution..Again,let me first test this before jumping into conclusion..but i am sure this is good. :) ..

EDIT : WORKED PERFECTLY....Both OEM and unattended.xml were executed...Thanks once again...So now we have got everything that we were expecting... :)

#113 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 27 August 2010 - 07:41 PM

:)

#114 Technotika

Technotika

    Frequent Member

  • Advanced user
  • 419 posts
  • Location:United Kingdom
  •  
    United Kingdom

Posted 04 September 2010 - 09:34 AM

Hi, I'm taking some steps to try and follow this guide from the RMPREP site but have hit some kind of problem I need some help with, If I may. :D

At this point....

Now locate ChangeBCD.cmd in the \MYUSB folder and double-click on it (if Vista\Win7 right-click and Run as Administrator). You will be asked for a BCD number.
Type 1 (if you have a bc1) - it should modify the existing bc1 file so that it looks for boot1.wim instead of boot.wim.


Repeat this for all bcx files that you have added.



....I saw the CMD window report an error.

I switched echo on & added a pause @ the end to see the output for some sign of a problem I made. Here it is......


C:\Windows\system32>echo C:\Windows\system32

C:\Windows\system32



C:\Windows\system32>pushd C:\Windows\system32



C:\Windows\system32>dir /b boot\bc*.

File Not Found



C:\Windows\system32>echo.





C:\Windows\system32>Echo Change BCD store to load \sources\bootX.wim

Change BCD store to load \sources\bootX.wim



C:\Windows\system32>SET /P NN=Enter BCD number :

Enter BCD number : 1



C:\Windows\system32>if not exist boot\bc1 goto :NOFILE



C:\Windows\system32>echo ERROR - cannot find  boot\bc1

ERROR - cannot find  boot\bc1



C:\Windows\system32>pause

Press any key to continue . . .

I am only running tests for 7 32/64 this time round and have installed everything carefully. In my C:\MYUSB\boot I have 2 renamed files bc1 & bc2.

At this point....

C:\Windows\system32>dir /b boot\bc*.

File Not Found


The contents are
en-US
winload.efi
winload.exe
winresume.efi
winresume.exe

My PC is 7-64 if also that might affect this.

Hopefully this gives you guys enough info to see what I did wrong, thanks :D


NB, also with this method can you make it so you can select which version to install like Home Premium /Ultimate /Professional etc.

#115 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 September 2010 - 09:44 AM

Hi
Sorry, the instructions are wrong! I log in as admin and so it works for me, but not if you right-click and run as admin.

So, run cmd as admin to get a command shell window, then change to your \myusb folder

e.g.

CD C:\MYUSB

then run changebcd by typing

CHANGEBCD

it should then be OK

I will change the instructions.

If you delete the ei.cfg file (if present), you should be given a choice of which edition to install.

Thanks
Steve

#116 Technotika

Technotika

    Frequent Member

  • Advanced user
  • 419 posts
  • Location:United Kingdom
  •  
    United Kingdom

Posted 04 September 2010 - 10:14 AM

arh cool no probs - I'll let you know how I get on - awsome! :D

#117 Technotika

Technotika

    Frequent Member

  • Advanced user
  • 419 posts
  • Location:United Kingdom
  •  
    United Kingdom

Posted 04 September 2010 - 04:22 PM

edit started replying and realised half way through I am bouncing off 2 threads, sticking with this one!


ranas admin, removed files, if prepare is doing the same job is nothing to worry about hey...

Just tested the multi installer disk I now have...works like a
charm, so pleased I can have them all in sub folders. You clever chaps pull out all the stops! Hot dammit! :D Thanks so much.

One thing I'd like to is now add the files to another USB stick.
However the other USB stick has a system build on there which uses a BOOTMGR on its root and some other folders too.

Can I use some of the processes I used today to let them all exist on the same stick together.....

I did think I could just copy them all over but the bootmgr's are different size and date and also boot.sdi, otherwise bc1,2,3,4 etc could have just missed any clashing nicely!

Here is a shot of the stick I want to add my subfolder winstaller package to ....FOLDERS


All that stuff does as far as I know is lay down some base files then we put in some server details and it builds the client machine its booted across network.

#118 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 04 September 2010 - 05:22 PM

Hi Steve,
I was wondering whether we can use windows 7 setup to install a sysprepped windows xp image... I know another very talented member of this forum thunn has already done this with his Panther XP project..and it was just awesome...But it is little outdated and moreover,we can't use it for installing from usb without modifying it...what i have done so far is as follows:..

1. I have created a sysprepped universal Windows xp install.wim which is already tested and works very well so far..
2. Now i tried to use this method to install that image using windows 7 32 bit boot image,but as it couldn't find the SKU version it just stopped there,even though it did find the install.wim...Now my question is ,"Is there any "Edition ID" for Windows XP which we can use with imagex "/flag" switch?..and if there is such a edition id,then please point me in the right direction..

The main advantage i can see with this method of installing Xp is that we can use have multiple versions of XP in just one install.wim and this method also installs xp much faster and just like what we want...I know we can use imagex and then apply the xp image directly on the system..But I am just trying to learn new ways of installing XP..

#119 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 04 September 2010 - 07:18 PM

There is no flag for XP, but you could just lie and set a flag for say Win 7 Pro. However, the PBR applied would be one that would boot to 'bootmgr' and not NTLDR (even if it would extract the image) and so it probably wouldn't boot (unless maybe you copied the file \ntldr to make a new \bootmgr file inside the image??).

#120 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 04 September 2010 - 07:24 PM

There is no flag for XP, but you could just lie and set a flag for say Win 7 Pro. However, the PBR applied would be one that would boot to 'bootmgr' and not NTLDR (even if it would extract the image) and so it probably wouldn't boot (unless maybe you copied the file \ntldr to make a new \bootmgr file inside the image??).

Ok i will try with an windows 7 flag,and as far as PBR is concerned ,we can take care of that by using the bootsect command and just apply the /nt52 ...And ntldr is already there in the image so thats not going to be a problem as far as i can see

#121 sushil1576

sushil1576

    Member

  • Members
  • 48 posts
  •  
    India

Posted 10 September 2010 - 05:58 PM

Ok, I tried using Windows 7 flag for using Windows XP install.wim in a windows setup,but it just did not accept...may be i am not doing it in a proper way..So i guess i should stick with the easy route of directly applying the Xp install.wim..For ease of use i just inserted "Gimagex.exe" into the sytem32 folder in the boot.wim image of the Windows PE.. :hyper: ..

#122 anybastard

anybastard
  • Members
  • 7 posts

Posted 18 October 2010 - 06:27 AM

Hi Guys,

I'm following these step by step instructions....

http://sites.google....and-server-2008


...to make a multiboot usbkey , but i have a little problem with W7 ( x86 and x64 ) installation.

The setup startup before hdd partition gui i have an " error message"

Load Driver : A required cd/dvd driver device is missing .....

Could you help me to solve this question ??

Thank a lot

AnyB

#123 anybastard

anybastard
  • Members
  • 7 posts

Posted 20 October 2010 - 09:45 AM

Hi Guys ,

sorry for my mistake , i had not read previous post about this problem .

Now all work fine !!!

Best Regards
AnyB

#124 kpdozer

kpdozer

    Newbie

  • Members
  • 11 posts

Posted 22 October 2010 - 07:23 AM

Good afternoon I ask the help of experts.

Has decided to create a boot drive with several LiveCD based on Winpe3.0.
I can boot with different boot.wim through grub4dos (boot1.wim, boot2.wim...) without problems.
To spare a place on CD (DVD) I would like to boot since various images in one WIM.

For experiment I have merged 2 boot.wim in one.
I have received boot.wim with two images in
At first I have marked the first image as boot (boot index:1) then the second image as boot (boot index:2) and have compared results on bytes.

cmd
fc /b

Distinctions have appeared minimum (some kilobytes)

How I can in Grub4Dos apply a patch to the RAM (write) or change in HEX editor BootSDI so that the loader selected the necessary image inside boot.wim?

Somebody could help to research this question? Thanks

#125 steve6375

steve6375

    Platinum Member

  • Developer
  • 7567 posts
  • Location:UK
  • Interests:computers, programming (masm,vb6,C,vbs), photography,TV,films
  •  
    United Kingdom

Posted 23 October 2010 - 08:12 AM

here is an example of how to alter 3 bytes of a boot file loaded into memory

title Install Windows 7 32-bit (bc2)
map --mem /BOOTMGR (rd)
write --offset=0x105E (rd)+1 \xEB\x08
write --offset=0x54696 (rd)+1 2
chainloader (rd)+1
root ()

So a few kb might take you quite a while to type in and the file size of menu.lst will probably be far too large!




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users