Jump to content











Photo
- - - - -

Recovery Console not working from USB Stick


  • Please log in to reply
159 replies to this topic

#1 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 30 July 2008 - 01:23 PM

Hi all,

I use the XP recoveryconsole started from grub and it works fine as long as i use it from cd/dvd. But when i put it on an USB stick (files copied with robocopy and grub installed with grubinst) all other options still work, but the recovery console just reboots...

I think it has something to do with the fact that the usb stick is like an USB HD and maybe the recovery console does not run from hd?

Thanks for your help!!

Markus

#2 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 30 July 2008 - 02:04 PM

It does work from both HD AND USB.

READ these:
http://www.boot-land...?showtopic=2254
http://www.911cd.net...showtopic=20983
http://www.911cd.net...showtopic=21049
AND links therein.

Alternatively, you may want to try posting some relevant :cheers: information (compare with "Common Sense Advice" point d.):
http://www.boot-land...?act=boardrules

Trivialities :cheers: like:
Filesystem used
Directory name (if not \CMDCONS\)
Directory listing of ROOT of stick
Directory listing of \CMDCONS\ directory
Bootsector used
menu.lst entry /method used
may make a difference :cheers:

jaclaz

#3 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 30 July 2008 - 06:35 PM

OK, i tried finding what i did wrong by reading the posts and links you pointed me to, but did not (yet) suceeed.

Here are some more details, maybe someone can give me a hint.

my txtsetup.sif ist attached

My target dir looks like this:

30.07.2008 19:48 <DIR> boot
02.11.2006 22:00 438.840 BOOTMGR
30.07.2008 19:49 1.054 menu.lst
30.07.2008 19:48 <DIR> Programs
30.07.2008 19:48 <DIR> RECO
30.07.2008 19:48 673 vistape.cfg
30.07.2008 19:49 86.654.499 vistape.wim


my usb root looks like this

30.07.2008 14:54 <DIR> boot
02.11.2006 22:00 438.840 BOOTMGR
30.07.2008 14:51 192.009 GRLDR
30.07.2008 14:51 1.054 menu.lst
30.07.2008 14:54 <DIR> Programs
30.07.2008 14:54 <DIR> RECO
30.07.2008 14:50 673 vistape.cfg
30.07.2008 14:51 86.654.543 vistape.wim


My menu.lst looks like this:

splashimage /boot/gentleblue.gz

timeout 30

default 0

 

title VPE c&#39;t edition

chainloader /BOOTMGR

 

title Parted Magic Linux 2.2 &#40;Runs from RAM&#41;

kernel /boot/plinux/kernel.pml vga=788 noapic root=/dev/ram0 squashfs=/boot/plinux/pmagic.fs pmodules=/boot/plinux//pmodules init=/linuxrc ramdisk_size=200000 keymap=us liveusb quiet toram

initrd /boot/plinux/initrd.pml

 

title Windows XP SP2 Recovery Console German

chainloader /RECO/SETUPLDR.BIN

 

title Find and Load NTLDR of Windows NT/2K/XP

find --set-root /ntldr

chainloader /ntldr

 

title Find and Load CMLDR of Windows NT/2K/XP

find --set-root /cmldr

chainloader /cmldr

 

title find and load IO.SYS of Windows 9x/Me

find --set-root /io.sys

chainloader /io.sys

 

title find and boot Linux with menu.lst already installed

find --set-root /sbin/init

configfile /boot/grub/menu.lst

 

title MemTest86+

kernel /boot/memtest.bin

 

title Floppy &#40;fd0&#41;

chainloader &#40;fd0&#41;+1

rootnoverify &#40;fd0&#41;

 

title CommandLine

commandline

 

title Reboot

reboot

 

title Halt

halt

the recovery console was made with the recc.script from vistape12b3. Here is the basic code (not complete, removed everything not relevant just to show what is done)

Echo,Downloading requested files...

WebGet,&#34;%DL_GERMAN%&#34;,&#34;%TmpFolder%%pScrollBox1%\WindowsXP-KB310994-SP2-Pro-BootDisk.exe&#34;

Echo,Extracting downloaded files...

