Closed bdallen closed 5 years ago
I have a very similar issue, probably the same.
INFO: starting new backup job: vzdump --mailnotification failure --storage
I noticed that the 5.4 patch has introduced a change in that section, compared to the 5.3 patch:
@@ -421,10 +421,10 @@
- }
+ my $fullbackup = undef;
+ if ($opts->{fullbackup} && !$opts->{stdout}) {
++ my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime();
+ my $bklist = get_backup_file_list($opts->{dumpdir}, $bkname);
+ $bklist = [ sort { $b->[1] <=> $a->[1] } @$bklist ];
-+ my $mintime = timelocal ($lt->sec, $lt->min, $lt->hour,
-+ $lt->mday, $lt->mon, $lt->year) -
++ my $mintime = timelocal($sec, $min, $hour, $mday, $mon, $year) -
+ $opts->{fullbackup} * 24 * 60 * 60 -
+ 12 * 60 * 60; # - 12h just to make sure that on last day we create full backup
+
I can't explain why this new code doesn't work - it works when I tested it independently... But I'm wondering if the change is really necessary, because $lt is still initialised from localtime() just a few lines back.
I will try and revert this portion of the patch and see if it fixes the issue.
I confirm, this fixes the issue. Any since this is the only change in the 5.4-5 patch, it also means that the last patch that works for PVE 5.4-3 is patch 5.3-9.
For the OP and whomever will encounter the same error, the fix is as simple as this:
./pve-5.4-5-diff-backup-addon revert
./pve-5.3-9-diff-backup-addon apply
Like the OP, I thought I should wait for the first 5.4-x patch after migrating to PVE 5.4... but the latest 5.3 worked just fine. It's a bit counterintuitive, but makes sense.
I usually do small fixes and mark that against the version that patch was created, so sometimes the 5.4-5
might work with earlier versions.
I usually grab pve from pvetest
repo.
ERROR: Backup of VM 102 failed - Day '' out of range 1..31 at /usr/share/perl5/PVE/VZDump.pm line 824. INFO: stat: missing operand INFO: Try 'stat --help' for more information.
Full backup set to every 7, with Max Backups set to 14