Overview

SkyCore includes a drive cloning feature that creates backups of your Jetson Orin partitions. The tool uses partclone to efficiently clone partitions and can compress images to save space. With the clone functionality, you can:
  • Create backups of all partitions from a source device
  • Compress images to save storage space
  • Create archives for easy transfer or storage
  • Create bootable clone drives for Jetson Orin devices

Requirements

  • SkyCore installed on your system
  • Root privileges (sudo)
  • partclone package installed
  • Optional: lz4 or gzip for compression

Basic Usage

sudo skycore clone --source SOURCE_DEVICE [options]
Where SOURCE_DEVICE is the device you want to clone (e.g., /dev/nvme0n1 or /dev/sda).

Command Line Options

OptionDescription
--source, -sSource device to clone (e.g., /dev/nvme0n1)
--compress, -cCompress the image files (using lz4 or gzip)
--output, -oOutput directory for image files (default: current directory)
--debug, -dEnable debug mode (verbose output)
--archive, -aCreate archive of backup (provide archive name without extension)
--help, -hDisplay help information

Examples

Clone a drive to the current directory:
sudo skycore clone --source /dev/sda
Clone with compression to a specific directory:
sudo skycore clone --source /dev/sda --compress --output /tmp/my_backup
Create a compressed archive:
sudo skycore clone --source /dev/sda --compress --archive my_backup

Cloning Process

When you run the clone command, the following steps are performed:
  1. The tool checks if partclone is installed
  2. It identifies all partitions on the source device
  3. It unmounts any mounted partitions (with your confirmation)
  4. It backs up the partition table from the source device
  5. It clones each partition with the appropriate filesystem handler
  6. It compresses the images if the --compress option is used
  7. It creates an archive if the --archive option is used

Restoring Images

To restore cloned images to a target drive, use the skycore flash command:
sudo skycore flash --target /dev/sdX --archive /path/to/backup.tar.gz
For more details, see Flashing Drives.

Troubleshooting

Cannot access source deviceError: Source device /dev/XXX does not exist or is not a block device. Make sure the source device is correctly connected and recognized by the system. Use lsblk to list available block devices.