kopia(1)
Kopia is a fast, secure, and efficient backup and restore tool that deduplicates data and supports multiple storage backends.
Synopsis
kopia [GLOBAL OPTIONS] COMMAND [COMMAND OPTIONS]Description
Kopia is a backup and restore utility designed for creating encrypted, deduplicated snapshots of files and directories. It supports local storage, cloud providers (AWS S3, Azure, Google Cloud), and network locations, making it flexible for various backup scenarios.
Data is automatically deduplicated at the block level, compressed, and encrypted, reducing storage costs while maintaining security. Kopia maintains a local index of all snapshots and provides efficient incremental backups.
Common workflows include creating snapshots, listing snapshots, restoring files, and managing retention policies across multiple storage backends.
Common options
| Flag | What it does |
|---|---|
-h, --help | Show help message and exit |
--log-level | Set logging level (debug, info, warning, error) |
--config-file | Path to configuration file (default: ~/.kopia/config.json) |
--password | Repository password for encryption/decryption |
--no-check-for-updates | Disable automatic update checks |
-q, --quiet | Suppress non-error output |
Examples
Initialize a new backup repository on local filesystem
kopia repository create filesystem --path /backup/storageCreate a snapshot of the documents directory
kopia snapshot create /home/user/documentsList all existing snapshots in the repository
kopia snapshot listRestore a complete snapshot to a specified directory
kopia snapshot restore <snapshot-id> --target-dir /restore/locationSet global retention policy: keep 10 latest and 30 daily snapshots
kopia policy set --global --keep-latest 10 --keep-daily 30Connect repository to AWS S3 bucket for cloud backups
kopia repository connect s3 --bucket my-bucket --endpoint s3.amazonaws.comShow differences between two snapshots
kopia diff <snapshot-id1> <snapshot-id2>Run maintenance tasks including cleanup and optimization
kopia maintenance run