dumptruck(8)
NAME
dumptruck — make and manage dump-style backups
SYNOPSIS
dumptruck [OPTION] PATH…
DESCRIPTION
dumptruck creates and manages dump(8)-style backups of volumes or directories, automatically handling levels and pruning of old backups. It supports the following backup methods:
- xfsdump
- Uses xfsdump(8) to dump the file system. Only works with a single PATH, which must be the root of an XFS volume.
- gnutar
-
Uses GNU tar(1) to archive one or more paths, using
--listed-incremental
to implement differential dump-style backups.
Backups are automatically compressed (with zstd(1)) and optionally encrypted (with age(1)). Notably, dumptruck does not require access to the private key at backup time, unlike most encrypted backup tools like kopia or restic; this comes with several tradeoffs, such as no support for deduplication.
OPTIONS
Following are the options supported by dumptruck. Many can also be configured with environment variables, listed in parentheses; this is particularly useful when setting up backups in a systemd service.
- -c, --cleanup
- Clean up old backups according to the expiration policy.
- -d, --backup-dir DIR
(
$BACKUP_DIR
) - Store backups in in DIR.
- -E, --encrypt-to FILE
(
$RECIPIENT_FILE
) - Encrypt backups to the Age recipients listed in FILE. Defaults to the file recipients.txt in the backup directory.
- --list
- List backups instead of creating new backups.
- -L, --level LEVEL
(
$BACKUP_LEVEL
) - Specify the backup level (0–9, but usually 0–2). The default is automatically detected according to a backup schedule.
- -m, --method METHOD
(
$BACKUP_METHOD
) - Use backup method METHOD (gnutar or xfsdump). Defaults to gnutar.
- -n, --dry-run
- Don’t back up, only print what would be done.
- -N, --name NAME
(
$BACKUP_NAME
) - Name backups NAME (default: “backup”).
- --rage
-
Encrypt with rage(1) instead of age(1). Support for
rage can also be invoked by setting the environment variable
AGE=rage
. - -S, --backup-schedule NAME
- Use the backup schedule named NAME.
- -W, --work-dir DIR
(
$BACKUP_WORK
) -
Persistent work directory for backup cache files (default:
/var/lib/dumptruck). Currently only needed by the
tar backend (to store the files needed by
--listed-incremental
). - -x, --one-file-system
- Don’t cross filesystem boundaries when backing up. This option is only respected by the gnutar backend; xfsdump is always limited to one FS. This option is the default.
- -X, --cross-fs-boundaries
- Cross filesystem boundaries when backed up. Not supportred by the xfsdump backend.
SCHEDULES
dumptruck
has two builtin backup schedules for level
selection and backup pruning.
Monthly
The monthly backup schedule (the default) is based on monthly full backups.
Level | Frequency | Retain |
---|---|---|
0 | monthly | 12 |
1 | weekly | 5 |
2 | daily | 10 |
3 | 12 |
Yearly
The yearly backup schedule is based on yearly full backups.
Level | Frequency | Retain |
---|---|---|
0 | yearly | 5 |
1 | monthly | 12 |
2 | weekly | 5 |
3 | daily | 10 |
4 | 12 |
REQUIREMENTS
dumptruck requires the following software installed:
- zsh(1) (dumptruck is implemented as a Z shell script)
- zstd(1) to compress backups
- age(1) to encrypt backups
- GNU tar(1), when using the tar backup method
- xfsdump(8), when using the xfsdump backup method
BUGS
- Only zstd(1) compression is supported (but why use anything else?).
- The expiration policy cannot yet be configured.
- The backup schedule cannot yet be configured.
- BSD dump(8) is not yet supported. There is no reason why it shouldn’t work, it just hasn’t been tested.
SEE ALSO
age(1), xfsdump(8), tar(1)