Boot Disk Create USB

Main.SideBar

FreeDOS Sections (components)

PmWiki

Boot Disk Create USB

Using Makebootfat on Linux

  • Download makebootfat (version 1.4 at the time of this writing) and compile it using
 tar -xvf makebootfat-1.4.tar.gz
  cd makebootfat-1.4
  ./configure
  make
  • Optionally you can install it
  make install
  • Install the syslinux Debian package (or download and build it from source)
  • If you do not already have a FreeDOS CD with sources, fetch the following 1.0 boot files: www.ibiblio.org/pub/micro/pc-stuff/freedos/files/distributions/1.0/pkgs/ kernels.zip commandx.zip and unstablx.zip
  • To get updated FreeDOS almost-1.1 files instead: the rugxulo.googlepages.com homepage has boot diskette images, zips with boot diskette files and zips with kernel updates including sources.
  • Copy command.com and kernel.sys to /tmp/fs-root
  • Copy fat12.bin, fat16.bin and fat32lba.bin from kernels.zip to /tmp
  • Copy mbr.bin of your syslinux from /usr/lib/syslinux/mbr.bin to /tmp

  • Write the boot logic (that we just extracted to the tmp directory) to the stick
 sudo /<path to makebootfat>/makebootfat -o /dev/<usb device> -E 255 -1 fat12.bin -2 fat16.bin -3 fat32lba.bin -m mbr.bin /tmp/fs-root

Note that this will use the MBR that comes with syslinux and the FAT boot sectors (along with all files in /tmp/fs-root, ie the kernel and shell) that come with FreeDOS, so command.com and kernel.sys will be loaded during bootup.

these instructions taken from here but adapted to avoid the tedious extraction of outdated 1.0 files from fdbasews.iso...(approve sites)

Using sys-freedos-linux on Linux

Get www.ibiblio.org/pub/micro/pc-stuff/freedos/files/dos/sys/sys-freedos-linux/ and follow the included instructions to add a DOS boot sector to your stick. You may also have to use a partition edit tool (fdisk or whatever nicer tool your Linux has) to mark the FAT partition of your stick as bootable. If your stick is NTFS-formatted, you first have to replace the NTFS partition by a FAT partition (only affects very new sticks). After adding a DOS boot sector, add the DOS files, at least kernel.sys and command.com, for example the versions from the first RUFFIDEA boot diskette on the rugxulo.googlepages.com homepage :-).

Using HP's USB Disk Storage Format Tool on Windows

  • Get an \"ODIN\" FreeDOS diskette image. I used the 2880KB disk of the Beta 9 Service Release 2.
  • Use WinImage to mount the ODIN disk image and copy the files to a directory.
  • Download and install HP's USB Disk Storage Format Tool(approve sites)
  • Using the USB Disk Storage Format Tool, format your USB flash drive in FAT format. Tell it that you want to make a boot disk and point it at the directory of FreeDOS files you got off of the ODIN image.

these instructions taken from here

Using makebootfat on Windows

see: http://www.bensbits.com/2007/08/21/booting_dos_from_a_usb_flash_drive(approve sites)

UNetbootin

 see: http://www.artiss.co.uk/2009/02/acer-aspire-one-bios(approve sites)

and see: http://unetbootin.sourceforge.net/(approve sites)

Using balder10 and qemu under Linux

Prerequisites:

  • Utility dd
  • Utility qemu
  • Dos-Floppy-Image, e.g. balder10.img http://www.finnix.org/files/balder10.img(approve sites)

Procedure (assumptions for this description: balder10.img is in CWD, stick appears as /dev/sdc)

  • Insert memory stick (Caution: all data on this stick will be destroyed)
  • Find out device name (e.g. /dev/sdc)
  • Make sure, it is unmounted (check with 'mount' command)
  • Issue 'dd if=/dev/zero of=/dev/sdc bs=1012 count=2' (This clears the MBR)
  • Boot qemu: 'qemu -boot a -fda ./balder10.img -hda /dev/sdc'
  • Answer all question with their default values
  • At the A:\> prompt: fdisk (create a bootable, primary DOS partition)
  • Stop qemu
  • Remove memory stick and re-insert it.
  • Make sure, it is still /dev/sdc, otherwise use new name in the next steps.
  • Make sure, it ist unmounted again.
  • Boot qemu again: 'qemu -boot a -fda ./balder10.img -hda /dev/sdc'
  • At the A:\> prompt: FORMAT C: /S
  • At the A:\> prompt: XCOPY A: C: /N /E
  • Stop qemu

