Booting from USB

From WhitixDoc

Jump to: navigation, search

The latest trunk version of Whitix allows booting from a USB drive. However, since the process is not a one-click procedure yet, you'll need to do the following (Thanks to Kostadin for going through the guide and testing it):

  1. Figure out the drive's device name (usually /dev/sdb or similar)
  2. Format the disk (using fdisk or parted) to contain a FAT filesystem that spans the entire disk.
  3. Copy CdRoot/* from the Whitix source directory (you'll have to check out the Subversion trunk) to the disk's mount directory (usually /media/disk-2)
  4. Rename Boot to boot, and /boot/Grub to /boot/grub (the default GRUB build doesn't allow case-insensitive lookups)
  5. Install GRUB:
    1. Create a device.map like so: "echo "(hd0) /dev/sdb" > /media/disk-2/boot/grub/device.map"
    2. Install stage1: "sudo grub-install --root-directory=/media/disk-2 /dev/sdb"
    3. Edit boot/grub/menu.lst, change the kernel name to /boot/Kernel and add the USB modules (take a look in /System/Modules/Core, add pci, usb, then usb_uhci, usb_ehci, usb_hub and usb_storage as applicable).
    4. Change the root parameter to "root=UsbDisk0"

Test it. Do 'sudo qemu -hda /dev/sdb' to check that GRUB works. You should now have a bootable version of Whitix on a USB stick.

Personal tools