jaclaz Posted February 9, 2007 Share Posted February 9, 2007 Make sure you just copy the files and not create an ISO on the drive, this will give you basically a CD on the drive and it will be seen as a USB CDROM drive.VERY interesting. Did you succeed with the above on real hardware, not a VM?Can you post details on the hardware you tested that on?Can you confirm that a USB stick with a CDFS filesystem is seen by BIOS/setup as a CD-ROM drive?jaclaz Link to comment Share on other sites More sharing options...
enuffsaid Posted February 9, 2007 Share Posted February 9, 2007 (edited) If read somewhere that Vista does a great job at creating Bootable USB drives, but ONLY from within Vista. I'll see if I can find that article.'nuffEDIT: Found the article. It describes how to create a bootable WinPE 2.0 USB stick. The stick must be formatted from within Vista. Is that of any use to you? Edited February 9, 2007 by enuffsaid Link to comment Share on other sites More sharing options...
jaclaz Posted February 10, 2007 Share Posted February 10, 2007 Yes,every info is interesting, but maybe Vista and WinPE 2.0 have nothing to do with windows XP, and with installing it from USB.Why don't you post a new thread with a link to the article in the Vista section?jaclaz Link to comment Share on other sites More sharing options...
enuffsaid Posted February 10, 2007 Share Posted February 10, 2007 You needed to format the USB stick with Vista. That's all that Vista was needed for if I remember correctly. Let me look for that article. Link to comment Share on other sites More sharing options...
Sgt_Strider Posted March 3, 2007 Share Posted March 3, 2007 Any updates on the methods posted here? Does all USB sticks work though? Link to comment Share on other sites More sharing options...
jaclaz Posted March 3, 2007 Share Posted March 3, 2007 Any updates on the methods posted here?Not yet, still have to find the time to "invent" or "find" a way to avoid (or restore) the deletion of files.Does all USB sticks work though?Yes.jaclaz Link to comment Share on other sites More sharing options...
cdob Posted March 26, 2007 Share Posted March 26, 2007 Setup deletes files at two times: -end of textmode setup-end of graphic mode setup: T -1 minutesSet USB WriteProtect twice.First \$WIN_NT$.~BT\migrate.inf[Version]Signature = "$Windows NT$"[Addreg];fix USB drive letter, adjust setting to your partitionHKLM,"SYSTEM\MountedDevices",,0x00000010HKLM,"SYSTEM\MountedDevices","\DosDevices\U:",0x00030001,\ 5c,00,3f,00,3f,00,5c,00,53,00,54,00,4f,00,52,00,41,00,\ 47,00,45,00,23,00,52,00,65,00,6d,00,6f,00,76,00,61,00,62,00,6c,00,65,00,4d,\ 00,65,00,64,00,69,00,61,00,23,00,37,00,26,00,31,00,64,00,64,00,65,00,34,00,\ 37,00,39,00,65,00,26,00,30,00,26,00,52,00,4d,00,23,00,7b,00,35,00,33,00,66,\ 00,35,00,36,00,33,00,30,00,64,00,2d,00,62,00,36,00,62,00,66,00,2d,00,31,00,\ 31,00,64,00,30,00,2d,00,39,00,34,00,66,00,32,00,2d,00,30,00,30,00,61,00,30,\ 00,63,00,39,00,31,00,65,00,66,00,62,00,38,00,62,00,7d,00;WriteProtect USBHKLM,"SYSTEM\ControlSet001\Control\StorageDevicePolicies","WriteProtect",%REG_DWORD%,1[Strings];Handy macro substitutions (non-localizable)REG_SZ = 0x00000000REG_BINARY = 0x00000001REG_DWORD = 0x00010001REG_MULTI_SZ = 0x00010000REG_SZ_APPEND = 0x00010008REG_EXPAND_SZ = 0x00020000MountedDevices fixes USB drive letter to U: This can be used at PNP time.Setting is hardware related, export MountedDevices USB setting from local registry.Different USB Sticks may require different MountedDevices settings. Create different migrate.inf.Second \$WIN_NT$.~LS\I386\hiveOEM.inf[Version]Signature = "$Windows NT$"DriverVer=07/01/2001,5.1.2600.2180[AddReg];WriteProtect USBHKLM,"SYSTEM\CurrentControlSet\Control\StorageDevicePolicies","WriteProtect",0x10001,1\txtsetup.sif: add hiveOEM.inf[SourceDisksFiles]hiveOEM.inf = 100,,,,,,_x,,3,3[HiveInfs.Fresh]AddReg = hiveOEM.inf,AddReg\$WIN_NT$.~BT\winnt.sif[data]msdosinitiated="1"UseSignatures="no"EulaComplete="1"Install windows. At T -1 minutes wait a looong time or remove USB stick. Setup reboots then. No files are deleted at USB stick.After windows installation USB stick is write protected still.You may change StorageDevicePolicies to 0 to disable write protection and delete USB stick in device manager.Another solution might be fbwf (File Based Write Filter Driver): write protect drive letter U:A XP Embedded user may have more knowledge. Link to comment Share on other sites More sharing options...
jaclaz Posted March 29, 2007 Share Posted March 29, 2007 @cdobVERY interesting! Any idea for the reason for the "loong" wait?About the migrate.inf setting, I remember having started (and not actually finished as most of my projects ) looking into the data written into MountedDevices keys, I am pretty confident that a batch that can automate the creation of it can be made.about:[strings];Handy macro substitutions (non-localizable)REG_SZ = 0x00000000REG_BINARY = 0x00000001REG_DWORD = 0x00010001REG_MULTI_SZ = 0x00010000REG_SZ_APPEND = 0x00010008REG_EXPAND_SZ = 0x00020000since the .inf only contains one "directive", cannot it be eliminated changing the line to:HKLM,"SYSTEM\ControlSet001\Control\StorageDevicePolicies","WriteProtect",0x10001,1? jaclaz Link to comment Share on other sites More sharing options...
cdob Posted March 29, 2007 Share Posted March 29, 2007 Any idea for the reason for the "loong" wait?Setup tries to delete all files still, but can't delete files.I've no idea, how setup works internally.Yes, a batch can convert MountedDevices keys. This is a job for a Rob van der Woude third party author.Rember a fixed USB drive letter is not required, but may be nice anyway.Yes, StorageDevicePolicies could be one line in migrate.inf.REG_BINARY is easier to read and may get less errors at editing migrate.inf.And this was a hint, migrate.inf can hold additional entries.BTW: At PE setupldr.bin read \minint\system32\migrate.inf. Link to comment Share on other sites More sharing options...
ilko_t Posted April 17, 2007 Share Posted April 17, 2007 It worked as described, great job cdob, thanks I didn't keep mounted devices in migrate.inf, just the write-protect entry and the USB device got D, hard drive got C. No files were deleted, to avoid the long wait I removed the USB stick after 2-3 minutes waiting.However I had to made a little change for the text- mode in menu.lst :title Phase 1 WinXP Text Mode Setupmap --read-only (hd0) (hd1)map --hookrootnoverify (hd1)chainloader (hd1,0)/setupldr.binsavedefault 1boottitle Phase 2 WinXP GUI Mode Setupmap (hd1) (hd0)map (hd0) (hd1)rootnoverify (hd1)chainloader +1 savedefault 0boototherwise I was getting blinking cursor and nothing was happening, with grub4dos-0.4.3-2007-03-16.@jaclaz- many thanks for keeping this thread alive and all your useful posts, here, in 911cd.net and any other forums Link to comment Share on other sites More sharing options...
jaclaz Posted April 17, 2007 Share Posted April 17, 2007 @ilko_tVERY good! It seems like we are almost done. I guess most of the merit has to go to cdob, whose help and knowledge has been decisive, and to porear whose contribution of ideas and testing was fundamental. While the first of your menu.lst entries does make sense to me, I am still curious how the second one works, as I see it things must have some logic behind, if BOTH the entries work, this:title Phase 1 WinXP Text Mode Setupmap --read-only (hd0) (hd1)map --hookrootnoverify (hd1)chainloader (hd1,0)/setupldr.binsavedefault 1bootshould be also working if rewritten as:title Phase 1 WinXP Text Mode Setupmap (hd1) (hd0)map (hd0) (hd1)rootnoverify (hd1)chainloader (hd1,0)/setupldr.binsavedefault 1bootby the same principle, viceversa, the entry:title Phase 2 WinXP GUI Mode Setupmap (hd1) (hd0)map (hd0) (hd1)rootnoverify (hd1)chainloader +1 savedefault 0bootshould work as well if rewritten as:title Phase 2 WinXP GUI Mode Setupmap --read-only (hd0) (hd1)map --hookrootnoverify (hd1)chainloader +1 savedefault 0bootAs said, the final boot command is unnecessary, and it should be possible to replace:chainloader (hd1,0)/setupldr.binwith:chainloader (hd1,0)/$WIN_NT$.~BT/setupldr.binto avoid copying SETUPLDR.BIN and NTDETECT.COM to the root of the stick.And, besides, once you have issued a root or rootnoverify command, root is established, and you only need the forward slash, i.e. :chainloader (hd1,0)/$WIN_NT$.~BT/setupldr.binshould be functionally equivalent to:chainloader /$WIN_NT$.~BT/setupldr.bin(as in the second menu.lst entry)I would be nice if you could test the above and make a new post with all steps together, something one could post a direct link to, to avoid other members to jump forward and backward on this longish thread, as is it is causing me headaches, and I already now most of it. jaclaz Link to comment Share on other sites More sharing options...
ilko_t Posted April 17, 2007 Share Posted April 17, 2007 (edited) In my excitement I forgot to thank porear , many thanks to him map --read-only (hd0) (hd1)map --hookrootnoverify (hd1)chainloader /$WIN_NT$.~BT/setupldr.bin gives Error 19, cannot mount selected partitionmap (hd0) (hd1)map (hd1) (hd0)rootnoverify (hd1)chainloader /$WIN_NT$.~BT/setupldr.bin gives the same messageIf in command line I type map (hd0) (hd1)map (hd1) (hd0)map --hook - as far as I know it should be done in order to apply and see the changes in command linerootnoverify (hd1)find /$WIN_NT$.~BT/setupldr.bin --->result is hd(1,0)chainloader /$WIN_NT$.~BT/setupldr.bin gives error 19chainloader (hd1,0)/$WIN_NT$.~BT/setupldr.bin gives the encouraging "Will boot NTLDR from drive=0x81, partition=0x0..."now booting SETUP is possible, but as far as I remember it will end up with improper boot.ini, pointing to rdisk(1), instead of (0), that's why I stuck with the map --read-only... variant for TEXT mode. This will be first to test.Honestly GRUB for me by far not so easy to understand, in some commands I just can't see logical explanation why work or why not.For example in README.TXT:4. Emulates an HD partition as the first hard disk and boot DOS from it: map --read-only (hd2,6)+1 (hd0) map --hook chainloader (hd0,0)+1 rootnoverify (hd0) map --harddrives=1 boot In this example, (hd2,6)+1 represents an extended logical DOS partition of the third BIOS hard disk (hd2).breaks the rule map (TO) (FROM) and is opposite (or at least not similar) for me as written herehttp://www.gnu.org/software/grub/manual/grub.html#map :13.3.23 map— Command: map to_drive from_drive Map the drive from_drive to the drive to_drive. This is necessary when you chain-load some operating systems, such as DOS, if such an OS resides at a non-first drive. Here is an example: grub> map (hd0) (hd1) grub> map (hd1) (hd0) The example exchanges the order between the first hard disk and the second hard diskI beleive title Phase 2 WinXP GUI Mode Setupmap (hd1) (hd0)map (hd0) (hd1)rootnoverify (hd1)chainloader +1savedefault 0boot makes sense to be changed to title Phase 2 WinXP GUI Mode Setupmap --read-only (hd0) (hd1)map --hookrootnoverify (hd0)chainloader (hd0,0)/ntldrsavedefault 0This will be second to test and I will report the results with a full step by step guide. Edited April 17, 2007 by ilko_t Link to comment Share on other sites More sharing options...
jaclaz Posted April 17, 2007 Share Posted April 17, 2007 VERY GOOD.Also, try with "root" instead of "rootnoverify"....jaclaz Link to comment Share on other sites More sharing options...
ilko_t Posted April 17, 2007 Share Posted April 17, 2007 (edited) Here are some findings:-setupldr.bin (renamed in my case as ntldrstp), ntdetect.com and txtsetup.sif must be copied in root, or it simply reboots when chainloaded, tried many options, but all results were either a hang with blinking cursor or just restart.Some experiments with GRUB, with red color were unsuccessful:TXT setupmap (hd1) (hd0)map (hd0) (hd1)map --hook....in this case ntldrstp cannot be foundTXT modemap (hd0) (hd1)map (hd1) (hd0)map --hookroot (hd1,0)chainloader (hd1,0)/ntldrstpSetup starts, but gives error 14, txtsetup.sif is missing or damaged. GUI setupmap --read-only (hd1) (hd0)map (hd0) (hd1)root (hd0,0)chainloader (hd0,0)+1boots GUI mode fine, read only switch shouldn't be needed anyway. It finds ntldr in (hd0,0) and completes the GUI part just fine.GUI setupmap --read-only (hd1) (hd0)map --hookroot (hd0,0)chainloader (hd0,0)+1Boots and completes GUI mode fine, ntldr is found in both in (hd0,0) and (hd1,0), but this seems to cause no problems.GUI setupmap --read-only (hd0) (hd1)root (hd0,0)chainloader (hd0,0)+1ntldr couldn't be found-----------------------------------------------------------The last working menu.lst I is:color black/cyan yellow/cyantimeout 10default /defaulttitle Phase 1 WinXP Text Mode Setup map --read-only (hd0) (hd1)map --hookroot (hd1,0)chainloader (hd1,0)/ntldrstpsavedefault 1title Phase 2 WinXP GUI Mode Setup map --read-only (hd1) (hd0)map --hookroot (hd0,0)chainloader (hd0,0)+1savedefault 0ntdetect.com, txtsetup.sif and setupldr.bin are copied to root and setupldr.bin renamed to ntldrstp in my case.It would have been perfect if all this worked on my laptop too, but it did not. All the test so far were done on ABIT AN7 motherboard with NF2 chipset and a blank, not partitioned IDE disk.On Dell Inspiron 6000 when I use same menu.lst it reboots when TXT mode is selected. It has 3 partitions with XP Home installed- Dell Diagnostic, System and Dell Recovery. Double mapping didn't work, mapping (hd1,0-2) too, but when I use only:rootnoverify (hd0,0)chainloader /ntldrstpit works just fine with no drive mapping at all. On the desktop computer using the same entries result in incorrect boot.ini ( rdisk(1) )as I already wrote about. Haven't tested yet will it set the correct entries on the laptop with no mapping.Is it because of the different BIOS-es and the way they handle USB? Any ideas? Edited April 17, 2007 by ilko_t Link to comment Share on other sites More sharing options...
jaclaz Posted April 18, 2007 Share Posted April 18, 2007 OK, so definitely we need the SETUPLDR.BIN and NTDETECT.COM on root.A possible "definitive" way out could be:color black/cyan yellow/cyantimeout 10default /defaulttitle Phase 1 WinXP Text Mode Setup map --read-only (hd0) (hd1)map --hookfind --set-root /ntldrstpchainloader /ntldrstpsavedefault 1title Phase 2 WinXP GUI Mode Setup map --read-only (hd1) (hd0)map --hookfind --set-root /ntldrchainloader /ntldrsavedefault 0 In the second item if ntldr is found on both disks, it could maybe cause problems, one could use another file as a marker even if it is found in a subdirectory, the "root" will be to the drive, I am not at all an expert in this, but if one cannot find a file that is on the HD and not on the stick, it should be possible to create it with some entry in TXTSETUP.SIF or similar.Also, maybe there is something "between the lines" of this:http://support.microsoft.com/kb/312569/en-us(if we can find an alternative to the "loong" wait and/or the extraction and reinsertion of the key, we would have a potential "unattended" method)jaclaz Link to comment Share on other sites More sharing options...
Recommended Posts