This is an example script of how to host VDI / VMDK (VirtualBox images) directly over PXE (Network boot).
Example relies on LTSP.
Can be any distro, but requires ltsp-client-core, example with Debian:
sudo apt-get -y install ltsp-client-core
sudo /usr/share/ltsp/update-kernel
If testing/building with VirtualBox remember to properly shutdown the machine (shutdown -h now
).
If you want DHCP from a second interface, this should do the trick upon boot inside the PXE client:
sudo ip route del default
sudo ip link set up dev enp0s3
sudo dhclient enp0s3
Run the install.sh-file on a Debian (tested on 9) box, VirtualBox should work fine. enp0s8 is the second interface on my vbox test, you probably have to change this. Both server and client supports multiple interfaces.