Recently I needed to install multiple ESX servers by CD, the CD’s kept getting lost and scratched, I wondered if there was a way to install from USB, surely this would be faster too.
I looked through the forums and found a couple of people that had managed it, I have amended there instructions slightly to get this working….
Requirements
You will need SYSLINUX, a Linux boot loader for removable media.
This can be downloaded here: http://www.kernel.org/pub/linux/utils/boot/syslinux/
These instructions are based on a Windows PC for my simplicity.
If you're a Linux guru (you know who I’m talking about!), then you can obviously do this under Linux. You'd need to know how to mount .ISO images in order to extract files, etc.
Steps Required
Throughout this example my USB hard drive was I: replace this with your letter.
1. Plug in your USB flash disk and format it in dos using the following command: FORMAT I: /FS:FAT
2. From Windows Explorer, find the boot.iso file in the /images directory on the ESX 3.x CD-ROM. Copy boot.iso into a temporary directory on your hard drive.
3. Using your ISO extraction or mount program, extract the contents of the boot.iso file to your USB flash drive.
4. Delete the isolinux.bin and updatecd.cfg files from the USB disk.
5. Rename the isolinux.cfg file on the USB flash disk to syslinux.cfg
6. Using WordPad (not Notepad), open the syslinux.cfg file and add the keyword usb to the end of every line that begins with append. Here's what the file should look like when you're done:
default esx
prompt 1
timeout 600
display boot.msg
F1 boot.msg
F7 snake.msg
label debug
kernel vmlinuz
append initrd=initrd.img noapic nomediacheck debug usb
label esx
kernel vmlinuz
append initrd=initrd.img usb
label text
kernel vmlinuz
append initrd=initrd.img text usb
label expert
kernel vmlinuz
append expert initrd=initrd.img usb
label ks
kernel vmlinuz
append ks initrd=initrd.img usb
label lowres
kernel vmlinuz
append initrd=initrd.img lowres usb
7. Extract the syslinux.zip file into another temporary directory on your hard drive.
8. Open up a command prompt and navigate into the win32 directory. For example:
C:\temp\syslinux-3.36\win32
9. Now, run the syslinux program to apply the boot loader and boot sector to the USB flash drive:
syslinux -s –ma I:
10. Copy the ESX 3.x ISO image onto the USB drive root
11. Confirm that your USB flash drive contains the following files:
boot.cat
boot.msg
initrd.img
snake.msg
splash.lss
vmlinuz
syslinux.cfg
esx-X.iso
12. Your ready to go, ensure your bios on the server you want to install too is setup to boot from USB or select USB from the alternate boot menu.
13. The ESX installer will detect the USB device and whatever SCSI / disk controllers you have. When the installer asks you what the installation source will be, choose Hard Disk.
14. You will need to choose the right disk device (ie. /dev/sda, /dev/sdb) that corresponds to your USB disk. Chances are it will be /dev/sdb.
15. Finally, the installer will ask you what directory to find the ESX installation CD image in. Just use / and it will find the .ISO image for you.
That’s everything, my servers managed to install in around 4 minutes which is not bad really! I have now modified my 4GB USB drive to include other tools like Knoppix and a dos boot disk all amendable from the main menu with not too much work. I might blog how to do these on another day.