Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 5 You must be signed in to fork a gist
  • Save joelio/81acc4f07725a5aba2bcb7620071bce7 to your computer and use it in GitHub Desktop.
Save joelio/81acc4f07725a5aba2bcb7620071bce7 to your computer and use it in GitHub Desktop.
Ubuntu 16.04 netboot installer via iPXE
#!ipxe
dhcp net0
# Figure out if client is 64-bit capable
cpuid --ext 29 && set arch x64 || set arch x86
echo Starting Ubuntu Xenial installer for ${mac}
set mirror http://archive.ubuntu.com
set release xenial
set base-url ${mirror}/ubuntu/dists/${release}/main/installer-${arch}/current/images/netboot/ubuntu-installer/${arch}
kernel ${base-url}/linux
initrd ${base-url}/initrd.gz
#imgargs linux auto=true url=http://yourserver/some/path/preseed.cfg
boot || goto failed
:failed
# If everything failed, give the user some options
echo Boot from ${base-url} failed
prompt --key 0x197e --timeout 2000 Press F12 to investigate || exit
shell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment