Duplicity 2.0.0 does not autodetect to use full or inc
I have:
- ([x] when completed)
-
searched https://gitlab.com/duplicity/duplicity/-/issues for similar issues. If you find a similar issue and the issue is still open, add a comment to the existing issue instead of opening a new one. If you find a Closed issue that seems like it is the same thing that you're experiencing, open a new issue and include a link to the original issue in the body of your new one. -
tested that this issue still occurs on the latest stable snap (install instructions: https://snapcraft.io/duplicity), please include the snap version ( snap info duplicity | grep installed
) output:installed: x.xx.xx (xx)
-
ideally, tested that this issue still occurs on the latest edge snap, if you can test without risking your data. Please include the snap version output: installed: x.xx.xx (xx)
Summary
Rely on duplicity to auto-detect whether to run an incremental or full backup based on --full-if-older-than option. This is broken in 2.0.0-ppa202308071821~ubuntu20.04.1.
The full or incremental option must be specified before SRC and DEST in 2.0.0.
Environment
Ubuntu 20.04
duplicity --version duplicity 2.0.0
duplicity command duplicity --verbosity info --archive-dir /var/backups/duplicity/ --full-if-older-than 7D --num-retries 3 --no-encryption --volsize 1024 /var/backups/mysql/localhost swift://object_storage
Steps to reproduce
Upgrade from duplicity:amd64 (1.2.3-ppa202305091626ubuntu20.04.1, 2.0.0-ppa202308071821ubuntu20.04.1)
Run a previously running backup that relied on --full-if-older-than to determine whether to run full or incremental backup.
What is the current bug behaviour?
get error message:
usage: duplicity [-h] [--allow-source-mismatch] [--archive-dir path] [--asynchronous-upload]
[--azure-blob-tier Hot|Cool|Archive] [--azure-max-block-size number] [--azure-max-connections number]
[--azure-max-single-put-size number] [--b2-hide-files] [--backend-retry-delay seconds]
[--cf-backend pyrax|cloudfiles] [--compare-data] [--config-dir path] [--copy-blocksize number]
[--copy-links] [--dry-run] [--encrypt-key gpg-key-id] [--encrypt-secret-keyring path]
[--exclude shell_pattern] [--exclude-device-files] [--exclude-filelist filename]
[--exclude-if-present filename] [--exclude-older-than time] [--exclude-other-filesystems]
[--exclude-regexp regex] [--file-changed path] [--file-prefix string] [--file-prefix-archive string]
[--file-prefix-manifest string] [--file-prefix-signature string] [--files-from filename]
[--filter-globbing] [--filter-ignorecase] [--filter-literal] [--filter-regexp] [--filter-strictcase]
[--force] [--ftp-passive] [--ftp-regular] [--full-if-older-than time] [--gpg-binary path]
[--gpg-options options] [--hidden-encrypt-key gpg-key-id] [--idr-fakeroot path] [--ignore-errors]
[--imap-full-address] [--imap-mailbox imap_mailbox] [--include shell_pattern]
[--include-filelist filename] [--include-regexp regex] [--log-fd file_descriptor]
[--log-file log_filename] [--log-timestamp] [--max-blocksize number]
[--metadata-sync-mode {full,partial}] [--mf-purge] [--mp-segment-size number] [--name backup name]
[--no-compression] [--no-encryption] [--no-files-changed] [--no-print-statistics]
[--no-restore-ownership] [--null-separator] [--num-retries number] [--numeric-owner]
[--par2-options options] [--par2-redundancy number] [--par2-volumes number] [--path-to-restore path]
[--progress] [--progress-rate number] [--rename from to from to] [--restore-time time]
[--rsync-options options] [--s3-endpoint-url s3_endpoint_url] [--s3-kms-grant s3_kms_grant]
[--s3-kms-key-id s3_kms_key_id] [--s3-multipart-chunk-size number] [--s3-multipart-max-procs number]
[--s3-region-name s3_region_name] [--s3-unencrypted-connection] [--s3-use-deep-archive]
[--s3-use-glacier] [--s3-use-glacier-ir] [--s3-use-ia] [--s3-use-onezone-ia] [--s3-use-rrs]
[--s3-use-server-side-kms-encryption] [--scp-command command] [--sftp-command command]
[--show-changes-in-set number] [--sign-key gpg-key-id] [--ssh-askpass] [--ssh-options options]
[--ssl-cacert-file file] [--ssl-cacert-path path] [--ssl-no-check-certificate]
[--swift-storage-policy policy] [--tempdir path] [--time-separator char] [--timeout seconds]
[--use-agent] [--verbosity verb] [--version] [--volsize number] [--webdav-headers string]
{cleanup,cl,collection-status,st,full,fb,incremental,inc,ib,list-current-files,ls,remove-all-but-n-full,ra,remove-all-inc-of-but-n-full,ri,remove-older-than,ro,restore,rb,verify,vb}
...
duplicity: error: invalid choice: '/var/backups/mysql/localhost' (choose from 'cleanup', 'cl', 'collection-status', 'st', 'full', 'fb', 'incremental', 'inc', 'ib', 'list-current-files', 'ls', 'remove-all-but-n-full', 'ra', 'remove-all-inc-of-but-n-full', 'ri', 'remove-older-than', 'ro', 'restore', 'rb', 'verify', 'vb')
Using temporary directory /tmp/duplicity-3vollsvg-tempdir
What is the expected correct behaviour?
Commencement of backup:
Local and Remote metadata are synchronized, no sync needed.
Last full backup date: Tue Aug 1 02:54:02 2023
--------------[ Backup Statistics ]--------------
StartTime 1691420045.54 (Tue Aug 8 02:54:05 2023)
EndTime 1691420045.69 (Tue Aug 8 02:54:05 2023)
ElapsedTime 0.16 (0.16 seconds)
SourceFiles 395
SourceFileSize 39112470 (37.3 MB)
NewFiles 21
NewFileSize 1839011 (1.75 MB)
DeletedFiles 14
ChangedFiles 0
ChangedFileSize 0 (0 bytes)
ChangedDeltaSize 0 (0 bytes)
DeltaEntries 35
RawDeltaSize 1810339 (1.73 MB)
TotalDestinationSizeChange 1809906 (1.73 MB)
Errors 0
-------------------------------------------------
Relevant logs and/or screenshots
(Paste any relevant logs - please use code blocks (```) to format console output, logs, and code as it's very hard to read otherwise.)
Possible fixes
Put version 1.2.3 back in the ppa, autoparse the --full-if-older-than option in version 2.0.
Formatting
PLEASE DO NOT copy/paste long listings to the issue. Use the attach file option to attach a file instead. This makes it much easier to read and to process by the developers.