ShellExecute,hide,&#34;%Tools%\7z.exe&#34;,&#34;x -y #$q%TmpFolder%%pScrollBox1%\WindowsXP-KB310994-SP2-Pro-BootDisk.exe#$q -o#$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot1.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot2.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot3.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot4.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot5.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%Tools%\extract.exe&#34;,&#34;-x #$q%TmpFolder%%pScrollBox1%\cdboot6.img#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

ShellExecute,hide,&#34;%WindowsDir%\System32\expand.exe&#34;,&#34;-r #$q%TmpFolder%%pScrollBox1%\TXTSETUP.SI_#$q #$q%TmpFolder%%pScrollBox1%#$q&#34;

#remove junk

FileDelete,&#34;%TmpFolder%%pScrollBox1%\WindowsXP-KB310994-SP2-Pro-BootDisk.exe&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\makeboot.exe&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\makebt32.exe&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot1.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot2.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot3.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot4.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot5.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\cdboot6.img&#34;

FileDelete,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SI_&#34;



#patch setupldr.bin to find its files in the recc folder insted of the i386 folder

ShellExecute,hide,&#34;%Tools%\sfk.exe&#34;,&#34;rep #$q%TmpFolder%%pScrollBox1%\SETUPLDR.BIN#$q -yes -text /i386/RECO/&#34;



#replace some strings in original txtsetup.sif

TXTReplace,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SIF&#34;,&#34;1=%cdname%,%cdtagfilei%,,\i386&#34;,&#34;1  = %cdname%,%cdtagfilei%,,\RECO&#34;

#replacement order does matter

TXTReplace,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SIF&#34;,&#34;win51ip.sp2&#34;,%tagfile%

TXTReplace,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SIF&#34;,&#34;win51ip2&#34;,%tagfile%

TXTReplace,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SIF&#34;,&#34;win51ip&#34;,%tagfile%

TXTReplace,&#34;%TmpFolder%%pScrollBox1%\TXTSETUP.SIF&#34;,&#34;win51mp&#34;,%tagfile%



#copy to target

FileCopy,&#34;%TmpFolder%%pScrollBox1%\*.*&#34;,&#34;%TargetDir%\RECO&#34;

If,ExistFile,&#34;%TmpFolder%%pScrollBox1%\BOOTFONT.BIN&#34;,FileCopy,&#34;%TmpFolder%%pScrollBox1%\BOOTFONT.BIN&#34;,&#34;%TargetDir%\BOOTFONT.BIN&#34;



#add to grub

TXTAddLine,&#34;%MenuFile_GRUB%&#34;,&#34;title Windows XP SP2 Recovery Console %pScrollBox1%&#34;,&#34;Append&#34;

TXTAddLine,&#34;%MenuFile_GRUB%&#34;,&#34;chainloader /RECO/SETUPLDR.BIN&#34;,&#34;Append&#34;

TXTAddLine,&#34;%MenuFile_GRUB%&#34;,&#34; &#34;,&#34;Append&#34;

the created recoverconsole works when bootet from the iso (created from the obove target dir)

Any hints are welcome, thanks!

Attached Files



#4 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 30 July 2008 - 08:41 PM

Yep, as often happens, it seems to me like an overlapping of modifications.

Without actually checking it, there is:
1) a modification of TXTSETUP.SIF
2) a modification of SETUPLDR.BIN
3) a modification of default \CMDCONS\ directory (to \RECO\)

It is probable that either the TXTSETUP.SIF or the SETUPLDR.BIN changes have been made ONLY to the "CD related" part. (there would have been no reason to change anything else)

Try using:
1) using an UNMODIFIED TXTSETUP.SIF
2) using an UNMODIFIED SETUPLDR.BIN
3) rename back \RECO\ to \CMDCONS\
4) change:
title Windows XP SP2 Recovery Console German

chainloader /RECO/SETUPLDR.BIN
to
title Windows XP SP2 Recovery Console German

find --set -root /CMDCONS/SETUPLDR.BIN

chainloader /CMDCONS/SETUPLDR.BIN

