PXE Boot¶
Overview¶
Morpheus includes a built in PXE Server to enable easy and rapid bare metal provisioning.
Prerequisites¶
- DHCP server with following config added to dhcpd.conf
allow booting;
allow bootp;
option option-128 code 128 = string;
option option-129 code 129 = text;
next-server morpheus-appliance-ip;
filename "pxelinux.0";
Note
Replace morpheus-appliance-ip
in the dhcpd.conf file with your Morpheus appliance IP address.
Internal Appliance URL (PXE)
set in Administration - Settings. For PXE-Boot your appliance needs to be routable directly with minimal NAT masquerading. This allows one to override the default appliance url endpoint for use by the PXE Server. If this is unset, the default appliance url will be used instead.- Mac or IP addresses of PXE target mapped in {morpheus} Infrastructure -> Boot - Mapping
- Target host configured for Network boot in BIOS
Note
On the Morpheus Appliance, PXE is enabled by default and port 69 is forwarded to the Internal PXE port 6969. These settings are configurable in in the pxe:
section of /opt/morpheus/conf/application.yml
.
Mapping¶
Add Mapping¶
Select the Mapping tab then click the Add Mapping button.
From the New Mapping Wizard input the following information:
- Match Pattern
Mac address separated by ‘:’ or an ip address filter
- Description(optional)
Description of the new mapping.
- Active
Flag to denote the mapping as active or disabled.
- Operating System
List of operating systems for the mapping.
- Boot Image
Lists available PXE boot images.
- Answer File
Lists available answer files.
- Cloud
Lists the available clouds.
- Server Mode
List of server modes:: unmanaged, Managed, Bare metal host, Container host, VM host, and Container & VM host.
Save
Once the mapping is added, and the target host is powered on, the {morpheus} PXE menu will load and PXE boot will start.
Edit Mapping¶
- Click the edit icon on the row of the mapping you wish to edit.
- Modify information as needed.
- Click the Save Changes button to save.
Delete Mapping
- Click the delete icon on the row of the mapping you wish to delete.
Answer Files¶
Answer files are like lists of answers for questions that you know the setup program is going to ask but the user is not prepared to answer. They contain one or more sections, and each section contains one or more properties in the form name=value. Morpheus provides Answer Files for ESXi, CentOS, Ubuntu and XenServer, and user can add their own.
Add Answer Files¶
Click the Infrastructure link in the navigation bar.
Click the Boot link in the sub navigation bar
Select the Answer Files tab then click the Add Answer File button.
From the New Answer File Wizard input the following information
- Name
Name of the answer file.
- Description(optional)
Description of the new answer file.
- Active
Flag to denote the mapping as active or disabled.
- Script Name
Name of the new answer file.
- Script Version
Version of the new answer file.
- Script
The script for the new answer file.
Save
Edit Answer File¶
- Click the Infrastructure link in the navigation bar.
- Click the Boot link in the sub navigation bar
- Select the Answer Files tab
- Click the edit icon on the row of the answer file you wish to edit.
- Modify information as needed.
- Save Changes
Delete Answer File¶
- Click the Infrastructure link in the navigation bar.
- Click the Boot link in the sub navigation bar
- Select the Answer Files tab.
- Click the delete icon on the row of the answer file you wish to delete.
Images¶
Morpheus provides Images for ESXi, CentOS, Ubuntu and XenServer, and user can add their own Images.
Add Images¶
Click the Infrastructure link in the navigation bar.
Click the Boot link in the sub navigation bar
Select the Images tab then click the Add Image button.
From the Upload Virtual Image Wizard input the following information
- Name
Name of the Image.
- Operating System
List of available operating systems.
- MENU
- Paste in PXE Menu
Example PXE 6.5.0 Menu:
Important
Ensure the case of file references match actual file names.
- Bucket
Select Bucket or File Share where PXE Image files exist
- Image Path
Path of the image relative to the selected Bucket or Storage Provider
Save Changes
Edit Image¶
- Click the Infrastructure link in the navigation bar.
- Click the Boot link in the sub navigation bar
- Select the Images tab
- Click the actions drop down and select edit.
- Modify information as needed.
- Click the Save Changes button to save.
Remove Image¶
- Click the Infrastructure link in the navigation bar.
- Click the Boot link in the sub navigation bar.
- Select the Image tab.
- Click the Actions drop and select Remove.
Adding ESXi 6.5 PXE Image¶
When adding a PXE Image for ESXi 6.5, a few requirements must be met for a successful PXE Boot.
- Image/iso must be expanded and added to a Bucket or File Share in Morpheus
- The ESXi
BOOT.CFG
needs to be edited to be PXE compatible: - The ESXiBOOT.CFG
uses lowercase file references, while the actual file names are CAPS. Change all file reference names to CAPS. - The ESXiBOOT.CFG
references empty files, which while cause PXE checksum failures, and the file references need to be removed. - The ESXiBOOT.CFG
has\
’s in front of all filenames that need to be removed
Create ESXi 6.5 PXE Image¶
Extract ESXi 6.5 iso file
Update
BOOT.CFG
file.- Delete
jumpstrt.gz
,useropts.gz
, andfeatures.gz
references. - These are blank by default and cause PXE checksum to fail - Change file references to ALL CAPS to match file names.
- Remove
/
’s in front of file references inBOOT.CFG
- example:sed -i 's/\///g' BOOT.CFG
Example updated BOOT.CFG
bootstate=0 title=Loading ESXi installer timeout=5 kernel=TBOOT.B00 kernelopt=runweasel MODULES=B.B00 --- K.B00 --- CHARDEVS.B00 --- A.B00 --- USER.B00 --- UC_INTEL.B00 --- UC_AMD.B00 --- SB.V00 --- S.V00 --- ATA_LIBA.V00 --- ATA_PATA.V00 --- ATA_PATA.V01 --- ATA_PATA.V02 --- ATA_PATA.V03 --- ATA_PATA.V04 --- ATA_PATA.V05 --- ATA_PATA.V06 --- ATA_PATA.V07 --- BLOCK_CC.V00 --- CHAR_RAN.V00 --- EHCI_EHC.V00 --- ELXNET.V00 --- HID_HID.V00 --- I40EN.V00 --- IGBN.V00 --- IMA_QLA4.V00 --- IPMI_IPM.V00 --- IPMI_IPM.V01 --- IPMI_IPM.V02 --- IXGBEN.V00 --- LPFC.V00 --- LSI_MR3.V00 --- LSI_MSGP.V00 --- LSI_MSGP.V01 --- MISC_CNI.V00 --- MISC_DRI.V00 --- MTIP32XX.V00 --- NE1000.V00 --- NENIC.V00 --- NET_BNX2.V00 --- NET_BNX2.V01 --- NET_CDC_.V00 --- NET_CNIC.V00 --- NET_E100.V00 --- NET_E100.V01 --- NET_ENIC.V00 --- NET_FCOE.V00 --- NET_FORC.V00 --- NET_IGB.V00 --- NET_IXGB.V00 --- NET_LIBF.V00 --- NET_MLX4.V00 --- NET_MLX4.V01 --- NET_NX_N.V00 --- NET_TG3.V00 --- NET_USBN.V00 --- NET_VMXN.V00 --- NHPSA.V00 --- NMLX4_CO.V00 --- NMLX4_EN.V00 --- NMLX4_RD.V00 --- NMLX5_CO.V00 --- NTG3.V00 --- NVME.V00 --- NVMXNET3.V00 --- OHCI_USB.V00 --- PVSCSI.V00 --- QEDENTV.V00 --- QFLE3.V00 --- QFLGE.V00 --- QLNATIVE.V00 --- SATA_AHC.V00 --- SATA_ATA.V00 --- SATA_SAT.V00 --- SATA_SAT.V01 --- SATA_SAT.V02 --- SATA_SAT.V03 --- SATA_SAT.V04 --- SCSI_AAC.V00 --- SCSI_ADP.V00 --- SCSI_AIC.V00 --- SCSI_BNX.V00 --- SCSI_BNX.V01 --- SCSI_FNI.V00 --- SCSI_HPS.V00 --- SCSI_IPS.V00 --- SCSI_ISC.V00 --- SCSI_LIB.V00 --- SCSI_MEG.V00 --- SCSI_MEG.V01 --- SCSI_MEG.V02 --- SCSI_MPT.V00 --- SCSI_MPT.V01 --- SCSI_MPT.V02 --- SCSI_QLA.V00 --- SHIM_ISC.V00 --- SHIM_ISC.V01 --- SHIM_LIB.V00 --- SHIM_LIB.V01 --- SHIM_LIB.V02 --- SHIM_LIB.V03 --- SHIM_LIB.V04 --- SHIM_LIB.V05 --- SHIM_VMK.V00 --- SHIM_VMK.V01 --- SHIM_VMK.V02 --- UHCI_USB.V00 --- USB_STOR.V00 --- USBCORE_.V00 --- VMKATA.V00 --- VMKPLEXE.V00 --- VMKUSB.V00 --- VMW_AHCI.V00 --- XHCI_XHC.V00 --- EMULEX_E.V00 --- WEASELIN.T00 --- ESX_DVFI.V00 --- ESX_UI.V00 --- LSU_HP_H.V00 --- LSU_LSI_.V00 --- LSU_LSI_.V01 --- LSU_LSI_.V02 --- LSU_LSI_.V03 --- NATIVE_M.V00 --- RSTE.V00 --- VMWARE_E.V00 --- VSAN.V00 --- VSANHEAL.V00 --- VSANMGMT.V00 --- TOOLS.T00 --- XORG.V00 --- IMGDB.TGZ --- IMGPAYLD.TGZ BUILD= updated=0
- Delete
Add expanded iso contents to Morpheus Bucket or File share.
The iso contents can be added to the bucket/file share form morpheus, or already exist in the bucket/file share.
Navigate to
Infrastructure -> Storage
Select Bucket or File Share Tab
Select target Bucket or File Share #. If a bucket or File Share does not exist, select + ADD to create one.
If the iso contents are already in the file share/bucket, skip to next step #. To add 6.5 iso contents, click + ADD and drag the expanded ESXi ISO folder to the upload modal #. One call files have been uploaded, select DONE
- Note the path to the ESXi 6.5 files, relative to the bucket/file share.
- For example, the screenshot below shows an iso expanded into a folder called
VMware-6.5.0
which was added topxe-images
folder insidemorpheus-ui local images
local file share. The path to the files from the file share is/pxe-images/VMware-6.5.0/
- For example, the screenshot below shows an iso expanded into a folder called
The Bucket or File Share and path to the iso files will be used when adding a PXE image.
Create PXE Image
Navigate to
Infrastructure -> Boot
Select Images tab
Select + ADD IMAGE
Populate the following:
- NAME
Name of the Image in Morpheus
- OPERATING SYSTEM
Select
esxi 6
- MINIMUM MEMORY
n/a leave default
0
- MENU
- Paste in PXE Menu
Example PXE 6.5.0 Menu:
Important
Ensure the case of file references match actual file names.
- BUCKET
Select the Bucket or File Share from step 2.3
- CLOUD-INIT USER DATA
N/A
- IMAGE PATH
Enter the path to the iso files relative to the Bucket or File Share, eg
/pxe-images/VMware-6.5.0/
- Select SAVE CHANGES
Your ESXi 6.5 PXE image is ready to be added to a mapping.