/homelab-ops:pxe-netbootfrom homelab-ops
Reliable remote OS install over PXE when virtual-media/KVM is broken — proxyDHCP+TFTP via dnsmasq, kernel/initrd over HTTP, custom iPXE with embedded autoexec. Use when a BMC's virtual CD is unreliable or a headless install needs netboot.
Ships in homelab-ops. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
When a server's out-of-band virtual-media path (iDRAC/iLO/BMC virtual CD) is broken or unreliable, and USB-boot keeps falling through to whatever OS is already on the internal disks, PXE is the install path that actually works. This is the concrete recipe — a temporary netboot service run from an existing healthy hypervisor on the same network.
Existing healthy host (same network segment as the target)
├── dnsmasq proxyDHCP + TFTP on that interface
│ → supplements the existing DHCP server with PXE-boot options only,
│ doesn't replace it
├── a plain HTTP server serving kernel + initrd + an answer/config file
└── a custom-built iPXE binary with an embedded autoexec script
Target chassis
├── BMC on its own management network — IPMI-over-LAN reachable
└── Primary NIC on the same segment as the netboot host — PXE-capable BIOS
Build (or reuse) an auto-install image with a per-node unattended-answer file baked in, then extract just the kernel and initrd from it — you don't need to serve the whole ISO, only the two boot artifacts plus the answer file:
mkdir -p /mnt/iso /srv/http/<target>
mount -o loop /path/to/auto-install.iso /mnt/iso
cp /mnt/iso/boot/<kernel> /mnt/iso/boot/<initrd> /srv/http/<target>/
cp <answer-file> /srv/http/<target>/answer.toml
umount /mnt/iso
Total per-node footprint is small — tens of megabytes, not the full ISO.
nohup setsid python3 -m http.server 8080 \
--bind <netboot-host-ip> --directory /srv/http \
</dev/null >/var/log/pxe-http.log 2>&1 &
A plain http.server is fine for a one-shot install; use nginx/caddy if this
becomes a standing service. Expect noisy BrokenPipeError log lines from
iPXE's range requests it later cancels — that's normal, not a fault.
systemd-run --unit=pxe-dnsmasq --description="PXE dnsmasq" \
/usr/sbin/dnsmasq --keep-in-foreground \
--bind-interfaces --interface=<netboot-iface> --except-interface=lo \
--no-resolv --no-hosts --port=0 \
--enable-tftp --tftp-root=/srv/tftp \
--dhcp-no-override --dhcp-range=<subnet-cidr>,proxy \
--dhcp-userclass=set:ipxe,iPXE \
--pxe-service=x86PC,"iPXE chain",undionly.kpxe \
--dhcp-boot=tag:ipxe,http://<netboot-host-ip>:8080/boot.ipxe \
--log-dhcp --log-queries --log-facility=/var/log/dnsmasq-pxe.log
Use systemd-run --unit=... rather than a backgrounded nohup — an
SSH-detached nohup & process gets reaped when the session ends; a transient
systemd unit survives detachment.
The distro-packaged undionly.kpxe binary does not auto-execute the
DHCP-offered chain URL by default. Iterating on the dnsmasq config won't fix
this — embed the boot script directly into the iPXE binary instead:
#!ipxe
dhcp || sleep 3 || dhcp || shell
iseq ${mac} <target-mac> && goto target || goto default
:target
kernel http://<netboot-host-ip>:8080/<target>/<kernel> <kernel-args>
initrd http://<netboot-host-ip>:8080/<target>/<initrd>
boot || shell
git clone --depth 1 https://github.com/ipxe/ipxe.git /tmp/ipxe-src
cd /tmp/ipxe-src/src
make -j4 bin/undionly.kpxe EMBED=/path/to/embed.ipxe
cp bin/undionly.kpxe /srv/tftp/undionly.kpxe
ipmitool -I lanplus -H <bmc-ip> -U <bmc-user> -P <bmc-password> \
chassis bootdev pxe options=persistent
ipmitool -I lanplus -H <bmc-ip> -U <bmc-user> -P <bmc-password> \
chassis power cycle
Typical timing: BIOS POST + PXE init ~90s; TFTP load of the small iPXE binary under 1s; iPXE's HTTP fetch of kernel+initrd ~10-30s; the actual installer running ~15-30 min depending on disk/package count.
ssh <netboot-host> 'tail -f /var/log/dnsmasq-pxe.log /var/log/pxe-http.log'
nc -zv -w 2 <target-ip> 22 # once the installer reboots into the new OS
ssh <target-ip> 'hostname'
If the installer fails partway through:
ipmitool -I lanplus -H <bmc-ip> -U <bmc-user> -P <bmc-password> \
chassis bootdev none options=persistent
ipmitool -I lanplus -H <bmc-ip> -U <bmc-user> -P <bmc-password> \
chassis power off
The disks are either freshly formatted (install reached the partition step) or still hold whatever was there before (install died earlier) — both are recoverable states; leave the host powered off for inspection rather than retrying blind.
What SKILL.md sets; muted values are Claude Code's defaults
9 skills in this plugin
/dell-idrac-bmc-opsBring a Dell PowerEdge BMC (iDRAC) onto the network headlessly, standardize settings, stage firmware, drive an unattended install — Redfish/racadm gotchas, identity-before-power, phantom-drive from stale firmware. Use bringing up/diagnosing a BMC./homelab-runbooksUse when powering on a sleeping DR node, converging DNS records for a new ingress vhost, or bringing up OpenBao/Terrakube JWT identity — homelab operational runbooks for power management, DNS, and secrets-engine bring-up./llm-router-opsOperate a self-hosted OpenAI-compatible LLM router — client-wiring per client, context-window ad gotcha, env-vs-persisted-config gotcha, why an unauth health probe should 401. Use wiring a client, adding a backend, diagnosing misbehavior./monitoring-firstRead system state from monitoring and close telemetry gaps./proxmox-cluster-opsOperate a Proxmox VE cluster safely — monitoring-first state checks, quorum-respecting node updates, and joining a new node. Use for cluster operations, rolling updates, or adding a node./terrakube-opsOperate self-hosted Terrakube (remote OpenTofu/Terraform plan/apply, state, locking) — login/plan/apply flow, gated targeted applies, lock recovery, offline-mirror gotcha, token rotation. Use for a plan/apply, stuck lock, new workspace.Other plugins' skills for the same job
npx claudepluginhub jacobpevans-ai/claude-code-plugins --plugin homelab-ops