π
2010-08-21 01:01
in Linux
First, if you don't know them, it's a mashup of http://www.ultimatebootcd.com/ and http://www.ubcd4win.com/ . Very convenient for recovery of systems.
I wanted to have a USB key that could boot both UCBD and UBCD4Win, the two award winning ultimate boot CDs for rescue and other things. Turns out however that making a bootable USB key is not that simple, XP is not even meant to boot from USB apparently.
To make things simple, UBCD boots with syslinux and UBCD4WIN boots with grub. However, copying the files from UBCD4WIN on a UBCD bootable USB stick does not allow to boot XP from grub anymore (it complains about a missing boot.ini it didn't need before).
After some research and work, here's what I was able to find and come up with. I'd love to be able to just share my image with you, but because of the XP license and requirement that you use your own XP media to generate it, I can't do that unfortunately.
Make use ubcd4win image
In my case, I already a ubcd4win CD image and didn't want to make a new one since it takes a while, but apparently if you make a new one, there is an option to make it usb compatible ( see http://www.youtube.com/watch?v=jdIKHdcMA0Y#t=6m10 ).
make ubcd4win installed/bootable for usb with bartpetoUSB: http://gocoding.com/page.php?al=petousb
However this setup forces the windows boot and ignores boot.ini/config.sys and grub, so there is no way to boot anything else that I could find.
get grub4dos: http://grub4dos.sourceforge.net/wiki/index.php/Grub4dos_tutorial and http://sourceforge.net/projects/grub4dos/
Then install gldr.mbr/gldr on the USB key (maybe only one is needed)
use grub4dos installer: http://www.themudcrab.com/acronis_grub4dos.php
The trick is to select disk, not select a file and chose whole disk/don't search floppy. This causes grub to boot instead of ntldr
copy ubcd files over (I used an existing ubcd ISO image from http://www.ultimatebootcd.com/download.html and copied the files over to my USB key).
I then had to modify menu.lst on the USB key to launch UBCD options too (you'll probably need some ^M's in there when you save it on your FAT filesystem).
color black/cyan yellow/cyan
default /default
default 0
timeout 10
title Launch "The Ultimate Boot CD for Windows"
fallback 1
find --set-root /ntldr
chainloader /ntldr
savedefault --wait=2
title
pause
# doesn't work without patched grub
#title UBCD menu
#chainloader /boot/isolinux/isolinux.bin
#savedefault --wait=2
title BIOS
configfile /ubcd/menus/grub4dos/bios.lst
title CPU
configfile /ubcd/menus/grub4dos/cpu.lst
title HDD
configfile /ubcd/menus/grub4dos/hdd.lst
title Memory
configfile /ubcd/menus/grub4dos/memory.lst
title Others
configfile /ubcd/menus/grub4dos/others.lst
title Peripherals
configfile /ubcd/menus/grub4dos/periph.lst
title System
configfile /ubcd/menus/grub4dos/system.lst
title Parted Magic V4.10\n Linux distro for manipulating partitions (eg. create, resize). Includes\n TestDisk, PhotoRec, Partition Image...)
configfile /pmagic/boot/grub4dos/grub4dos.lst
title UBCD FreeDOS R1.38 (Based on NwDsk V3.40)\n FreeDOS boot disk used to run many of the other DOS apps on the UBCD.
map --mem /ubcd/images/fdubcd.img.gz (fd0)
map --hook
chainloader (fd0)+1
rootnoverify (fd0)
title User-defined
configfile /ubcd/custom/custom.lst
title
pause
title Reboot\n Reboot the PC.
reboot
title
pause
title commandline
savedefault --wait=2
commandline
title floppy (fd0)
chainloader (fd0)+1
rootnoverify (fd0)
savedefault --wait=2
title reboot
savedefault --wait=2
reboot
title Darik's Boot And Nuke v2.0 ~ Submenu
configfile /dban-Grub4dos.ini
title FreeDos
map --mem (hd0,0)//Images/freedos.img (fd0)
map --hook
chainloader (fd0)+1
rootnoverify (fd0)
title GOBACK Removal Tool
map --mem (hd0,0)//Images/goback.ima (fd0)
map --hook
chainloader (fd0)+1
rootnoverify (fd0)
title Memtest86 v3.5 (iso boot)
map (hd0,0)//Images/memtest.iso (hd32)
map --hook
chainloader (hd32)
boot
title NTFS-Dos
map --mem (hd0,0)//Images/ntfs4dos.img (fd0)
map --hook
chainloader (fd0)+1
rootnoverify (fd0)
title Launch "Windows(tm) Recovery Console"
fallback 1
find --set-root /cmdcons/setupldr.bin
chainloader /cmdcons/setupldr.bin
#####################################################################
# write string "cmdcons" to memory 0000:7C03 in 2 steps:
#####################################################################
# step 1. Write 4 chars "cmdc" at 0000:7C03
write 0x7C03 0x63646D63
# step 2. Write 3 chars "ons" and an ending null at 0000:7C07
write 0x7C07 0x00736E6F
savedefault --wait=2
Other random links I found:
Install WinNT and maybe more (Vista?) from USB key, also add grub/bartpe: http://www.911cd.net/forums//index.php?showtopic=20089
Multiboot with usb_multiboot_10.cmd: http://www.911cd.net/forums//index.php?showtopic=20089&st=11
More than 2GB key needs the HP usb disk storage option: http://tsukasa.jidder.de/blog/2009/07/29/short-notice-installing-grub4dos-on-usb-thumbdrives
Make boot on device bigger than 2GB (not FAT32): http://ubcd4win.com/forum/index.php?showtopic=9668 |