If everything works, you can then "refine" with:
1) using either a patched bootsector or the (default in grub4dos) bootsector memory patching to avoid to go through the "blue screens of Text setup
2) clean (reduce) TXTSETUP.SIF, remove useless drivers
3) re-compress TXTSETUP.SIF to TXTSETUP.SI_
4) add the (by yours truly :cheers:) trick about allowing access, file copying, etc. (No more CATCH 22)
5) if you use the Server 2003 SP1 or R2 SETUPLDR.BIN put the whole thing in a RAMDISK image and have it really portable
6) do whatever else is suggested/hinted/explained in the referenced threads

A good idea would be to build a "basic" Recovery Console CD with the Vlauri batch, one with the psc's script, (BOTH should not do the "exoteric" modifications that the .script you posted appears to be doing) compare them with the one made by that script, check info given in the threads, on how to put it to HD or USB stick.

jaclaz

#5 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 31 July 2008 - 08:00 AM

argl....still drives me crazy after trying and reading for hours now...so i decided to start from scratch but still no luck...

i took a fresh cmdcons install (winnt32.exe /cmdcons)

took the folder cmdcons and the files ntldr, boot.ini, bootfont.bin,ntdetect.com and cmldr from my c drive and put it on usb (freshly formatted NTfs with hp util)
made the usb stick bootable by grub with grubinst

added this menu.lst:

splashimage /boot/gentleblue.gz

timeout 30

default 0





title Windows XP SP2 Recovery Console German

find --set -root /CMDCONS/SETUPLDR.BIN

chainloader /CMDCONS/SETUPLDR.BIN



title chainloader /CMDCONS/SETUPLDR.BIN

chainloader /CMDCONS/SETUPLDR.BIN

 

title Find and Load NTLDR of Windows NT/2K/XP

find --set-root /ntldr

chainloader /ntldr



title chainloader /ntldr

chainloader /ntldr



title Find and Load CMLDR of Windows NT/2K/XP

find --set-root /cmldr

chainloader /cmldr



title chainloader /cmldr

chainloader /cmldr



title CommandLine

commandline

 

title Reboot

reboot

 

title Halt

halt
here is the boot.ini

&#91;boot loader&#93;

timeout=30

default=C&#58;\CMDCONS\BOOTSECT.DAT

&#91;operating systems&#93;

C&#58;\CMDCONS\BOOTSECT.DAT=&#34;Microsoft Windows XP-Wiederherstellungskonsole&#34; /cmdcons

\CMDCONS\BOOTSECT.DAT=&#34;Microsoft Windows XP-Wiederherstellungskonsole&#34; /cmdcons

so there is not much left that is non standard but still does not work, get the following errors:

menu.lst eintry 1 starts booting but tried to access floppy and does not continue
menu.lst eintry 2 starts booting until a line of text from the recovery console (white in black, can no read, gone too fast) comes up and the reboots
menu.lst eintry 3 and 4 boot into ntldr and i can get the boot menu but when selecting option 1 from boot ini i get (after a fwe seconds) "error rading disk....", option 2 just reboots (was just a test)
menu.lst eintry 5+6 both just reboot

i also tried with a patched txtsetup.sif where i changed the tagfile to \menu.lst but it did not work...

any ideas...i am almost giving up on this...

#6 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 31 July 2008 - 08:57 AM

ctmag,
sorry, but I do not get it. :cheers:

I suggested you to use one out of two methods to re-start from scratch and you managed to use a third one? :cheers:

However, giving up or failure IS NOT an option! :cheers:

Please follow me. :cheers:

Make a §#*@ing :cheers: Recovery Console CD ISO with the V. Laurie batch, first thing:
http://www.boot-land...?showtopic=2254

Follow EXACTLY this step by step tutorial:
http://www.911cd.net...o...20983&st=39

Just to make sure, try first with English Recovery floppies.

Once you have it working, EXACTLY as it is, we will see the mods you can make, grub4dos booting options, etc.

jaclaz

#7 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 31 July 2008 - 09:49 AM

Sorry for not following your advice...

I now did as you suggested: made the is (which boots fine in VMware) and then i copied it to USB and made an entry in menu.lst

title test
chainloader /I386/SETUPLDR.BIN

same result as before, starts booting the RC and after writing one line of text it reboots. So i think the problem must be the way the loader is started...on cd it works fine but not on usb.

