Scroll to navigation

BOOTCD2DISK(1) bootcd utils BOOTCD2DISK(1)


bootcd2disk - copy a system running from bootcd to a disk


bootcd2disk [-i|-s|-m] [-d debug_runtime_config] -- [-h|--help]
[-c|--conf CONF] [-y|--yes] [-url url] [--only_mount] [--only_unmount] [--only_copydata] [-o|--use_originaldiskname] [-z|--zerodsk] [--variable_from_bootcd2disk.conf(5) value]


bootcd2disk is used to write a running system to disk. It was originally used do write a running bootcd built with bootcdwrite to disk, but it is also possible to backup a system directly to an attached disk.

The system can be copied to one or more disk partitions seen by the running system. When running from bootcd, it is possible to let bootcd2disk automatically find a disk, make partitions on it, copy the cd to the disk and make the disk bootable.


-i|-s|-m|-d debug_runtime_config
Run bootcdwrite in interactive, silent, minimal control or debug mode. See shellia(1) for this standard shellia options.

-c|--conf CONF

use the bootcdwrite config options from file CONF. Default:



print help and exit


if bootcd2disk.conf was created by bootcdmk2diskconf, not only the variable DISK0 is defined as auto but also ORIG_DISK0 is defined with the original device. To use it this option exists.


answer always yes


This option can be used to zero the first part of the disk, that contains the MBR, before writing to it. Normally this should not be necessary, because sfdisk should be able to rewrite a previously used disk. But users of bootcd have seen disks, where this option may help.

-url url

If bootcd2disk is slow on your system (because of a slow CD/DVD drive or the HP ILO virtual CD interface), you can use an image server to get the bootcd iso image from. The swap partition of the installed system will be used as temporary space for the iso image.

The image server url is configured with this option. Example:

Another way the increase the performance is the use of the mounted CD/DVD itself for the copy. Example:

bootcd2disk -url file:///dev/sdc0

The swap partition of the upcoming system must have enough space to get the whole image!


After bootcd2disk did partition, format and install the disk, the disks can be mounted again with this option. For example to run update-grub in chroot on the mounted disk:
# remount disks to /mnt/bootcd.disc/ bootcd2disk --only_mount

# prepare chroot mount --bind /dev /mnt/bootcd.disc/dev mount -t proc none /mnt/bootcd.disc/proc mount -t sysfs none /mnt/bootcd.disc/sys mount -t devpts none /mnt/bootcd.disc/dev/pts

# run update-grub in chroot chroot /mnt/bootcd.disc update-grub


If the disks are mounted with option --only_mount , they can be unmounted with this option.


This will not create partitions, but only copy data to the directory COPYDEST defined with --COPYDEST COPYDEST


This option writes zeros to the beginning of a disk before using it.

--variable_from_bootcd2disk.conf(5) value

variables or functions listed in bootcd2disk.conf(5) can be overwritten from command line. For example a variable called VARIABLE will get the value VALUE with the option: --VARIABLE VALUE


bootcd(7), bootcdwrite(1), bootcdflopcp(1), bootcdmk2diskconf(1), bootcdbackup(1), bootcdwrite.conf(5), bootcd2disk.conf(5)



2019-09-09 0.1