• I had been using Clonezilla for some time. I was going to try out FOG and it seems far more complicated to setup in an existing PXE environment. So recently I learned for Clonezilla how to setup a UEFI PXE environment (been using bios version for 10+ years) and have my machines load Grub via PXE and have a selection of options: Ubuntu install, Fedora Install, and Clonezilla. I would like to add FOG to my list of options to boot. Clonezilla I have mount an SMB shared location from my file server as a place to land images. I’d like to setup a similar setup for FOG. For the Ubuntu install, Fedora Install, and Clonezilla I have a simple Ubuntu vm setup as a tftp and web server that serve the needed files. I have the typical /tftpboot location reshared via web http://tftp/tftp on that same server (I named the server tftp) I created another vm server for fog and it looks like a very complicated install vs clonezilla. Looks like it uses ipxe as it’s pxe boot loader which the config looks like pxelinux’s that I have used for bios PXE boot. After installing FOG on it’s own server I was thinking I could probably try installing it on my tftp server and add a line to grub.cfg to try it out.
    I’d rather use grub than ipxe
    I’ll need to convert

    LABEL fog
    kernel ipxe.krn dhcp && chain http://${next-server}/fog/service/ipxe/boot.php?mac=${net0/mac}

    to a grub config.
    next-server I can replace with the ip and I can figure out how to get the mac in grub.

    Just curious if anyone has any recommendations for a multiboot pxe environment?

    Would it be easier to use ipxe as the default boot loader how to convert the following grub lines to ipxe?

    menuentry "Clonezilla-live 2019-09-03 x64"{
      linux /cz190903.x64/live/vmlinuz video=800x600 boot=live union=overlay username=user hostname=clonezilla ocs_live_run="ocs-live-general" ocs_live_extra_param="" ocs_live_batch="no" locales=en_US.UTF-8 keyboard-layouts=NONE toram=filesystem.squashfs fetch=http://tftp/tftp/cz190903.x64/live/filesystem.squashfs
      initrd /cz190903.x64/live/initrd.img
    menuentry "Ubuntu-18.04"{
      linux /u18.04.x64/linux vga=788 --- quiet
      initrd /u18.04.x64/initrd.gz
    menuentry "Install Fedora 30 64-bit"{
      linux /f30/vmlinuz inst.stage2=http://download.fedoraproject.org/pub/fedora/linux/releases/30/Workstation/x86_64/os/ edd=off ip=dhcp
      initrd /f30/initrd.img

    in the above the kernel and initrd are transferred over tftp but would also be accessible via http://tftp/tftp/<same path as tftp>

    I also have bios boot using pxelinux.0 and similar lines in it’s config.

    Does ipxe work in both bios and UEFI?

  • Moderator

    (warninig this will be a bit biased since you are asking on a FOG forum) Truthfully setting up FOG is pretty easy and is a solid foundation for pxe booting, even multi pxe booting. iPXE is a superior network booting environment as compared to syslinux or grub. With iPXE you can transfer the boot image via http, https, nfs, tftp, and sanboot.

    In regards to converting your grub menus to iPXE, i have a tutorial on using FOG as a netboot server: https://forums.fogproject.org/topic/10944/using-fog-to-pxe-boot-into-your-favorite-installer-images

    In regards to uefi vs bios, you need the proper bootloader for bios and uefi respectively. This is the same requriement for whatever boot loader you use. For FOG the default one for bios is undionly.kpxe for uefi is ipxe.efi. Most uefi boot loaders end in a .efi extension. For bios/ufei coexistence we have a wiki page for setting up your dhcp server (Win2012 and newer, or linux) so dynamically provide the proper bootloader based on the target computer: https://wiki.fogproject.org/wiki/index.php/BIOS_and_UEFI_Co-Existence If you have a soho or router dhcp server that doesn’t support dynamic boot files then you can always install dnsmasq on your fog server to supply the dynamic boot loader. Understand that fog and clonezilla are built on opensouce stack so these tutorials above can be reused for other applications (dnsmasq is dnsmasq, tftp is tftp and so on)