2022-08-23 23:21:01 +00:00
|
|
|
Enhancement: Add compression support
|
2022-04-11 19:28:21 +00:00
|
|
|
|
2022-08-23 23:21:01 +00:00
|
|
|
We've added compression support to the restic repository format. To create a
|
2022-04-11 19:28:21 +00:00
|
|
|
repository using the new format run `init --repository-version 2`. Please note
|
|
|
|
that the repository cannot be read by restic versions prior to 0.14.0.
|
|
|
|
|
2022-08-23 23:21:01 +00:00
|
|
|
You can configure whether data is compressed with the option `--compression`. It
|
|
|
|
can be set to `auto` (the default, which will compress very fast), `max` (which
|
2022-04-13 18:38:30 +00:00
|
|
|
will trade backup speed and CPU usage for better compression), or `off` (which
|
|
|
|
disables compression). Each setting is only applied for the single run of restic.
|
2022-07-30 14:21:53 +00:00
|
|
|
The option can also be set via the environment variable `RESTIC_COMPRESSION`.
|
2022-04-13 18:38:30 +00:00
|
|
|
|
2022-05-09 20:39:02 +00:00
|
|
|
To upgrade in place run `migrate upgrade_repo_v2` followed by `prune`. See the
|
|
|
|
documentation for more details. The migration checks the repository integrity
|
2022-08-23 23:21:01 +00:00
|
|
|
and upgrades the repository format, but will not change any data. Afterwards,
|
2022-05-09 20:39:02 +00:00
|
|
|
prune will rewrite the metadata to make use of compression.
|
|
|
|
|
2022-08-23 23:21:01 +00:00
|
|
|
As an alternative you can use the `copy` command to migrate snapshots; First
|
|
|
|
create a new repository using
|
|
|
|
`init --repository-version 2 --copy-chunker-params --repo2 path/to/old/repo`,
|
|
|
|
and then use the `copy` command to copy all snapshots to the new repository.
|
2022-04-11 19:28:21 +00:00
|
|
|
|
|
|
|
https://github.com/restic/restic/issues/21
|
2022-06-04 22:25:19 +00:00
|
|
|
https://github.com/restic/restic/issues/3779
|
2022-04-11 19:28:21 +00:00
|
|
|
https://github.com/restic/restic/pull/3666
|
2022-06-04 22:25:19 +00:00
|
|
|
https://github.com/restic/restic/pull/3704
|
|
|
|
https://github.com/restic/restic/pull/3733
|