This is relatively straightforward to set up.
The DOS boot disks and the PXE environment both use loadlin.exe to load
the linux files.
The commandline:
loadlin linux.1 5 initrd=linux.2 root=/dev/ram rw PROXYADDR=x.x.x.x TFTPIP=x.x.x.x
is used to boot the linux environment.
So to do this from a USB pen drive, we need to be able to boot to DOS
and run loadlin.
Requirements
- A machine that supports booting from USB devices
- A USB pen drive
- Free DOS files:
http://www.fdos.org/bootdisks/
I downloaded the kernel.zip file from the "Creating your own
bootdisk" section of the page. You can use files from a win9x boot disk but I chose not to...
Util for formating USB pen drive (there may be others).- TFTP folder from ZENworks server.
How to Do It
First, back up everything on the pendrive that you might need again, as we are
going to format the drive.
- Extract the files from the HP download. (We will use the HPUSBFW.exe
util.) - Run this util.
- Select your USB device from the drop-down list.
- Select file system: FAT
- Then Format options:
- [x] Create a DOS Startup Disk
- [x] Using DOS system files located at:
<specify the location of your extracted freedos
files>
- Select Start, and it should format your drive.
- Next create an autoexec.bat at the root of the USB device.
All I've got in the file is:@echo off echo. echo. here goes... echo ... loadlin linux.1 5 initrd=linux.2 root=/dev/ram rw PROXYADDR=x.x.x.x TFTPIP=x.x.x.x ramdisk=0
Note: update x.x.x.x to match your imaging server's ip address.
- Next copy the loadlin.exe, linux.1 and linux.2 files into the root of
your USB device.
Now you are ready to test.
Plug USB device into USB port - power on machine - it should boot.
Note: you will need to check that your machine's bios allows booting from
USB devices and that you have set it higher in the boot order than your
HD. Otherwise it will boot from the local HD instead of the USB pen.
You should see linux loading in a similar way to a PXE boot.
If you want to mount the USB device try the following (it worked for
me!):
- img dg
This gave me the disk geometry and highlighted that there was a 0.2GB
FAT device on /dev/sda1 - my pen drive. - mount /dev/sda1 /mnt/jazzdrive
This mounted the device on /mnt/jazzdrive but you could use any of the
existing mount points or create your own, so you can copy files across, or even image to the device.
If you have any questions you may contact Jamie at jamie_glendinning@engl_NOSPAM_.co.uk, after removing NOSPAM from the address.