I am looking to do PXE booting of the ESXi installer as the first step in rolling out my new automated deployment solution. We already have an Altiris (HP RDP) PXE server in house for Windows deployments so I needed to figure out a way to make it work. Below is the first phase of this using standard pxelinux and not gPXE.
- Download the ESXi 4.1 installable release from VMware
- Download the current 3.x branch of syslinux
- Create a folder esxi_41_pxe to contain our custom boot files.
- Copy core\pxelinux.0 from the syslinux release into esxi_41_pxe
- Copy the following files from the ESXi 4.1 release into esxi_41_pxe: cim.vgz, ienviron.vgz, install.vgz, mboot.c32, menu.c32, sys.vgz, vmkboot.gz, vmkernel.gz
- Create a directory pxelinux.cfg
- Create a text file esi_41_pxe\pxelinux.cfg\default with the following contents
menu title VMware VMvisor Boot Menu
append vmkboot.gz ks=<ks path> --- vmkernel.gz --- sys.vgz --- cim.vgz --- ienviron.vgz --- install.vgz
In the Altirs PXE Configuration Utility Create a New Boot Menu Option with a meaningful name such as ESXi 4_1
Select Linux x64 for the OS & Processor Option
Under Image Creation Method select User Supplied
Click the Manual Boot Image Option and browse to the location of the esxi_41_pxe folder created in step 3 and click Ok
Make a note of the Final Location on PXE Server field at the bottom of the Window. It should be something like …\PXE\Images\MenuOption163
Click Ok twice to exit the PXE Configuration Utility
Navigate to the Altiris Express program directory. A default installation of Altiris will be in C:\Program Files\Altiris\eXpress\Deployment Server.
Now go into the directory containing the PXE files for our custom boot image. The path was noted in step 5.
Go into the X64 folder.
Rename MenuOption.0 to MenuOption.0.orig
Rename pxelinux.0 to MenuOption.0
PXE boot a test system using the new menu option
At this point all of your system builds use the same kickstart file. That may be ok if you do all of your customization after the initial build, but it leaves me wanting more to match my current ESX build strategy.
There are at least two strategies that I can see for injecting some per server customization into this process.
- Instead of using the pxelinux.cfg/default file use a per server file based upon MAC address. Check out the PXELINUX docs for more information on this approach.
- Use %pre and %post scripts in the kickstart and have them query a central authority to determine what configuration scripts should be downloaded based upon some unique attribute available to the setup environment.
There is clearly more work for me to do 🙂
Problem: You receive “not a com32r image” on booting
Solution: Use pxelinux.0 from the 3.x release of syslinux not 4.x