Clonezilla Pointers

From Physiki
Jump to: navigation, search

The complete tablet install guide is located at the Imaging Guide.

Steps to DRBL/Clonezilla

Somewhat patchy original documentation at http://www.clonezilla.org/clonezilla-server-edition/ and http://drbl.sourceforge.net/


Contents

Import the repo key to your keyring

wget http://drbl.nchc.org.tw/GPG-KEY-DRBL; sudo apt-key add GPG-KEY-DRBL

Edit sources.list

Add the following to your /etc/apt/sources.list

(This should also work if you add a file in /etc/apt/sources.list.d/, then apt-get update) This repo is the only one with the DRBL package, but it's really slow. Consider downloading the .deb from SourceForge (http://drbl.sourceforge.net/download/sourceforge/) and installing it locally. “sudo apt install XYZ.deb” is the command, I believe. Otherwise apt-get update && apt-get install drbl

Install DRBL, step 1

There are two commands you use to install and activate CloneZilla. The first is /opt/drbl/sbin/drblsrv -i . Note: There is a space before the "-i". The first time you run it, this will also connect to the Intarweb and download a bunch of packages. The default options are all the way down. We don't want to install packages for “Diskless Linux”, as we don't run any thin clients. Other than that, the questions are pretty straightforward.

Install DRBL, step 2

Run /opt/drbl/sbin/drblpush -i - This sets up your client configuration. Make sure you have two network interfaces up when you run this command – it will detect one as “Internet” and one as “private”. It is sufficient to set your eth0 in Network Manager to 192.168.0.1, following Nick's directions. If this command doesn't detect two interfaces, the clients won't get a DHCP lease. Don't bother to configure your clients – letting the range in dhcp.conf control leases is fine. It warns you about this, but we don't care. The default options are again mostly acceptable. We want “no diskless Linux” and “Clonezilla box”. Some options give information about “increased requirements on server for more clients”. These options are never what we want – we don't care about persistent client configuration.

Put the following in /etc/drbl/drblpush.conf:

#Setup for general
[general]
domain=drbl.sf.net
nisdomain=penguinzilla
localswapfile=no
client_init=text
login_gdm_opt=
timed_login_time=
maxswapsize=
ocs_img_repo_dir=/home/partimag
total_client_no=37
create_account=
account_passwd_length=8
hostname=tablet-clone
purge_client=no
client_autologin_passwd=
client_root_passwd=
client_pxelinux_passwd=
set_client_system_select=yes
use_graphic_pxelinux_menu=yes
set_DBN_client_audio_plugdev=no
open_thin_client_option=no
client_system_boot_timeout=50
language=en_US.UTF-8
set_client_public_ip_opt=no
config_file=drblpush.conf
collect_mac=no
clonezilla_mode=clonezilla_box_mode
drbl_mode=none
drbl_server_as_NAT_server=no
add_start_drbl_services_after_cfg=yes

#Setup for eth0
[eth0]
interface=eth0
range=3-27

and run /opt/drbl/sbin/drblpush -c /etc/drbl/drblpush.conf to use this config.

Get image from source tablet

Now run /opt/drbl/sbin/dcs to set the mode. Primarily pay attention to “clonezilla-start” and “clonezilla-stop”, then “clonezilla-save-disk” or “clonezilla-restore-disk”. Note that the defaults include no graphical boot screen – this is nice to have, so change this option. Also, choose whether you want to set the image name now or later. “Now” is fine. Your first task is to receive an image, so select that option. Netboot your master, and follow the instructions.

  • Step 1 (Get image) command

/opt/drbl/sbin/drbl-ocs -b -q -c -rm-win-swap-hib -p true -z3 -l en_US.UTF-8 startdisk save 2008-08-23-15-img sda

  • Step 2 (Send Image) command

/opt/drbl/sbin/drbl-ocs -b -g auto -x -v -r -p choose --clients-to-wait 39 --max-time-to-wait 600 -l en_US.UTF-8 startdisk multicast_restore 2008-08-23-15-img sda

Broadcast image

After you receive the image, you have to put it back out to the others. Rerun /opt/drbl/sbin/dcs, selecting “clonezilla-start” and “clonezilla-restore-disk”. When you are broadcasting an image, you have two options. You can wait for a certain amount of time or a certain number of clients. I suggest the “number of clients” option, as it should prevent the problem we've experienced with our dd/udpcast script of missing one client and having to reboot all the clients.

Da-da!

That's it! Our test run showed a sustained transfer speed of about 1GB of data/minute, which may or may not happen on a regular basis.

Misc. Comments

Each interactive command ends with a statement like “Next time you want to do this, run the following command”, giving you a method to bypass the interactive part by using a huge command line instead. I was never paying enough attention to capture these, but we should get them and put them up on the wiki to save some time.

Good luck!

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox