Hi all we setup a clonezilla server at work. We have Ubuntu 12.04 installed on a VM and have gotten Clonezilla up and running and can PXE boot to it. My issue is that we can not save the images inside of the VM the images need to be saved on the NAS. As off right now the files are being saved in /home/partimag which is the default. I can post any config files need please let me know the best way to set this up. I have Synology and have created an NFS share on the unit. Below are some of the config files.
Drbl.conf
Author: Steven Shiau <steven _at_="" nchc="" org="" tw=""></steven>
License: GPL
Setting for DRBL environment.
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
Keep drblroot="/tftpboot/nodes" and drbl_common_root="/tftpboot/node_root". These settings are already fixed in some programs.
//NOTE// The variable "DRBL_SCRIPT_PATH" is from system environment variable, and if not defined, it will be "/usr/share/drbl" by default.
drbl_setup_path="$DRBL_SCRIPT_PATH/setup"
Do NOT put / in the end of $drblroot, it's important
when using rsync in drbl-setup
DO NOT modify t$drblroot and $drbl_common_root, it's already fixed for the
whole system, drblsrv and drblpush use /tftpboot/nodes and /tftpboot/node_root
Why we put here is only for sometimes we can use them.
if [ -e /etc/debian_version ]; then
# Debian
SYSCONF_PATH="/etc/default/"
# From Debian Squeeze, isc-dhcp-server is used, no more dhcp3-server (as that in etch, lenny...)
if [ -x "/usr/sbin/dhcpd3" ]; then
DHCPDCONF_DIR="/etc/dhcp3"
DHCP_SRV_NAME="dhcp3-server"
else
DHCPDCONF_DIR="/etc/dhcp"
DHCP_SRV_NAME="isc-dhcp-server"
fi
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
NFS_SRV_NAME="nfs-kernel-server"
YP_SRV_NAME="nis"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/X11/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/X11/gdm/factory-gdm.conf"
#KDM_CFG="/etc/kde3/kdm/kdmrc"
RCX_ROOTDIR="/etc"
# The releative path between init.d and rcx.d, for Debian, it's same, so
# in when working dir is in rc.d, service is in ../init.d/
RCX_REL_INITD="../init.d"
# Force to set the color output when it is Debian. For RH-like distribution,
# it is already defined in /etc/init.d/functions.
BOOTUP=color
query_allpkgs_cmd="dpkg --get-selections"
query_pkglist_cmd="dpkg -L"
# instead of using dpkg -s, we use dpkg -L, since dpkg -s will give the wrong
# return code if a package is installed but removed later.
query_pkglist_exist_cmd="dpkg -L"
elif [ -e /etc/SuSE-release ]; then
# SuSE
SYSCONF_PATH="/etc/sysconfig/"
DHCPDCONF_DIR="/etc"
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
DHCP_SRV_NAME="dhcpd"
NFS_SRV_NAME="nfs"
YP_SRV_NAME="ypserv"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/opt/gnome/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/opt/gnome/gdm/factory-gdm.conf"
#KDM_CFG="/etc/opt/kde3/share/config/kdm/kdmrc"
RCX_ROOTDIR="/etc/init.d"
# The releative path between init.d and rcx.d, for SuSE, it's not same,
# rcx.d is under init.d. So in when working dir is in rc.d, service is in ../
RCX_REL_INITD="../"
# Force to set the color output when it is SuSE. For RH-like distribution,
# it is already defined in /etc/init.d/functions.
BOOTUP=color
query_allpkgs_cmd="rpm -qa"
query_pkglist_cmd="rpm -ql"
query_pkglist_exist_cmd="rpm -q"
else
# RH-like
SYSCONF_PATH="/etc/sysconfig/"
# From Fedora 11, the dhcpd config dir is in /etc/dhcp
if [ -d "/etc/dhcp" ]; then
DHCPDCONF_DIR="/etc/dhcp"
else
DHCPDCONF_DIR="/etc"
fi
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
DHCP_SRV_NAME="dhcpd"
# From Mandriva 2008.0, the nfs server name is changed to nfs-server.
nfs_srv_name_chklist="nfs nfs-server"
NFS_SRV_NAME=""
for i in $nfs_srv_name_chklist; do
if [ -e /etc/init.d/$i -o -e "/lib/systemd/system/$i.service" ]; then
NFS_SRV_NAME="$i"
break
fi
done
YP_SRV_NAME="ypserv"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/X11/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/X11/gdm/factory-gdm.conf"
#KDM_CFG="/etc/kde/kdm/kdmrc"
RCX_ROOTDIR="/etc"
# The releative path between init.d and rcx.d, for RH-like, it's same, so
# in when working dir is in rc.d, service is in ../init.d/
RCX_REL_INITD="../init.d"
query_allpkgs_cmd="rpm -qa"
query_pkglist_cmd="rpm -ql"
query_pkglist_exist_cmd="rpm -q"
fi
syslinux_binsrc_url is for downloading syslinux and pxelinux if necessary. You can change to any mirror site. E.g. "http://www.kernel.org/pub/linux/utils/boot/syslinux/"
Note, we can not use - or other charactor, since isolinux won't accept that (drbl-pxe.png is not accepted by syslinux, however, it's ok for pxelinux). To fit both, we use drblwp.png.
Note, we can not use - or other charactor, since isolinux won't accept that (ocs-logo.png is not accepted by syslinux, however, it's ok for pxelinux). To fit both, we use ocswp.png.
UGLY!!! We should not put the fixed version rpm here, but this seems to be the most easiest way to do. Thanks! From FC3, this is no more, since we already use yum.
For Mandriva, actually it's not necessary. However, just keep it as a record.
//NOTE// Packages lzop ntfsprogs partimage maybe are not included in distribution repository (e.g. CentOS). If so, the backup plan is to use those in drbl repository.
Use dhcp-client$ for dhcp3-client, dhcp-client, and isc-dhcp-client (yes, debian will select 'dhcp-client' for regex 'dhcp-client', then select 'isc-dhcp-client' for regex 'dhcp*-client'. With "$" in the end means we do not want "isc-dhcp-client-dbg"
Excluding some dir when rsync server's /etc to client's /etc
/etc/selinux/targeted is for selinux, which is already disabled in client.
//NOTE// Always remember to put the / in the end of dir.
etc_exclude_dirs="/etc/selinux/targeted/"
If /var/run is a symbolic file (on Ubuntu 11.10 or FC17, for example), we will copy it, too. Otherwise for /var/ we will only copy directories name (Files in /var/lib/ will be copied, though). Actually in this case, /var/run is linked to /run. For /var/lock, it is linked to /run/lock
symbolic_files_in_var_chklist="run lock"
The directory with its content that will NOT to be copied to common root's /var/lib
This is for rsyncing /var/lib/ to /tftpboot/node_root/var/lib/
The reason that varlib_NOT_2_be_copied_2_common_root and varlib_NOT_2_be_copied_2_each_client can not share the same is that for some dir, e.g. /var/lib/{rpm,dpkg}, client will mount from /tftpboot/node_root/, so we do not have to waste the space to copy to each client's /var/lib/.
NOTE!!! Do not append "/" in the end of the dir name
varlib_NOT_2_be_copied_2_common_root="tftpboot mysql vmware-server boinc-client/projects hadoop backuppc ntp/proc"
The directory with its content that will be copied to common root's /var/cache
This is for rsyncing /var/cache/ to /tftpboot/node_root/var/cache/
NOTE!!! Do not append "/" in the end of the dir name
varcache_2_be_copied_2_common_root="debconf sax"
The directory with its content that will NOT to be copied to client's /var/lib
This is for rsyncing /tftpboot/node_root to /tftpboot/nodes/$IP
Ugly here....
lib to be copied due to those necessary files for some packages,
especially rpm database and alternatives
Do NOT copy others if you are not sure, such as /var/lib/nfs will cause
nfslock refuse to start...
NOTE!!! Do not append "/" in the end of the dir name
Set DRBL gdm greeting background for DRBL clients ?
set_drbl_gdmgreeter="yes"
PRE_RUN_DIR and POST_RUN_DIR
The script in the direcoty $DRBLPUSH_PRERUN_DIR will be run before drblpush is run, and script in the direcoty $DRBLPUSH_POSTRUN_DIR will be run after it is finished. You need to put your own scripts in those directories if you want to use this.
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_1 are those necessary dir for mount point.
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_1="home mnt proc tmp usr opt root dev var lib initrd sys"
diskless_root_dir_2 are those necessary dir for mount point (from drbl.conf), too. These dirs depend on distribution, so we will test it before create it.
Add misc net srv on 6/14/2005 for FC4
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_2="media misc net srv selinux"
If the dir (tmpfs) exists on server's /etc/fstab, append it to client's /etc/fstab:
try IP from 192.168."100".254 for alias IP address subnet
drbl_live_private_IP_alias_eth_def="100"
For SAN booting (AoE/iSCSI booting)
Only 1 dir is allowed here, since we will use it as the target dir to dump AoE file by drbl-aoe-img-dump. Later you can use drbl-aoe-srv to assign different image dirs, including multiple dirs
we have tried modifying fstab to mount the NAS to /home/partimag in both the PXE fstab and the servers fstab. Also we have tried just adding the fstab edits to the client-append-fstab file but that also did not work to mount the NAS the files are still saved in the local VM instead of the NAS.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi all we setup a clonezilla server at work. We have Ubuntu 12.04 installed on a VM and have gotten Clonezilla up and running and can PXE boot to it. My issue is that we can not save the images inside of the VM the images need to be saved on the NAS. As off right now the files are being saved in /home/partimag which is the default. I can post any config files need please let me know the best way to set this up. I have Synology and have created an NFS share on the unit. Below are some of the config files.
Drbl.conf
Author: Steven Shiau <steven _at_="" nchc="" org="" tw=""></steven>
License: GPL
Setting for DRBL environment.
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
Keep drblroot="/tftpboot/nodes" and drbl_common_root="/tftpboot/node_root". These settings are already fixed in some programs.
//NOTE// The variable "DRBL_SCRIPT_PATH" is from system environment variable, and if not defined, it will be "/usr/share/drbl" by default.
drbl_setup_path="$DRBL_SCRIPT_PATH/setup"
Do NOT put / in the end of $drblroot, it's important
when using rsync in drbl-setup
DO NOT modify t$drblroot and $drbl_common_root, it's already fixed for the
whole system, drblsrv and drblpush use /tftpboot/nodes and /tftpboot/node_root
Why we put here is only for sometimes we can use them.
drblroot="/tftpboot/nodes"
drbl_common_root="/tftpboot/node_root"
if [ -e /etc/debian_version ]; then
# Debian
SYSCONF_PATH="/etc/default/"
# From Debian Squeeze, isc-dhcp-server is used, no more dhcp3-server (as that in etch, lenny...)
if [ -x "/usr/sbin/dhcpd3" ]; then
DHCPDCONF_DIR="/etc/dhcp3"
DHCP_SRV_NAME="dhcp3-server"
else
DHCPDCONF_DIR="/etc/dhcp"
DHCP_SRV_NAME="isc-dhcp-server"
fi
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
NFS_SRV_NAME="nfs-kernel-server"
YP_SRV_NAME="nis"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/X11/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/X11/gdm/factory-gdm.conf"
#KDM_CFG="/etc/kde3/kdm/kdmrc"
RCX_ROOTDIR="/etc"
# The releative path between init.d and rcx.d, for Debian, it's same, so
# in when working dir is in rc.d, service is in ../init.d/
RCX_REL_INITD="../init.d"
# Force to set the color output when it is Debian. For RH-like distribution,
# it is already defined in /etc/init.d/functions.
BOOTUP=color
query_allpkgs_cmd="dpkg --get-selections"
query_pkglist_cmd="dpkg -L"
# instead of using dpkg -s, we use dpkg -L, since dpkg -s will give the wrong
# return code if a package is installed but removed later.
query_pkglist_exist_cmd="dpkg -L"
elif [ -e /etc/SuSE-release ]; then
# SuSE
SYSCONF_PATH="/etc/sysconfig/"
DHCPDCONF_DIR="/etc"
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
DHCP_SRV_NAME="dhcpd"
NFS_SRV_NAME="nfs"
YP_SRV_NAME="ypserv"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/opt/gnome/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/opt/gnome/gdm/factory-gdm.conf"
#KDM_CFG="/etc/opt/kde3/share/config/kdm/kdmrc"
RCX_ROOTDIR="/etc/init.d"
# The releative path between init.d and rcx.d, for SuSE, it's not same,
# rcx.d is under init.d. So in when working dir is in rc.d, service is in ../
RCX_REL_INITD="../"
# Force to set the color output when it is SuSE. For RH-like distribution,
# it is already defined in /etc/init.d/functions.
BOOTUP=color
query_allpkgs_cmd="rpm -qa"
query_pkglist_cmd="rpm -ql"
query_pkglist_exist_cmd="rpm -q"
else
# RH-like
SYSCONF_PATH="/etc/sysconfig/"
# From Fedora 11, the dhcpd config dir is in /etc/dhcp
if [ -d "/etc/dhcp" ]; then
DHCPDCONF_DIR="/etc/dhcp"
else
DHCPDCONF_DIR="/etc"
fi
# DHCPDLEASE_DIR is got from get_dhcpdlease_dir() in drbl-functions
DHCP_SRV_NAME="dhcpd"
# From Mandriva 2008.0, the nfs server name is changed to nfs-server.
nfs_srv_name_chklist="nfs nfs-server"
NFS_SRV_NAME=""
for i in $nfs_srv_name_chklist; do
if [ -e /etc/init.d/$i -o -e "/lib/systemd/system/$i.service" ]; then
NFS_SRV_NAME="$i"
break
fi
done
YP_SRV_NAME="ypserv"
# Now GDM_CFG, FAC_GDM_CFG and KDM_CFG are got in drbl-functions.
#GDM_CFG="/etc/X11/gdm/gdm.conf"
#FAC_GDM_CFG="/etc/X11/gdm/factory-gdm.conf"
#KDM_CFG="/etc/kde/kdm/kdmrc"
RCX_ROOTDIR="/etc"
# The releative path between init.d and rcx.d, for RH-like, it's same, so
# in when working dir is in rc.d, service is in ../init.d/
RCX_REL_INITD="../init.d"
query_allpkgs_cmd="rpm -qa"
query_pkglist_cmd="rpm -ql"
query_pkglist_exist_cmd="rpm -q"
fi
drbl_syscfg="/etc/drbl"
cache_dir="/var/cache/apt/archives"
drbl_pkgdir="/usr/share/drbl/share"
pxecfg_pd="/tftpboot/nbi_img"
syslinux_binsrc_url is for downloading syslinux and pxelinux if necessary. You can change to any mirror site. E.g. "http://www.kernel.org/pub/linux/utils/boot/syslinux/"
syslinux_binsrc_url="http://free.nchc.org.tw/syslinux"
SYS_PXELINUX_VER_DEF="4.06"
pxelinux_binsrc_dir="$DRBL_SCRIPT_PATH/pkg/syslinux/"
pxelinux_file="$pxelinux_binsrc_dir/pxelinux.0"
gpxelinux_file="$pxelinux_binsrc_dir/gpxelinux.0"
pxelinux_simple_menu="$pxelinux_binsrc_dir/menu.c32"
pxelinux_simple_vesamenu="$pxelinux_binsrc_dir/vesamenu.c32"
pxelinux_memdisk_file="$pxelinux_binsrc_dir/memdisk"
pxelinux_chain_file="$pxelinux_binsrc_dir/chain.c32"
pxelinux_mboot_file="$pxelinux_binsrc_dir/mboot.c32"
pxelinux_sanboot_file="$pxelinux_binsrc_dir/sanboot.c32"
For Syslinux 5, new .c32 are required: ldlinux.c32, libcom32.c32, libutil.c32
sys_pxelinux_required_c32="ldlinux.c32 libcom32.c32 libutil.c32"
Note, we can not use - or other charactor, since isolinux won't accept that (drbl-pxe.png is not accepted by syslinux, however, it's ok for pxelinux). To fit both, we use drblwp.png.
pxelinux_bg_img="$DRBL_SCRIPT_PATH/image/drblwp.png"
PXELINUX_DIR="/tftpboot/nbi_img/pxelinux.cfg"
PXE_CONF_DEF="$PXELINUX_DIR/default"
isolinux_file="$pxelinux_binsrc_dir/isolinux.bin"
Note, we can not use - or other charactor, since isolinux won't accept that (ocs-logo.png is not accepted by syslinux, however, it's ok for pxelinux). To fit both, we use ocswp.png.
ocs_logo_img_png="$DRBL_SCRIPT_PATH/image/ocswp.png"
ocs_logo_img_xpm="$DRBL_SCRIPT_PATH/image/ocswp.xpm.gz"
ocs_logo_grub2_img_png="$DRBL_SCRIPT_PATH/image/ocswp-grub2.png"
MEMTEST86_URL="http://www.memtest.org/download/"
MEMTEST86_VER_DEF="4.20"
memtest86_file="$DRBL_SCRIPT_PATH/pkg/memtest86+/memtest86"
fdos_img_src="/usr/lib/freedos/fdos1440.img"
fdos_img_output="fdos1440_drbl.img"
PXE_RAMDISK_SIZE_DEF="19456"
PXE_RAMDISK_BLOCKSIZE="1024"
NETINSTALL_RAMDISK_SIZE_DEF="65535"
The default-lease-time and max-lease-time in dhcpd.conf (secs)
DHCPD_DEFAULT_LEASE_TIME="300"
DHCPD_MAX_LEASE_TIME="300"
The default image might show in menu if user want to show them.
note! use lowercase for the image name!!!
IMG_SHOW_IN_MENU="drbl local memtest drbl-terminal"
pxelinux menu
powerful_client_menu_label="Linux (DRBL mode, mostly local resources)"
thin_client_menu_label="Linux (Terminal mode, mostly remote resources)"
local OS label in pxelinux menu
Some might want to change it as: Debian Linux, or M$ windows...
local_os_menu_label="Local operating system (if available)"
url_prefix="http://free.nchc.org.tw"
graphical boot settings, now only for Fedora Core (i.e. we will put "rhgb" in pxelinux.cfg/default)
graphical_boot="no"
clonezilla image directory, the default dir is /home/partimag (YES, it's partimag instead of partimage)
NOTE! Do NOT put / in the end of the dir (i.e. Ex. use /home/partimag instead of /home/partimag/)
ocsroot="/home/partimag" # Modified by drblpush
clonezilla.lock path
ocs_lock_dir="/var/lock/clonezilla"
clonezilla log files path
ocs_log_dir="/var/log/clonezilla/"
log file for sfdisk when restoring
RESTORE_SFDISK_LOG="/var/log/clonezilla-restore-sfdisk.log"
Administrator account ID in M$ windows
This is for drbl-doit to send command to cloned M$ windows via ssh. Different language M$ windows use different ID. Ex:
English: Administrator
Traditional Chinese: Administrator
France: Administrateur
Dutch: Administrator
Default vlaue: Administrator
MSWIN_ADMIN_ID="Administrator"
default LANGUAGE
[0]: English, [1]: Traditional Chinese (Big5) - Taiwan, [2] Traditional Chinese (UTF-8, Unicode) - Taiwan"
DEFAULT_LANGUAGE="0"
default pxe timeout (unit: 1/10 sec)
DEFAULT_PXE_TIMEOUT="70"
user with UID greater than $uid_begin_default is normal user,
i.e. effective id
UID_BEGIN_DEFAULT="500"
Misc setting
TIMED_GDM_TIME_DEFAULT="30"
TIMED_LIGHTDM_TIME_DEFAULT="30"
PASSWD_LENGTH_DEFAULT="8"
AUTO_LOGIN_ID_PASSWD="$drbl_syscfg/auto_login_id_passwd.txt"
The time (how long ago) to kill the old $AUTO_LOGIN_ID_PASSWD file, in secs.
TIME_2_KILL="1200"
The default max swap file (MB)
maxswapsize_default="128"
The default ramdisk size for PXE and NBI initrd (MB)
default_ramdisk_size="9600"
parameter for checking space
common_root_dir="/bin /etc /lib /sbin"
buffer_ratio_for_client_space="1.5"
HOST_MAC_TABLE="$drbl_syscfg/HOST_MAC_TABLE"
IP_HOST_TABLE="$drbl_syscfg/IP_HOST_TABLE"
drbl-useradd need these:
useradd_range_exec_file="drbl-useradd-range"
userdel_range_exec_file="drbl-userdel-range"
useradd_file_exec_file="drbl-useradd-file"
userdel_file_exec_file="drbl-userdel-file"
useradd_list_exec_file="drbl-useradd-list"
userdel_list_exec_file="drbl-userdel-list"
useradd_gen="username_pw.txt"
XFS font server switch
XFS_RATIO="1.2"
fs_port="7100"
fixed setting
UGLY!!! We should not put the fixed version rpm here, but this seems to be the most easiest way to do. Thanks! From FC3, this is no more, since we already use yum.
For Mandriva, actually it's not necessary. However, just keep it as a record.
wget_rpm_RH8_0="wget-1.8.2-3.i386.rpm"
wget_rpm_RH9="wget-1.8.2-9.i386.rpm"
wget_rpm_FC1="wget-1.8.2-15.3.i386.rpm"
wget_rpm_FC2="wget-1.9.1-5.i386.rpm"
wget_rpm_FC3="wget-1.9.1-17.i386.rpm"
wget_rpm_MDK9_2="wget-1.8.2-12mdk.i586.rpm"
wget_rpm_MDK10_0="wget-1.9.1-4mdk.i586.rpm"
wget_rpm_MDK10_1="wget-1.9.1-4mdk.i586.rpm"
List those packages has different arch rpms (i386, i486, i586, i686) in repository except kernel. This is specially for Redhat, Fedora, CentOS.
Ex: glibc-2.6-3.i386.rpm, glibc-2.6-3.i686.rpm
openssl-0.9.8b-12.fc7.i386.rpm, openssl-0.9.8b-12.fc7.i686.rpm
openssl-perl is specially for CentOS (4.x).
i686_pkg_check_list_RH_like="glibc openssl openssl-perl pm-utils libbeagle libbeagle-devel libbeagle-python beagle beagle-evolution beagle-gui"
DRBL server necessary services checklist, both for RH-like and Debian.
list all the possible services, if it exists, will start it.
RH-like: dhcpd xinetd portmap iptables ypserv ypbind yppasswdd ypxfrd nfs nfslock nis (Note! Since Fedora Core 7, portmap is replaced by rpcbind)
Debian: nfs-common dhcp3-server nis nfs-kernel-server tftpd-hpa drbl-clients-nat inetd (woody). unfs3 is for DRBL Live if it's installed.
From Debian Squeeze, isc-dhcp-server is used, no more dhcp3-server (as that in etch, lenny...)
Note: nfs-common should be before nfs-kernel-server
SuSE: nfsserver instead of nfs (nfs is client server)
Mandriva 2008: nfs-server instead of nfs
drbl_server_service_chklist="dhcpd xinetd portmap rpcbind iptables ypserv ypbind yppasswdd ypxfrd nfs nfslock dhcp3-server isc-dhcp-server nis nfs-common nfs-kernel-server nfs-server unfs3 tftpd-hpa inetd nfsserver SuSEfirewall2_init SuSEfirewall2_setup drbl-clients-nat"
DRBL client necessary services checklist, both for RH-like and Debian.
list the possible services which are necessary for cleitns,
we will test all that in RedHat/Fedora/Mandrake/Debian...
Note: "nfs" is server in RH, but it's client in SuSE. So we have to add it
separately for SuSE.
Note: hwscan for suse will be processed later, check the session "# Take care the hardware config files, clean old, make them be detected at boot"
For Ubuntu, we add: acpid, acpi-support, and usplash for clients.
Note! for OpenSuSE 10.1, we add powersaved resmgr
For Fedora 7, we add ConsoleKit, which is necessary for CD/USB stick automount. Sep/12/2008.
For Mandriva 2008, we add consolekit, which is necessary for CD/USB stick automount. Oct/10/2008.
Note! service network or network-up is not necessary since network is already done in initrd of client.
client_services_chklist="netfs portmap rpcbind crond nfslock sshd xfs ypbind kudzu harddrake dm alsa sound keytable haldaemon messagebus nis nfs-common makedev ssh dbus-1 hal dbus kbd acpid acpi-support powersaved resmgr usplash gpm ConsoleKit consolekit cups cupsys pcscd cpuspeed abrtd binfmt-support"
necessary packages for DRBL environment,
we separate them as RH, MDK, SUSE and Debian
//NOTE// Packages lzop ntfsprogs partimage maybe are not included in distribution repository (e.g. CentOS). If so, the backup plan is to use those in drbl repository.
PKG_FROM_RH="dhcp tftp-server nfs-utils ypserv ypbind yp-tools firstboot iptables wget dialog initscripts rsync parted tcpdump bc dos2unix curl lftp openssh-server openssh-clients coreutils gzip bzip2 nc file ethtool net-tools syslinux zip unzip iproute binutils expect lzop ntfsprogs partimage pigz pbzip2 udpcast memtest86+ yum yum-utils"
PKG_TO_UNINSTALL_PART1_RH="dhcp tftp-server nfs-utils ypserv ypbind yp-tools dos2unix"
PKG_TO_UNINSTALL_PART2_RH=""
PKG_FROM_MDK="dhcp-server tftp-server nfs-utils ypserv ypbind yp-tools iptables wget cdialog initscripts rsync parted drakxtools pciutils autologin tcpdump bc dos2unix curl lftp openssh-server openssh-clients coreutils gzip bzip2 nc file ethtool net-tools syslinux glibc-i18ndata zip unzip iproute2 binutils expect lzop ntfsprogs partimage pigz pbzip2 udpcast"
PKG_TO_UNINSTALL_PART1_MDK="dhcp-server tftp-server nfs-utils ypserv ypbind yp-tools dos2unix"
PKG_TO_UNINSTALL_PART2_MDK=""
The reason we need pbbuttonsd in SuSE is we need "run-parts"
PKG_FROM_SUSE="dhcp-server tftp nfs-utils ypserv ypbind yp-tools iptables wget dialog rsync parted tcpdump bc dos2unix curl lftp openssh insserv coreutils gzip bzip2 netcat file ethtool netdiag syslinux glibc-i18ndata zip unzip iproute2 pbbuttonsd binutils expect lzop ntfsprogs partimage pigz pbzip2 udpcast memtest86+"
PKG_TO_UNINSTALL_SUSE="dhcp-server tftp nfs-utils ypserv ypbind yp-tools"
PKG_FROM_DBN_MINIMAL_NEED are those required packages in Debian Live, DRBL and Clonezilla
PKG_FROM_DBN_WHICH_OCS_LIVE_NEED are what we create drbl live and clonezilla live need.
PKG_FROM_DBN is those required packages when drbl server is setup ($PKG_FROM_DBN_MINIMAL_NEED is included in $PKG_FROM_DBN).
Therefore PKG_FROM_DBN_MINIMAL_NEED is the common one for "Debian Live CD for ocs" and DRBL/Clonezilla
PKG_FROM_DBN_MINIMAL_NEED="util-linux tar gzip bzip2 lzop pigz pbzip2 procps dialog rsync parted pciutils tcpdump bc gawk hdparm sdparm netcat file ethtool etherwake ssh syslinux mtools reiserfsprogs e2fsprogs psmisc locales wget disktype zip unzip patch iproute traceroute iputils-ping binutils expect partimage udpcast"
Use dhcp-client$ for dhcp3-client, dhcp-client, and isc-dhcp-client (yes, debian will select 'dhcp-client' for regex 'dhcp-client', then select 'isc-dhcp-client' for regex 'dhcp*-client'. With "$" in the end means we do not want "isc-dhcp-client-dbg"
PKG_FROM_DBN_WHICH_OCS_LIVE_NEED="$PKG_FROM_DBN_MINIMAL_NEED perl-modules less ntfs-3g screen bogl-bterm jfbterm localepurge whiptail sshfs cifs-utils lftp dhcp*-client$ fbset gddrescue lvm2 xfsprogs xfsdump jfsutils dosfstools console-data console-setup console-common kbd reiser4progs hfsutils hfsprogs pwgen testdisk tofrodos dvd+rw-tools udftools pcmciautils nfs-common man ncpfs pppoe pppoeconf ethtool mc wodim net-tools lshw hwinfo deborphan refit encfs lsscsi open-iscsi aoetools mdadm gpm ifupdown usbutils dmidecode mbr wipe hexedit cryptsetup kexec-tools vim-tiny lbzip2 lzma xz-utils pxz lzip plzip lrzip bsdmainutils wireless-tools w3m smartmontools vmfs-tools dbus dmsetup dmraid kpartx wpasupplicant fsarchiver cdrdao bind9-host nano grub-pc sysklogd fbcat foremost eject gzrt sudo busybox user-setup genisoimage btrfs-tools gdisk ufsutils hal pcscd partclone-utils cpufrequtils acpi dirvish rsnapshot pv dnsutils vlan mpg123 tree exfat-utils exfat-fuse tcplay libdata-validate-ip-perl udisks extlinux keyutils"
PKG_FROM_DBN="$PKG_FROM_DBN_MINIMAL_NEED initscripts tftpd-hpa nfs-kernel-server nis curl lftp iptables memtest86+ ntfs-3g"
PKG_TO_UNINSTALL_PART1_DBN="$DHCP_SRV_NAME tftpd-hpa nfs-kernel-server nis"
PKG_TO_UNINSTALL_PART2_DBN=""
Some package we are not sure it exists in repository or not, so query before
install it, otherwise such as apt, one package does not exist, all the
installation will be aborted.
This is only for DRBL and DRBL live, nothing to do with Clonezilla live.
PKG_TO_QUERY is for common, and PKG_TO_QUERY_RH is for Redhat-like distributions
PKG_TO_QUERY="mkinitrd lvm2 ntfs-3g genisoimage mkisofs lshw hwinfo aoetools vblade dmidecode lzop lzma xz xz-utils pxz lzip pigz pbzip2 lbzip2 plzip lrzip hfsutils hfsprogs dmsetup dmraid kpartx device-mapper tofrodos dos2unix unix2dos dhcp3-server isc-dhcp-server gdisk btrfs-tools ufsutils disktype"
PKG_TO_QUERY_RH="dracut"
package from DRBL
PKG_FROM_DRBL_FOR_CLONEZILLA_LIVE is the packages which clonezilla live need.
PKG_FROM_DRBL_FOR_CLONEZILLA_LIVE="clonezilla mkswap-uuid partclone drbl-chntpw"
PKG_FROM_DRBL="$PKG_FROM_DRBL_FOR_CLONEZILLA_LIVE mkpxeinitrd-net ipxe freedos"
i686 package list for SUSE
TODO: make use list_available_rpm to get the lists.
i686_pkg_check_list_SUSE="glibc glibc-devel db db-devel db41 db41-devel"
Packages for gparted, this is for Debian.
vim-common is for /usr/bin/xdd, which is required for NTFS moves and copies.
debian_pkgs_for_gparted="gparted hfsutils hfsprogs jfsutils xfsprogs xfsdump reiserfsprogs reiser4progs btrfs-tools parted ntfs-3g dosfstools mtools lvm2 mbr vim-common hal dmsetup dmraid kpartx"
Excluding some dir when rsync server's /etc to client's /etc
/etc/selinux/targeted is for selinux, which is already disabled in client.
//NOTE// Always remember to put the / in the end of dir.
etc_exclude_dirs="/etc/selinux/targeted/"
If /var/run is a symbolic file (on Ubuntu 11.10 or FC17, for example), we will copy it, too. Otherwise for /var/ we will only copy directories name (Files in /var/lib/ will be copied, though). Actually in this case, /var/run is linked to /run. For /var/lock, it is linked to /run/lock
symbolic_files_in_var_chklist="run lock"
The directory with its content that will NOT to be copied to common root's /var/lib
This is for rsyncing /var/lib/ to /tftpboot/node_root/var/lib/
The reason that varlib_NOT_2_be_copied_2_common_root and varlib_NOT_2_be_copied_2_each_client can not share the same is that for some dir, e.g. /var/lib/{rpm,dpkg}, client will mount from /tftpboot/node_root/, so we do not have to waste the space to copy to each client's /var/lib/.
NOTE!!! Do not append "/" in the end of the dir name
varlib_NOT_2_be_copied_2_common_root="tftpboot mysql vmware-server boinc-client/projects hadoop backuppc ntp/proc"
The directory with its content that will be copied to common root's /var/cache
This is for rsyncing /var/cache/ to /tftpboot/node_root/var/cache/
NOTE!!! Do not append "/" in the end of the dir name
varcache_2_be_copied_2_common_root="debconf sax"
The directory with its content that will NOT to be copied to client's /var/lib
This is for rsyncing /tftpboot/node_root to /tftpboot/nodes/$IP
Ugly here....
lib to be copied due to those necessary files for some packages,
especially rpm database and alternatives
Do NOT copy others if you are not sure, such as /var/lib/nfs will cause
nfslock refuse to start...
NOTE!!! Do not append "/" in the end of the dir name
sax is for SuSE's DRBL firstboot.
varlib_NOT_2_be_copied_2_each_client="dhcp nfs rpm dpkg apt synaptic yum urpmi"
For SuSE, we need to copy /var/X11R6 to clients also. How about /var/adm ?
set the DIA as dialog, whiptail or xdialog
if type whiptail >/dev/null 2>&1; then
DIA="whiptail"
else
DIA="dialog"
fi
NFS
default ratio for nfsd and total client number, i.e. the nfs daemon number
(RPCNFSDCOUNT) running in server = $NFSD_RATIO * total_client_no.
NFSD_RATIO=2.5
The upper limit for NFS daemons
NFSD_MAX=120
Extra options for NFS client in /etc/fstab
nfs_client_extra_opt=""
Yum repository blacklist, Ex. http://ftp.isu.edu.tw, it uses page by page output, it it NOT compatable with DRBL scripts.
yum_repo_blacklists="http://ftp.isu.edu.tw"
DRBL yum repo list
drbl_yum_repo_list="drbl.repo drbl-testing.repo drbl-unstable.repo drbl-extra.repo drbl-legacy.repo"
RPM MD repository config file (drbl.repo, drbl-testing.repo, drbl-unstable.repo). This is for OpenSuSE 11.1 or later.
rpm_md_conf_dir_path="$drbl_setup_path/rpm-md-repos"
Set DRBL gdm greeting background for DRBL clients ?
set_drbl_gdmgreeter="yes"
PRE_RUN_DIR and POST_RUN_DIR
The script in the direcoty $DRBLPUSH_PRERUN_DIR will be run before drblpush is run, and script in the direcoty $DRBLPUSH_POSTRUN_DIR will be run after it is finished. You need to put your own scripts in those directories if you want to use this.
DRBLPUSH_PRERUN_DIR="$DRBL_SCRIPT_PATH/prerun/drbl/"
DRBLPUSH_POSTRUN_DIR="$DRBL_SCRIPT_PATH/postrun/drbl/"
drbl client common root dir
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_1 are those necessary dir for mount point.
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_1="home mnt proc tmp usr opt root dev var lib initrd sys"
diskless_root_dir_2 are those necessary dir for mount point (from drbl.conf), too. These dirs depend on distribution, so we will test it before create it.
Add misc net srv on 6/14/2005 for FC4
WARNING! DO NOT MODIFY THIS FILE UNLESS YOU KNOW WHAT YOU ARE DOING!
diskless_root_dir_2="media misc net srv selinux"
If the dir (tmpfs) exists on server's /etc/fstab, append it to client's /etc/fstab:
memfs_dir_in_rh_client_fstab="/dev/shm /dev/pts /sys /proc"
dummy ethernet card port config in client (for RH-like only)
The dummy files are automatically created by DRBL to avoid to be regenerated.
They will be saved to $drblroot/$ip/etc/sysconfig/network-scripts/ifcfg-$ethx
Normally 4 NICs will be enough, if you have more NICs in DRBL client, append them.
dummy_eth_nics="eth0 eth1 eth2 eth3"
diskless_root_dir_ro_user_add and diskless_root_dir_rw_user_add are user assigned directores so that client can see those directories (NFS mounted).
diskless_root_dir_ro_user_add is ReadOnly dir for client
diskless_root_dir_ro_user_add is ReadWrite dir for client
Ex: "/data /work", then
1. /tftpboot/node_root/data and /tftpboot/node_root/work will be created (done in drblpush)
2. /data and /work will be exported (/etc/exports) (done in drbl-nfs-exports)
3. client will NFS mount /data (from server) as /data and /work (from server) as /work (/etc/fstab) (done in drbl-gen-client-files)
///Note///
(1) You must use the absolute path, for example, in the above example, "/" is necessary for /data.
(2) Do not use the dir under /media as mount point to share. /media in client is based on tmpfs, it's created everytime when it boots.
diskless_root_dir_ro_user_add=""
diskless_root_dir_rw_user_add=""
Debian/Ubuntu user group to be added for the users created by drbl-useradd
desktop_user_group_debian="dialout audio cdrom plugdev floppy video"
GNU/Linux netinstall image settings:
This is used in drbl-netinstall
Be default, we turn off BSD netinstall. If you want to use BSD netintsall, set this as "yes"
setup_bsd_netinst="no"
Debian netinstall
debian_netinstall_ver="squeeze wheezy"
debian_netinstall_arch="i386 amd64"
debian_url_site="http://free.nchc.org.tw"
Path to Debian where directory $ver (Ex. etch) exists
path_to_debian="debian/dists"
debian_netinstall_kernel="linux"
debian_netinstall_initrd="initrd.gz"
Ubuntu netinstall
ubuntu_netinstall_ver="precise quantal"
ubuntu_netinstall_arch="i386 amd64"
ubuntu_url_site="http://free.nchc.org.tw"
Path to Ubuntu where directory $ver (Ex. dapper) exists
path_to_ubuntu="ubuntu/dists"
ubuntu_netinstall_kernel="linux"
ubuntu_netinstall_initrd="initrd.gz"
Fedora netinstall
fedora_netinstall_ver="18"
fedora_netinstall_arch="i386 x86_64"
fedora_url_site="http://free.nchc.org.tw"
Path to Fedora where directory core or releases exists
path_to_fedora="fedora/linux"
fedora_netinstall_kernel="vmlinuz"
fedora_netinstall_initrd="initrd.img"
CentOS netinstall
centos_netinstall_ver="5 6"
centos_netinstall_arch="i386 x86_64"
centos_url_site="http://free.nchc.org.tw"
Path to CentOS where directory $ver (Ex. 4.4) exists
path_to_centos="centos"
centos_netinstall_kernel="vmlinuz"
centos_netinstall_initrd="initrd.img"
RedHat netinstall
redhat_netinstall_ver="8.0 9"
redhat_netinstall_arch="i386"
redhat_url_site="http://free.nchc.org.tw"
Path to RedHat where directory $ver (Ex. 9) exists
path_to_redhat="redhat/linux"
redhat_netinstall_kernel="vmlinuz"
redhat_netinstall_initrd="initrd.img"
Mandriva netinstall
mandriva_netinstall_ver="2010.0"
mandriva_netinstall_arch="i586"
mandriva_url_site="http://free.nchc.org.tw"
Path to Mandriva where directory $ver (Ex. 2007.1) exists
path_to_mandriva="mandrake/official"
mandriva_netinstall_kernel="vmlinuz"
mandriva_netinstall_initrd="all.rdz"
Mageia netinstall
mageia_netinstall_ver="cauldron"
mageia_netinstall_arch="i586"
mageia_url_site="http://free.nchc.org.tw"
Path to Mageia where directory $ver (Ex. cauldron) exists
path_to_mageia="mageia/distrib"
mageia_netinstall_kernel="vmlinuz"
mageia_netinstall_initrd="all.rdz"
Scientific netinstall
scientific_netinstall_ver="6x"
scientific_netinstall_arch="i386 x86_64"
scientific_url_site="http://free.nchc.org.tw"
Path to Scientific where directory $ver (Ex. 50) exists
path_to_scientific="scientific"
scientific_netinstall_kernel="vmlinuz"
scientific_netinstall_initrd="initrd.img"
OpenSuSE netinstall
Note! Works only from 10.1
opensuse_netinstall_ver="12.1"
opensuse_netinstall_arch="i386 x86_64"
opensuse_url_site="http://free.nchc.org.tw"
Path to OpenSUSE where directory $ver (Ex. 10.2) exists
path_to_opensuse="opensuse/distribution"
opensuse_netinstall_kernel="linux"
opensuse_netinstall_initrd="initrd"
FreeBSD netinstall
Note! Works only for 1 version
Ex: ftp://ftp.twaren.net/BSD/FreeBSD/releases/i386/ISO-IMAGES/8.0/8.0-RELEASE-i386-bootonly.iso
freebsd_netinstall_ver="8.0"
freebsd_netinstall_arch="i386"
freebsd_url_site="ftp://ftp.twaren.net"
Path to FreeBSD where releases exists
path_to_freebsd="BSD/FreeBSD/"
OpenBSD netinstall
Note! Works only for 1 version
Ex: ftp://ftp.twaren.net/BSD/OpenBSD/4.6/i386/
openbsd_netinstall_ver="4.6"
openbsd_netinstall_arch="i386"
openbsd_url_site="ftp://ftp.twaren.net"
Path to OpenBSD where version (e.g. 4.6) exists
path_to_openbsd="BSD/OpenBSD/"
For DRBL live
try IP from 192.168."100".254 for alias IP address subnet
drbl_live_private_IP_alias_eth_def="100"
For SAN booting (AoE/iSCSI booting)
Only 1 dir is allowed here, since we will use it as the target dir to dump AoE file by drbl-aoe-img-dump. Later you can use drbl-aoe-srv to assign different image dirs, including multiple dirs
sanboot_img_dump_dir="/home/sanboot-img"
aoe_shelf_max="15"
aoe_slot_max="15"
Drblpush.conf
Setup for general
[general]
domain=drbl.org
nisdomain=penguinzilla
localswapfile=no
client_init=text
login_gdm_opt=
timed_login_time=
maxswapsize=
ocs_img_repo_dir=/home/partimag
total_client_no=12
create_account=
account_passwd_length=8
hostname=clonezilla
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=70
language=en_US.UTF-8
set_client_public_ip_opt=no
config_file=drblpush.conf
collect_mac=no
run_drbl_ocs_live_prep=yes
drbl_ocs_live_server=
clonezilla_mode=full_clonezilla_mode
live_client_branch=alternative
live_client_cpu_mode=i386
drbl_mode=none
drbl_server_as_NAT_server=yes
add_start_drbl_services_after_cfg=yes
continue_with_one_port=
Setup for eth0:0
[eth0:0]
interface=eth0:0
range=1-12
we have tried modifying fstab to mount the NAS to /home/partimag in both the PXE fstab and the servers fstab. Also we have tried just adding the fstab edits to the client-append-fstab file but that also did not work to mount the NAS the files are still saved in the local VM instead of the NAS.