.TH ocs-onthefly 8 "2026-05-03" "Clonezilla" "Clonezilla Manual" .SH NAME ocs-onthefly \- Clonezilla: on-the-fly disk or partition(s) cloning .SH SYNOPSIS .B ocs-onthefly [\fIOPTION\fR] .SH DESCRIPTION .B ocs-onthefly is used for "disk to disk" or "partition to partition" clone on-the-fly, either locally or over the network. .SH OPTIONS .TP .B \-b, \-batch, \-\-batch, \-\-batch\-mode Run program in batch mode (dangerous!), i.e., without any prompt or wait for confirmation. .TP .B \-cmf, \-\-chk\-chksum\-for\-files\-in\-dev Do the files checksum inspection for cloned files in destination devices. .TP .B \-d, \-\-destination, \-\-target DEV Specify the target device as DEV (e.g., /dev/sdb or sdb). .TP .B \-e1, \-\-change\-geometry NTFS\-BOOT\-PARTITION Force to change the CHS (cylinders, heads, sectors) value of NTFS boot partition after cloning. NTFS-BOOT-PARTITION can be "auto" or a device name. .TP .B \-e2, \-\-load\-geometry\-from\-edd Force to use the CHS from EDD (Enhanced Disk Device) when creating partition table by sfdisk. .TP .B \-r, \-\-resize\-partition Resize the file system size to fit the partition size in the destination disk. .TP .B \-f, \-\-source DEV Specify the source device as DEV (e.g., /dev/sda or sda). .TP .B \-g, \-\-grub\-install GRUB_PARTITION Install grub in the MBR. GRUB_PARTITION can be "auto" or a device name. .TP .B \-\-net\-filter PROGRAM Use the PROGRAM (gzip, lzop, bzip2, xz, lz4, zstd, cat) before sending partition data to netcat/nuttcp (only in network clone mode). Default is zstd. .TP .B \-nogui, \-\-nogui Do not show GUI (TUI), use text only. .TP .B \-rescue, \-\-rescue Turn on rescue mode, i.e., try to skip bad sectors. .TP .B \-rvd, \-\-rvd Remove the NTFS volume dirty flag in source NTFS file system before cloning it. .TP .B \-irhr, \-\-irhr Skip removing the Linux udev hardware records on the restored GNU/Linux. .TP .B \-ius, \-\-ius Skip updating syslinux-related files on the restored GNU/Linux. .TP .B \-iui, \-\-iui Skip updating initramfs file(s) on the restored GNU/Linux. .TP .B \-icds, \-\-ignore\-chk\-dsk\-size\-pt Skip checking destination disk size before creating the partition table. .TP .B \-iefi, \-\-ignore\-update\-efi\-nvram Skip updating boot entries in EFI NVRAM after cloning. .TP .B \-k, \-\-no\-sfdisk Do NOT create partition table in boot sector in target machine. .TP .B \-k0 Create partition table based on the partition table from the source (default). .TP .B \-k1 Create partition table in the target disk proportionally. .TP .B \-k2 Enter command line prompt to create partition table manually before cloning. .TP .B \-j2, \-\-clone\-hidden\-data Use dd to clone the image of the data between MBR (1st sector) and 1st partition. .TP .B \-m, \-\-no\-boot\-loader\-clone Do NOT clone boot loader. .TP .B \-o, \-\-load\-geometry Force to use the saved CHS (cylinders, heads, sectors) when using sfdisk. .TP .B \-q1, \-\-force\-to\-use\-dd Force to use sector-by-sector copy (slow but works for all filesystems). .TP .B \-po, \-\-port PORT Specify the netcat port (only in network clone mode). .TP .B \-p, \-pa, \-\-postaction ACTION Action when cloning finishes: [choose|poweroff|reboot|true|CMD]. .TP .B \-a, \-\-server Specify the running machine is the network clone server. .TP .B \-s, \-\-source\-IP IP Specify the source IP address (used in target client machine). .TP .B \-t, \-\-no\-restore\-mbr Do NOT restore the MBR. .TP .B \-t1, \-\-restore\-raw\-mbr Restore the prebuilt bootloader from syslinux (For Windows only). .TP .B \-t2, \-\-no\-restore\-ebr Do NOT restore the EBR. .TP .B \-v, \-\-verbose Prints verbose information. .TP .B \-np, \-\-net\-pipe PROGRAM Use PROGRAM as network pipe program. Available: netcat, nuttcp. .TP .B \-x, \-\-interactive Interactive mode. .TP .B \-bm, \-\-beginner\-mode Run in beginner mode (shortcut for "-um beginner"). .TP .B \-em, \-\-expert\-mode Run in expert mode (shortcut for "-um expert"). .TP .B \-um, \-\-user\-mode [beginner|expert] Specify the user mode. .TP .B \-edio, \-\-enable\-direct\-io Enable the direct IO mode of Partclone for NVMe SSD. .SH EXAMPLES 1. To clone local sda to local sdb: .IP ocs-onthefly \-f sda \-d sdb .PP 2. To clone sda from machine A (IP 192.168.100.1) to sda on machine B via network: .PP On machine A: .IP ocs-onthefly \-a \-f sda .PP On machine B: .IP ocs-onthefly \-s 192.168.100.1 \-d sda .SH FILES .TP .I /etc/drbl/drbl-ocs.conf The configuration file for Clonezilla. .SH SEE ALSO .BR ocs-sr (8), .BR drbl-ocs (8) .SH AUTHORS Steven Shiau