Linux command
clonezilla 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Boot Clonezilla and start interactive mode
clonezilla
Save disk to image
ocs-sr -q2 -c -j2 -z1p -i 2000 -fsck-y -senc -p reboot savedisk [image_name] [sda]
Restore image to disk
ocs-sr -g auto -e1 auto -e2 -r -j2 -c -p reboot restoredisk [image_name] [sda]
Clone disk to disk
ocs-onthefly -g auto -e1 auto -e2 -r -j2 -sfsck -k -p reboot -f [sda] -d [sdb]
Save partition to image
ocs-sr -q2 -c -j2 -z1p -i 2000 -fsck-y -senc -p reboot saveparts [image_name] [sda1]
List available images
ocs-sr -l
说明
Clonezilla is a disk cloning and imaging solution similar to Norton Ghost. It creates backup images of entire disks or partitions and can restore them to the same or different hardware. Clonezilla boots from USB or CD into a Linux environment with specialized imaging tools. It supports imaging filesystems (ext4, NTFS, HFS+, etc.) efficiently by copying only used blocks. Raw mode supports any filesystem. Two modes are available: Clonezilla Live for imaging single machines, and Clonezilla SE (Server Edition) for mass deployment via network using PXE boot.
参数
- savedisk _name_ _disk_
- Save entire disk to image.
- restoredisk _name_ _disk_
- Restore image to disk.
- saveparts _name_ _parts_
- Save partitions to image.
- restoreparts _name_ _parts_
- Restore partitions from image.
- -q2
- Use partclone for imaging.
- -c
- Confirm before action.
- -j2
- Clone hidden data between MBR and partition.
- -z1p
- Use parallel gzip compression.
- -i _size_
- Split image into files of given MB.
- -fsck-y
- Run fsck automatically.
- -senc
- Encrypt the image.
- -g auto
- Reinstall grub automatically.
- -p _action_
- Post-action: reboot, poweroff, or choose.
FAQ
What is the clonezilla command used for?
Clonezilla is a disk cloning and imaging solution similar to Norton Ghost. It creates backup images of entire disks or partitions and can restore them to the same or different hardware. Clonezilla boots from USB or CD into a Linux environment with specialized imaging tools. It supports imaging filesystems (ext4, NTFS, HFS+, etc.) efficiently by copying only used blocks. Raw mode supports any filesystem. Two modes are available: Clonezilla Live for imaging single machines, and Clonezilla SE (Server Edition) for mass deployment via network using PXE boot.
How do I run a basic clonezilla example?
Run `clonezilla` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does savedisk _name_ _disk_ do in clonezilla?
Save entire disk to image.