And as if installing and configuring a new *NIX environment is not time consuming enough, I decided to boot the installation image from PXE.
PXE utilizes TFTP and DHCP to serve the installation media over the network. Luckily, instead of installing separate packages of
dhcpd in your setup, dnsmasq offers the whole PXE-boot functionality in one seemingly clean package.
Start by downloading the Arch Linux image to the raspberry and mounting it:
As the case often is, there might already be a DHCP-server running in your intranet and you might not have root access to it. In this case, you can turn
dnsmasq to behave as a proxyDHCP, effectively only serving the PXE-specific information to the client. A typical configuration for PXE boot would look something like:
However, the default Arch Linux image has its boot configuration elsewhere than the
pxelinux.cfg, which PXE boot will automatically look for. This coupled with the obscure fact that
dhcp-option-force seems not to work when running proxyDHCP leaves no option but to manually configure the PXE-boot options of the image. One way of doing this is to just copy the contents of the image and modify them:
Finally, the root filesystem from the Arch image has to be transferred somehow. The options are HTTP, NFS and NBD. I opted for setting up a NFS share:
You need to also point the PXE/NFS -mount to that folder:
Now if you boot over PXE, you should eventually be awarded with a ‘Welcome to Arch Linux!’ message. Alternatively, you can debug/test the PXE boot with QEMU.