(also tried "find --set -root /I386/SETUPLDR.BIN" but causes my floppy to run wild)

i also tried to boot the created cd boot sector, but grub does not like this file...is there a special way to boot such sectors? Or is there an (easy) way to just put the iso on the stick and boot the iso from grub?

#8 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 31 July 2008 - 10:16 AM

Hmmm, :cheers: sometimes (read often) I appear to have problems in communicating.

Does the word "EXACTLY" have a different meaning in Germany? :cheers:

Can you find anywhere on the given link:
http://www.911cd.net...o...20983&st=39
a reference to menu.lst, grub4dos, or chainloading?

Does this sentence:

Once you have it working, EXACTLY as it is, we will see the mods you can make, grub4dos booting options, etc.


mean if translated in German get the meaning of :cheers::

Use any way you think fit to copy the files to USB, introduce as many variations as you like to the booting mechanism, add grub4dos and a bunch of random menu.lst entries, and everything else that may cross your mind.


Let's see if Google translate helps:

Sie müssen nach dem Vorbild genau.


jaclaz

#9 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 31 July 2008 - 10:29 AM

Well you are right, i overlooked the posts for this topic.
I just thought that the topic would just consist of the question and did not see the answers...stupid me....:cheers: :cheers:

will read through that now...

#10 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 31 July 2008 - 04:49 PM

After trying a lot of different things including

  • Different USB Sticks
  • Different PC's
  • Different boot methods (ntldr and grub, chainloading bootsectors and/or setupldr.bin) which always work from hd
  • Following this also works from hd

I give up. :cheers:


Other topic:
I was hoping to at least get grub to chainload setupldr.bin with memorypatching the cmdcons switch (which works, rc starts without blue setup screens) but then it fails with a message saying txtsetup.sif not found...also could not resolve this...

#11 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 31 July 2008 - 05:13 PM

After trying a lot of different things including


Why not just the one (that you report working from HD, but not from USB, if I get it right) ?


I give up. :cheers:


Why? :cheers:

As said:

However, giving up or failure IS NOT an option!


Something that has been reported as working, MUST work.

There must be something either missing in the tutorial (and given as acquired before) or in the way you followed it.

Can I convince you to get back to work? :cheers:

You should confirm that:
1) You followed to the letter the proposed tutorial
2) That you are using English files
3) That you are using a FAT 16 or 32 formatted stick
4) That it works in Qemu
5) Post the actual error you have when on USB stick (it is NOT the same one you had before, is it?)
6) Confirm that it is a USB stick and not a USB HD, and whether the device is seen as "removable" or "fixed"

Then, there is more than one way to skin a cat. :cheers:

Try another approach, using instead of the "real" \CMDCONS\ structure, the "usual" \minint\ one, and chainloading normally SETUPLDR.BIN.
(You will have to go through the blue screen of setup, but it should work)

jaclaz

#12 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 31 July 2008 - 05:54 PM

Try another approach, using instead of the "real" \CMDCONS\ structure, the "usual" \minint\ one, and chainloading normally SETUPLDR.BIN.
(You will have to go through the blue screen of setup, but it should work)


If i understand your right here are the steps to go:
1. Format USB stick with fat
2. make stick bootable with bootsect.exe /nt50 g: /force
3. copy ntldr, ntdetect.com, boot.ini to the stick
4. add C:\MININT\SETUPLDR.BIN="RC Test" /cmdcons to boot.ini (or wothout cmdcons switch?)
5. copy copy the files (including the tagfiles) from the iso to usb stick (iso created from english files and testet in vmware first)
6. rename the i386 folder to MININT (uppercase?)
7. verify if stick boots and if it boots try RC Test

Result: when selecting RC test the system just reboots...

