Skip to content

CLI Usage

ark {-s -d -n | -v | -x -d}

Flag Description
-s Source directory used for creating the archive
-d Target directory used to output archive. If not specified, working directory will be used instead
-n Specify the name of the archive. Must be given when creating archive
-v Verifies integrity of part files. Specify metadata file to test archives
-x Restore archive. Specify path to metadata file

Create archive

You can specify a directory (recommended) or file. You do not need to tar archive a directory yourself.

ark -s /path/to/source/ -d /path/to/outputdir/ -n archive_name

You cannot create archive names with an equals (=) sign. If you want to use a space remember to enclose in perensese: -n "name of archive"

Nb: the output directory must have double the available space to match the source directory. After processing, the space requirement will the same as the source directory.

How this works.

Verify archive

A useful feature is to verify the integrity of the archive parts. Testing backups are an important aspect of data preservation. Verifying is a faster method to test parts integrity without restoring the archive.

ark -v /path/to/archive.m

You will need to specify the archive metadata file. As a reminder, you should keep this backed up and ideally keep multiple copies. More on the (metadata file)[metadata.md].

You will be given an output like:

project.0 PASS project.1 PASS project.2 PASS project.3 PASS project.4 PASS

If there are any failed parts, the output will read:

project.3 FAIL

In this case, consider restoring broken part from backup and re-testing. There are no methods to fix broken parts, but if there are enough "working" parts, you can restore. To restore, there needs to be 3 of the 5 parts undamaged.

Restore

Before you restore, ensure metadate file is located with parts. Example, metadata file named [archive_name].m

File structure:

archive.m archive.0 archive.1 archive.2 archive.3 archive.4

You can still restore if parts are missing. Let the program handle this.

ark -x /path/to/metadata_file.m -d /path/to/outputdir/

How this works.