Done! Now you can mount the stick again and copy any required utilities on it ...

Using CD-ROM

Burn an iso image (fdbasecd.iso will do). Plug in pendrive, boot computer from the CD. Install system on the pendrive like an ordinary hard disk drive.

Using memdisk from syslinux on linux

This method will get you booted up inside a "phony" freedos bootdisk which is actually just an image on the drive you intent to install freedos to. Good as a last resort where installing freedos FROM freedos is the only way it will work and everything else has failed. This works because the "floppy" is in memory and allows you to work on the disks without taking the system out from under you.

  • install syslinux (i.e. emerge syslinux on Gentoo)
  • download freedos floppy image as well as distribution CD
  • insert the syslinux MBR (i.e. dd if=/usr/share/syslinux/mbr.bin of=/dev/${disk})
  • partition the drive and create drive C: (i.e. cfdisk /dev/${disk} && hdparm -z ${disk} && mkfs.vfat ${disk})
  • insert the syslinux partition boot code: (i.e. syslinux /dev/${disk})
  • mount partition and copy memdisk + dos floppy image to partition (i.e. mount /dev/${disk} && cp /usr/share/syslinux/memdisk /mnt/${disk} && cp /path/to/fdboot.img /mnt/${disk}
  • mount the partition and create a syslinux.cfg file as follows:
    LABEL DOSMEMDISK
    LINUX memdisk
    INITRD fdboot.img
    APPEND floppy
  • mount the distribution iso cd and floppy image using loopback (i.e. mount -o loop /path/to/fd*ws.iso /mnt/fdisoloop && mount -o loop /mnt/${disk}/fdboot.img /mnt/fdbootloop
  • extract the sysx, formatx, and fdiskx packages to the floppy image (i.e. for PackageName? in sys fdisk format; do unzip -L -o /mnt/fdisoloop/freedos/packages/base/${PackageName}x.zip -d /tmp/freedos; done && cp /tmp/freedos/bin/* mnt/fdbootloop/bin)
  • unmount the loopbacks in the previous step (i.e. umount /mnt/fd{iso,boot}loop) and the partition (i.e. umount /mnt/${disk})
  • boot the disk on the target machine, if syslinux complains about a missing kernel enter \"DOSMEMDISK\". You can press tab to confirm the name.
  • Once in the freedos command-line do:
    a:
    cd bin
    fdisk (say yes to fat32 support and then delete the c: drive using the fdisk TUI - DO NOT REBOOT!)
    fdisk (say yes to fat32 support and then recreate the c: drive using the fdisk TUI - DO NOT REBOOT!)
    format c: (DO NOT REBOOT!)
    sys c: (REBOOT!)

You can then put the disk back in the machine with your distribution cd to mount the new C: drive and install all your desired packages.

Using Clonezilla

Clonezilla is a disk imaging linux distribution that uses syslinux and includes FreeDOS for ease of BIOS flashing. It's very easy to install.

Download clonezilla from clonezilla.org. Format the pendrive FAT32 and copy all the files onto the root of the pen. From Windows open cmd.exe and change to utils/win32 and run makeboot.bat. From Linux terminal cd to utils/linux and run makeboot.sh.

Boot the pen and select FreeDOS. If you only want FreeDOS and not clonezilla, edit syslinux/syslinux.cfg so that it's the only menu option and delete the excess files.

Proof of Concept - 2GB USB Boot Image Link

Available on the sample bootdisks page.

< CD-ROM | Installation Overview | Customize >

Recent Changes (All) | Edit SideBar Page last modified on March 16, 2010, at 04:49 PM Edit Page | Page History
Powered by PmWiki