How can i verify if the stick runs as floppy or as hd? (grub always tells my try hd0,0 ntfs...so it should be HD or not?

#13 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 31 July 2008 - 06:53 PM

no, ctmag, sorry, but you seem to be missing some "basics" or a methodical approach.

You have a working .iso, right?

Then:
1. Format USB stick with fat by using PetoUSB or the HP formatting utility
1.a copy ntldr, ntdetect.com, boot.ini to the stick
1.b verify it boots up to boot.ini choices
2. if you did the above when running Vista and the stick does not boot make stick bootable with bootsect.exe /nt502 g: /force
2.a verify it boots up to boot.ini choices
3. copy ntldr, ntdetect.com, boot.ini to the stick copy the \i386 folder on your .iso to the stick
3.a rename the \i386 folder on the stick to \minint (small letters)
4. add C:\MININT\SETUPLDR.BIN="RC Test" /cmdcons to boot.ini (or wothout cmdcons switch?)
5. copy copy the files (including the tagfiles) from the iso to usb stick (iso created from english files and testet in vmware first)
6. rename the i386 folder to MININT (uppercase?)
4. copy to the stick grldr and menu.lst
5. add to boot.ini a line:
C&#58;\grldr=&#34;grub4dos&#34;
6. add to menu.lst an entry:
title RC test Blue

find --set-root /minint/SETUPLDR.BIN

chainloader /minint/SETUPLDR.BIN
7. verify if stick boots and if it boots try RC Test

#14 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 01 August 2008 - 07:02 AM

1. Format USB stick with fat by using PetoUSB or the HP formatting utility
done with hp util 2.0.6 (used fat not fat32, OK?)
does the hputil write the bootsector? I did not do bootsect.exe qafter the format.

1.a copy ntldr, ntdetect.com, boot.ini to the stick
done, boot.ini has entrYS
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Microsoft Windows XP Professional on HD" /noexecute=optin /fastdetect
and
C:\CMDCONS\BOOTSECT.DAT="Test" /cmdcons

1.b verify it boots up to boot.ini choices
boots up to the boot.ini menu, but does not boot windows or CMDCONS from hd
complains about missing "<windows dir>\system32\hal.dll" in both cases, those settings work fine from boot.ini on HD

#15 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 01 August 2008 - 08:16 AM

boots up to the boot.ini menu, but does not boot windows or CMDCONS from hd
complains about missing "<windows dir>\system32\hal.dll" in both cases, those settings work fine from boot.ini on HD


Yes, the HP utility does write the bootsector, but having never used it under Vista, I shifted the bootsect.exe to 2. and 2.a, just in case.

You can jump to 3.

GOOD. :cheers:

Now, change first entry in BOOT.INI from:

multi(0)disk(0)rdisk(0)partition(1)\WINDOWS

to

multi(0)disk(0)rdisk(1)partition(1)\WINDOWS


Check these:
http://www.msfn.org/...b....html&st=13
http://www.msfn.org/...f...5.html&st=2

Second entry won't of course work until you have the files on the stick.

What happens?

jaclaz

#16 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 01 August 2008 - 09:45 AM

1. Format USB stick with fat by using PetoUSB or the HP formatting utility
done with hp util 2.0.6 (used fat not fat32, OK?) Bootsector writteb by hp tool

1.a copy ntldr, ntdetect.com, boot.ini to the stick
done, boot.ini has entry
multi(0)disk(0)rdisk(1)partition(1)\WINDOWS="Microsoft Windows XP Professional on HD" /noexecute=optin /fastdetect

1.b verify it boots up to boot.ini choices
boots up to the boot.ini menu, boots windows from hd fine

skipped 2 and 2a as it worked without bootsect

3. copy the \i386 folder on your .iso to the stick
3.a rename the \i386 folder on the stick to \minint (small letters)
done

4. copy to the stick grldr and menu.lst
done

5. add to boot.ini a line: C:\grldr="grub4dos"
done

6. add to menu.lst an entry:
title RC test Blue
find --set-root /minint/SETUPLDR.BIN
chainloader /minint/SETUPLDR.BIN

done

7. verify if stick boots and if it boots try RC Test

boots, loads grub, starts loading setupldr.bin but errors out with

\$win_nt5.~bt\biosinfo.inf not found code 18

(TXTsetup.sif is still default and packed and tagfiles are not present on stick)

#17 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 01 August 2008 - 12:16 PM

may i drop in a quick question please:

nightman uses "hpusbfw.exe -f" to format usb sticks (i believe the complete line is wrong)

ShellExecute,Open,"%basedir%\Temp\%ProjectName%\usb\HPUSBFW.exe" -f,"#$qg:\ #$q"
should be ShellExecute,Action,"Filename","Parameters","StartDir"
ShellExecute,Open,"%basedir%\Temp\%ProjectName%\usb\HPUSBFW.exe","-f"

But i believe the -f is a leftover from pe2usb which uses this syntax. I could nowhere find proof that hpusbfw.exe accepts any commandline arguments...do you know more about this (and can you confirm that nightman original line is wrong)? Thanks.

#18 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 01 August 2008 - 01:09 PM

boots, loads grub, starts loading setupldr.bin but errors out with

\$win_nt5.~bt\biosinfo.inf not found code 18

(TXTsetup.sif is still default and packed and tagfiles are not present on stick)


Good. :cheers:

this:

\$win_nt5.~bt\biosinfo.inf not found code 18

should be:

\$win_nt$.~bt\biosinfo.inf not found code 18


Some reference:
http://www.msfn.org/...n...5.html&st=2

Let's introduce a (temporary) variation:
rename \minint to \$win_nt$.~bt

and add to menu.lst this entry:
title RC test Blue $win_nt$.~bt

find --set-root /$win_nt$.~bt/SETUPLDR.BIN

chainloader /$win_nt$.~bt/SETUPLDR.BIN

What happens?

jaclaz

#19 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 01 August 2008 - 02:16 PM

Result:

txtsetup.sif corrupted or missing status 18

Where to go from here?

#20 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 02 August 2008 - 08:51 AM

Result:

txtsetup.sif corrupted or missing status 18

Where to go from here?


Good. :cheers:

Let's introduce another (temporary, again) variation.

COPY the \$WIN_NT$.~BT\TXTSETUP.SI_ to ROOT of the stick.

What happens?

(you should get to the "usual" blue SETUP screen and from it choose R and get to the recovery console) :cheers:

jaclaz

#21 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 02 August 2008 - 11:00 AM

Works fine...

#22 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 02 August 2008 - 11:59 AM

GOOD. :cheers:

Now:
1) rename $WIN_NT$.~BT to CMDCONS
2) delete the TXTSETUP.SI_ in ROOT
3) Change your BOOT.INI to this:
[codebox]color black/cyan yellow/cyantimeout 30default 0title find and load NTLDR of Windows NT/2K/XPfind --set-root /ntldrchainloader /ntldrtitle Boot Recovery Console of Windows NT/2K/XP SETUPLDR.BINfind --set-root /setupldr.binchainloader /setupldr.bin###################################################################### write string "cmdcons" to memory 0000:7C03 in 2 steps:###################################################################### step 1. Write 4 chars "cmdc" at 0000:7C03write 0x7C03 0x63646D63# step 2. Write 3 chars "ons" and an ending null at 0000:7C07write 0x7C07 0x00736E6Ftitle Boot Recovery Console of Windows NT/2K/XP \CMDCONS\SETUPLDR.BINfind --set-root /CMDCONS/setupldr.binchainloader /CMDCONS/setupldr.bin###################################################################### write string "cmdcons" to memory 0000:7C03 in 2 steps:###################################################################### step 1. Write 4 chars "cmdc" at 0000:7C03write 0x7C03 0x63646D63# step 2. Write 3 chars "ons" and an ending null at 0000:7C07write 0x7C07 0x00736E6Ftitle RC CMDCONS cmdcons.bsfind --set-root /cmdcons.bschainloader /cmdcons.bs[/codebox]5) add in CMDCONS\ a file named WINNT.SIF with this contents:[code]&#91;data&#93;msdosinitiated=&#34;1&#34;floppyless=&#34;1&#34;CmdCons=&#34;1&#34;[/code]
6) create a backup of the bootsector of the stick, save it as setupldr.bs, use a hex editor or whatever to change "NTLDR" at offset 1A1/417 to "SETUPLDRBIN"

