Clonezilla guide

Wed, July 24, 2024 - 3 min read

Prepare

  1. Download clonezilla live (iso or zip file) from https://clonezilla.org/downloads.php or https://free.nchc.org.tw/clonezilla-live

  2. Following the instruction to create USB boot

Clone local disk to remote computer disk

  1. Boot from usb, choose 1st option

    Step 1

  2. Choose default or what you want in next 2 step

    Step 2.1

    Step 2.2

  3. Start clonezilla

    • Choose Start clonezilla to begin

      Step 3.1

    • Choose lite-server to clone from local source to remote

      Step 3.2

    • Choose lite-server -> start to clone from local source to remote

      Step 3.2

      Step 3.3

    • Choose netboot

      Step 3.4

      choose use-existing-dhcp > dhcp if these is existing dhcp server in network.

      choose start-new-dhcpd if there is no dhcp server, clonezilla will do itself

      Step 3.5

      Step 3.6

    • choose localdev if you want to read image file to local disk.

      choose skip if not (we choose skip now because we will clone from disk to disk later)

      Step 3.7

    • Choose Expert > massive-deployment

      Step 3.8

      Step 3.9

    • Choose from-image if previous step is localdev

      Choose from-device > disk-2-mdisks

      Step 3.10

      Step 3.11

    • Choose source disk to clone to remote computer

      Step 3.12

    • Choose options before start

      Step 3.13

      Step 3.14

    • Choose what to do when done

      Step 3.15

    • Choose multicast > clients+time-to-wait

      Step 3.16

      Step 3.17

    • Enter clients (number of clients will be clone)

      Step 3.18

    • Enter time-to-wait (waiting time befor start, even if clients is smaller than value in previous step)

      Step 3.19

    • Clonezilla will be run as server

      Step 3.20

  4. In remote computers

    • Boot from network (in the same network with clonezilla server)

      Step 4.1

    • All action will be automatically run, when done, the computers will do the action we choose before (reboot)

      Step 4.2

      Step 4.3

  5. Shutdown clonezilla server by enter y

    Step 5

Create clonezilla live

  1. After language and keyboard are selected, choose Start_Clonezilla -> device-image, then mount a working directory, the space should large enough to put the live CD and some temp files. It’s recommended to choose local*dev to mount local partition as */home/partimag_

    When Clonezilla live asks you to choose save or restore disk/partition, choose exit to enter command line prompt

  2. Run these command

    sudo -i
    
    # configure the network to update package
    ocs-live-netcfg
    
    apt-get purge drbl clonezilla
    apt-get update
    
    apt-get -y install drbl clonezilla
    
    apt-get -y install live-build
    
    cd /home/partimg
    
    # create debian iso template to create clonezilla in next step
    create-debian-live -d sid -i mt
    
    # create iso file
    ocs-iso -s -x quiet -j debian-live-for-ocs-mt.iso -i mt -k NONE -g en_US.UTF-8
    
    # create zip file
    ocs-live-dev -s -x quiet -j debian-live-for-ocs-mt.iso -i mt -k NONE -g en_US.UTF-8

Referrences:

ssh to clonezilla

  1. Run step 1 in Create clonezilla live

  2. Start ssh service in clonezilla

    sudo -i
    # configure the network
    ocs-live-netcfg
    
    # start service
    service ssh start
    service ssh status
  3. Connect from client

    # connect to clonezilla and enter password 'live'
    ssh user@[ip of clonezilla]
    
    # after connect run command
    sudo -i
    ...

Referrences: