Package: backup-manager
Version: 0.7.9-4
Severity: normal
Tags: patch
Hi,
I had configured backup-manager to do incremental backups with a full backup
on the 23th of each month. I noticed that this did not work because
backup-manager:
- expects the value to be between 0 and 6 (this is only reasonable for
weekly
backups)
- tries to fix this by setting the value to 0 (which also only works for
weekly backups)
Here is the relevant configuration which did not work
# Which frequency to use for the master tarball?
# possible values: weekly, monthly
export BM_TARBALLINC_MASTERDATETYPE="monthly"
# Number of the day, in the BM_TARBALLINC_MASTERDATETYPE frequency
# when master tarballs should be made
export BM_TARBALLINC_MASTERDATEVALUE="23"
And here is a small patch which adjusts the limits for monthly backups
--- /usr/share/backup-manager/sanitize.sh 2012-12-23
01:09:31.460859354 +0100
+++ /usr/share/backup-manager/sanitize.sh 2012-12-23
01:18:15.100111361 +0100
@@ -160,11 +160,22 @@
[[ -z "$BM_TARBALLINC_MASTERDATETYPE" ]]; then
confkey_require "BM_TARBALLINC_MASTERDATETYPE" "weekly"
fi
+
+# check if the date on which the backup is supposed to run is a valid one
if [[ -n "$BM_TARBALLINC_MASTERDATEVALUE" ]]; then
+ # if we have a monthly backup the limit is 31 and the fallback 1
+ if [[ "$BM_TARBALLINC_MASTERDATETYPE" = "monthly" ]]; then
+ if [[ "$BM_TARBALLINC_MASTERDATEVALUE" -gt "31" ]]; then
+ warning "BM_TARBALLINC_MASTERDATEVALUE should not be greater
than 31 (or 29 to be safe), falling back to 1"
+ export BM_TARBALLINC_MASTERDATEVALUE="1"
+ fi
+ else
+ # if we have a weekly backup the limit is 6 and the fallback 0
if [[ "$BM_TARBALLINC_MASTERDATEVALUE" -gt "6" ]]; then
warning "BM_TARBALLINC_MASTERDATEVALUE should not be greater
than 6, falling back to 0"
export BM_TARBALLINC_MASTERDATEVALUE="0"
fi
+ fi
fi
if [[ "$BM_ARCHIVE_METHOD" = "tarball" ]] ||
Kind regards
Thorsten
-- System Information:
Debian Release: 6.0.6
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.32-5-vserver-amd64 (SMP w/3 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages backup-manager depends on:
ii debconf [debconf-2.0] 1.5.36.1 Debian configuration
management sy
ii findutils 4.4.2-1+b1 utilities for finding
files--find,
ii ucf 3.0025+nmu1 Update Configuration File:
preserv
backup-manager recommends no packages.
Versions of packages backup-manager suggests:
ii anacron 2.3-14 cron-like program that
doesn't go
pn backup-manager-doc <none> (no description available)
pn dar <none> (no description available)
ii dvd+rw-tools 7.1-6 DVD+-RW/R tools
ii genisoimage 9:1.1.11-1 Creates ISO-9660 CD-ROM
filesystem
ii gettext-base 0.18.1.1-3 GNU Internationalization
utilities
pn libfile-slurp-perl <none> (no description available)
pn libnet-amazon-s3-perl <none> (no description available)
ii openssh-client 1:5.5p1-6+squeeze2 secure shell (SSH) client,
for sec
ii perl 5.10.1-17squeeze3 Larry Wall's Practical
Extraction
pn wodim <none> (no description available)
pn zip <none> (no description available)
-- debconf information excluded
--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org