7) create a copy of setupldr.bs, save it as cmdcons.bs, use a hex editor or whatever to change the "MSDOS5.0" at offset 3 to "cmdcons" (please note that cmdcons is 7 characters long, whilst "MSDOS5.0" is 8, so you must also make sure that after "cmdcons" there is a "00" instead of the current "30"), more details are in the already referenced thread:
http://www.boot-land...topic=2362&st=7

8) try experimenting all the booting choices you have :cheers:
[teasing]
one (or more) of the entries in BOOT.INI won't work, can you guess which without actually testing it? :cheers:
[/teasing]

For your convenience, find in the attached file:
a. BOOT.INI (as above detailed)
b. menu.lst (as above detailed)
c. \CMDCONS\WINNT.SIF (as above detailed)
d. original.bs (the bootsector you sent me via PM, on request)
e. setupldr.bs (modified original.bs, as above detailed)
f. cmdcons.bs (modified setupldr.bs, as above detailed)

AT ALL OTHERS:
quite obviously the bootsectors in the attachment are SPECIFIC to ctmag's stick, they can only be useful for reference to modify them on other sticks

A note:
if you use the grub4dos menu.lst entry:
"Boot Recovery Console of Windows NT/2K/XP \CMDCONS\SETUPLDR.BIN"
you can get rid of the SETUPLDR.BIN in ROOT of the stick.

