Clonezilla

The Free and Open Source Software for Disk Imaging and Cloning
Step-by-step docs

Clonezilla Live on PXE Server

Besides Clonezilla Live CD and Live USB, Clonezilla Live can be put on a PXE server so that a client can be booted via network to use Clonezilla live. This is how:

  1. Prepare a PXE server. You may refer to some doc, e.g. this one or DRBL (Diskless Remote Boot in Linux). We assume the pxelinux config file is /tftpboot/nbi_img/pxelinux.cfg/default, and the image files are in /tftpboot/nbi_img/.
  2. Download Clonezilla live zip file (You have to use Clonezilla live 1.2.0-25 or later), and unzip the required files (vmlinuz, initrd.img, and filesystem.squashfs in dir live) to /tftpboot/nbi_img/. You can make it by something like: "unzip -j clonezilla-live-*.zip live/vmlinuz live/initrd.img live/filesystem.squashfs -d /tftpboot/nbi_img/" (Replace clonezilla-live-*.zip with the file name you just downloaded).
  3. Edit your PXElinux config file /tftpboot/nbi_img/pxelinux.cfg/default, and append the following:
    -----------
    label Clonezilla-live
    MENU LABEL Clonezilla Live (Ramdisk)
    KERNEL vmlinuz
    APPEND initrd=initrd.img boot=live username=user union=overlay config components quiet noswap edd=on nomodeset nodmraid locales= keyboard-layouts= ocs_live_run="ocs-live-general" ocs_live_extra_param="" ocs_live_batch=no net.ifnames=0 nosplash noprompt fetch=tftp://$serverIP/filesystem.squashfs
    -----------
    //NOTE//:
    1. Replace $serverIP with your IP address of tftp (DRBL) server.
    2. Remember to check kernel, initrd file names and boot parameters in syslinux/syslinux.cfg from the zip file, copy them to here. It might be different from here, say vmlinuz path maybe different.
      For more info about pxelinux, you can refere to here.
    3. Here we do not put "ip=frommedia" in the boot parameters because the /etc/resolv.conf get in live-initramfs won't exist in the system after initramfs is done.
    4. "fetch" also supports http or ftp, if you want to use http or ftp instead of tftp, you have to put the file filesystem.squashfs in your http or ftp server and the corresponding path.
    5. If you want to do unattended clone, you can assign clonezilla live parameters (ocs_live_run, ocs_live_extra_param, keyboard-layouts, locales, and ocs_live_batch) in kernel parameters. For example, you can use:
      ------------------------------------------------------
      append initrd=initrd.img boot=live username=user union=overlay components noswap noprompt vga=788 keyboard-layouts=us locales=en_US.UTF-8 fetch=tftp://$serverIP/filesystem.squashfs
      ------------------------------------------------------
      in the above example to assign your PXE client to use default keymap (US) and English environment. For more info about those parameters, you can refer to this Clonezilla live doc.