I was wondering if it was possible to make a PXE bootable image from a dos utility firmware. For some specifics the firmware updater is usually to be installed on a USB stick. I have all the flat files. Should I be fine just dumping the flat files on my tftpboot server and then just adding in the proper bits for the pxemenu or is the process a bit more involved?

I found FreeDOS but they do not supply a bigger image than 1.44MB which is an issue because the firmware rom alone is 5MB in size. I tried creating a larger image using these steps but have not had any success as each time I go to boot into the image it does not display the usual FreeDOS menu (it only prints out FreeDOS and gives no command prompt).

EDIT: I was able to get the rom running off the FreeDOS image from here but of course when running the rom it says that the rom is corrupted because the entire rom is not actually on there and is only partially there due to there being only 1.44MB of space on the image. To further complicate things the rom will only run when himem.exe and emm386.exe are running (they are started by selecting the second option on FreeDOS).

EDIT2: I finally got the USB stick to work after adding the flat files to the stick and the COMMAND.COM from a custom freedos usb stick I found. Still with copying the files to a USB image and trying to boot from PXE it refuses to boot.

  • Do you want my working image that I created like described below? – mailq Aug 5 '11 at 23:05
  • Would be helpful in trying to test this out before I go out and just buy a handful of usb sticks to update our 900 machines. – Wilshire Aug 6 '11 at 1:39
  • The image file is located at ubuntuone.com/p/18gb – mailq Aug 6 '11 at 8:04

You can see a step-by-step tutorial here: http://www.smop.co.uk/mediawiki/index.php/PXE_booting_floppy_images

Or try to search for "boot ISO via PXE", "boot DOS via PXE", etc.

Extended edit

The following is tested and working.

All you need is the Full FreeDOS ISO, a recent Linux LiveCD, an installed Linux and a Virtual Machine.

Then this is what I did:

  1. Create a virtual machine with a harddisk of only 20 MB size, also attach the Full FreeDOS ISO as a CD-ROM.
  2. Boot the virtual machine from the FreeDOS ISO and install the minimal version of FreeDOS on the virtual harddisk.
  3. Make sure that you partition and format the harddisk with the provided FreeDOS tools during install. The disk should be bootable and formatted as FAT16.
  4. Eject the ISO image and try to boot from the virtual harddisk. Repeat the steps until it successfully boots into the virtual harddisk. For me it only works with 3rd FreeDOS boot option, but you should try all of them.
  5. Attach the Linux LiveCD to the virtual Machine and boot the LiveCD. Then mount the virtual harddisk somewhere in the filesystem.
  6. Transfer the needed DOS tools onto the mounted harddisk. Either via HTTP, SCP, FTP, SMB or even via a real USB flashdrive. It is not necessary but recommended to create a subfolder of the virtual harddisk and put the files in it. You should have extracted the files externally or within the Linux LiveCD system. Make sure that you do not overwrite any FreeDOS files on the harddisk.
  7. Unmount the virtual harddisk.
  8. Create a disk image of the virtual harddisk with dd if=/dev/sda of=/tmp/freedos.img (replace /dev/sda with the correct device name of the virtual harddisk)
  9. Transfer the image /tmp/freedos.img to a real machine (SCP, SMB, FTP or whatever).
  10. Shutdown the Linux LiveCD system, eject the LiveCD image, reboot and try to boot back into the FreeDOS harddisk (not the image).
    If it works and you see the copied programs everything is fine and you can shutdown the system again. If not, repeat from step 5).
  11. If you have an installed Linux somewhere, then try to install the syslinux package. This is easier then compiling your own binaries or download precompiled images from somewhere.
    After the install locate the memdisk binary in the filesystem. Mine was at /usr/lib/syslinux/memdisk.
  12. Transfer memdisk and freedos.img to the tftp server of your PXE environment and configure it with the following configuration entry.


label freedos
menu label FreeDOS flash environment 
kernel memdisk
append initrd=freedos.img harddisk

Boot via PXE and enjoy FreeDOS from network.

As an exercise for the reader you should try iPXE which is an Open Source PXE firmware. With it you can skip all the tftp/PXE crap and instead boot via HTTP! In this case you can boot from the iPXE boot loader and enter the following commands:

chain harddisk

dhcp gives you any IP from your DHCP server just to communicate with or whatever your (internal) webserver is. You could also set a static IP instead. The other commands download and install the bootloader and the disk image from HTTP and then boot the image. Impressive.

  • And it gets even better. I just figured out that you can even have a gziped image to boot via iPXE. – mailq Aug 6 '11 at 8:05
  • very good comment about using ipxe instead of the more conventional tftp method... – Andre de Miranda May 21 '16 at 5:58
  • Also note that if you are using VirtualBox you can use "VBoxManage internalcommands converttoraw" instead of dd – Andre de Miranda May 21 '16 at 11:27

You can use memdisk to do boot disk images (e.g. from a floppy disk or hard drive) or iso images. For example, here is my PXE configuration for booting DBAN.

label dban
menu label Wipe hard drive 
kernel memdisk
append initrd=dban/dban.img floppy

This is enough to work with some vendors update tools. However, it looks like the firmware update is not distributed as an image, but as a number of files.


What I would try to do is use the HPQUSB.exe utility to prepare a USB key, make an image of the USB key, then boot that image using memdisk.

  • funnily enough the HPQUSB.exe utilty just copies in an IBMDOS program that is only 21k large and then continues to copy all files from the spxxxxx.exe directory until the stick is full. So trying that route is a bust since HP is incapable of making a proper USB drive program. – Wilshire Aug 5 '11 at 1:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.