Let us know your report on the various choices.

jaclaz

Attached Files



#23 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 02 August 2008 - 02:38 PM

Thanks for all your help, and to answer your question:

chainloader /setupldr.bin

points to a not existing file...so this can not work.

you zip includes a file setupldr..bs (two .)...renamed it to .bs

none of the boot.ini options work (except grub)

and in grub only chainloader /CMDCONS/setupldr.bin works bringing up a working RC.

i noticed that (after i had to reformat the usb stick) my bootsectors changed a bit, maybe this is the reason (see PM)...but i only used the hp tool as always...don't know why they changed

Will do more testing an come back to this on monday...thanks very much so far !!!

#24 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7,098 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 02 August 2008 - 03:28 PM

You are welcome. :cheers:

Hmmm, :cheers:

The bootsector you sent me was a German one, I do not think that the USB version by itself makes localized version, :cheers:

I thought you had a setupldr.bin in ROOT of the stick.

Of course none of the "direct" chainloading from BOOT.INI can work, since any bootsector can only load files in ROOT of the drive.

And yes, I actually introduced THREE "mistakes" (just to see if you were following attentively or not :cheers: ):
1) The misnamed setupldr..bs
2) The entry:

C:\setupldr.bs="XP SETUPLDR.bs No params"

in BOOT.INI (that cannot work, besides the double dots, as NO /cmdcons parameter is present)
3) The entry:

C:\orignal.bs="XP NTLDR"

in BOOT.INI (that cannot work as as the file is named original.bs)

Besides the intentional "teasing", your report about what happened with the re-formatting of the stick, is a good demonstration of the idea that wherever possible direct chainloading from grub4dos is a better choice, as it bypasses the bootsector (that can possibly have become invalid due to changes in formatting).

More generally, and expecially when experimenting, a good idea is to make things in a way that they are repeatable.

For formatting a USB key in a repeatable way:
1) Use the HP USB utility ONCE (you will NEVER need the HP utility again)
2) Backup the MBR with HDhacker
3) Format (or, better said) re-format the stick using your OS FORMAT command
4) If using Vista, run bootsect.exe /nt52


When you need to re-format:
1) Restore the MBR with HDhacker
2) Format the stick using your OS FORMAT command
3) If using Vista, run bootsect.exe /nt52

Since FORMAT uses the info in the MBR, the result will be exactly the same.

An even better method is hinted here:
http://www.boot-land...?showtopic=5000

As long as you create the image files as a sparse image, it will take just a few Kbytes on your harddisk, and when you transfer it to the stick it will "grow" re-creating the formatting and zeroing out all the rest of the sectors.
WARNING: The image can be compressed in a .zip or 7.z, but when extracted will grow to full size anyway.


jaclaz

#25 pecd.net

pecd.net

    Silver Member

  • .script developer
  • 947 posts
  •  
    Germany

Posted 02 August 2008 - 04:05 PM

Not much time today, sorry, will come back to this monday...

But to be honest, i did not much care about the boot.ini options as i never wanted to use them in the project i am working on, so i just selected them once and did not check further...you got me:-)

Its not always easy getting the answer from you, but one learns something on the way...:-)




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users