Skip to content

How to Set Up PXE Discovery in DRP

This guide walks you through configuring Digital Rebar Platform (DRP) to automatically discover machines through PXE boot.

Prerequisites

  • DRP server installed and running
  • Administrative access to DRP (UI or CLI)
  • Machines connected to a network where DRP can serve DHCP

Configuring a Subnet for PXE Discovery

Option 1: Using the DRP UI

  1. Navigate to the Networking section in the navigation bar
  2. Select the Subnets option
  3. Click the Create button
  4. Complete the subnet form with your network details:
  5. Name: Provide a descriptive name (e.g., "lab-network")
  6. Subnet: Enter your subnet CIDR (e.g., "192.168.122.0/24")
  7. ActiveStart/ActiveEnd: Define the DHCP range (e.g., "192.168.122.10" to "192.168.122.254")
  8. Options: Add required DHCP options (router, DNS, etc.)
  9. Click Save to create the subnet

Option 2: Using the DRP CLI

  1. Create a JSON file with your subnet configuration:
cat > /tmp/example_subnet.json << 'EOF'
{
  "ActiveEnd": "192.168.122.254",
  "ActiveLeaseTime": 3600,
  "ActiveStart": "192.168.122.10",
  "Enabled": true,
  "Meta": {
    "icon": "cloud",
    "color": "black",
    "title": "User added"
  },
  "Name": "example-subnet",
  "OnlyReservations": false,
  "Options": [
    {
      "Code": 3,
      "Value": "192.168.122.1"
    },
    {
      "Code": 6,
      "Value": "192.168.122.143"
    },
    {
      "Code": 15,
      "Value": "test.example.com"
    }
  ],
  "Pickers": [
    "hint",
    "nextFree",
    "mostExpired"
  ],
  "Proxy": false,
  "ReservedLeaseTime": 21600,
  "Strategy": "MAC",
  "Subnet": "192.168.122.0/24",
  "Unmanaged": false
}
EOF
  1. Create the subnet in DRP:
drpcli subnets create - < /tmp/example_subnet.json

Configuring Boot Preferences

Skip this step if you installed DRP with the --universal flag.

  1. Set the necessary preferences to enable discovery:
drpcli prefs set unknownBootEnv discovery defaultBootEnv sledgehammer defaultStage discover

This command configures DRP to:

  • Boot unknown machines into the discovery environment
  • Use Sledgehammer as the default boot environment
  • Apply the "discover" stage to new machines

Testing Your Configuration

  1. Connect a machine to the network where DRP is serving DHCP
  2. Configure the machine to PXE boot (usually through BIOS/UEFI settings)
  3. Start or restart the machine
  4. Verify the machine appears in DRP:
  5. Check the DRP UI under Machines
  6. Or use CLI: drpcli machines list | jq

Troubleshooting

If machines aren't being discovered:

  1. Verify network connectivity between DRP and target machines
  2. Check that the subnet configuration matches your network
  3. Ensure the machine is set to PXE boot by examining the server's configuration and console
  4. Review DRP logs for DHCP or PXE boot errors:
drpcli logs get

Next Steps

After successful discovery, you can:

  • Classify discovered machines
  • Create workflows to provision the machines
  • Configure machine parameters for customized deployment

UEFI HTTP Boot as an Alternative to PXE Boot

For modern systems that support HTTP Boot (a UEFI extension):

  1. Access the UEFI firmware settings during system startup
  2. Navigate to the boot options section
  3. Enable "HTTP Boot" or "UEFI HTTP Boot" option
  4. Set the URL to https://$RS_ENDPOINT:8092/ipxe.efi
  5. Ensure HTTP Boot appears in the boot order before local drives