Found the bug, i hope that Dietmar will be so kind to include the solution.
/usr/share/perl5/PVE/API2/VZDump.pm
This code says that the exclude-path is ALWAYS read from command-line
and despite each line in /etc/vzdump.conf will be skipped
the solution?
this one:
when the cmdline does not contain exclude-path the conf will be read
of course even the other parameters should be verified...
for example mailto and so on
/etc/vzdump.conf
exclude-path: /usr/.+ /sbin/.+ /var/.+
And now it works
Diaolin
(Here the solution for 1.* versions)
/usr/share/perl5/PVE/VZDump.pm
Change:
in
/usr/share/perl5/PVE/API2/VZDump.pm
This code says that the exclude-path is ALWAYS read from command-line
and despite each line in /etc/vzdump.conf will be skipped
Code:
# exclude-path list need to be 0 separated
my @expaths = split(/\0/, $param->{'exclude-path'} || '');
$param->{'exclude-path'} = [ @expaths ];
the solution?
this one:
Code:
# exclude-path list need to be 0 separated
if (exists($param->{'exclude-path'})) {
my @expaths = split(/\0/, $param->{'exclude-path'} || '');
$param->{'exclude-path'} = [ @expaths ];
}
when the cmdline does not contain exclude-path the conf will be read
of course even the other parameters should be verified...
for example mailto and so on
/etc/vzdump.conf
exclude-path: /usr/.+ /sbin/.+ /var/.+
And now it works
Diaolin
(Here the solution for 1.* versions)
/usr/share/perl5/PVE/VZDump.pm
Change:
Code:
foreach my $k (keys %$defaults) {
if ($k eq 'dumpdir' || $k eq 'storage') {
$opts->{$k} = $defaults->{$k} if !defined ($opts->{dumpdir}) &&
!defined ($opts->{storage});
} else {
$opts->{$k} = $defaults->{$k} if !defined ($opts->{$k});
}
}
in
Code:
foreach my $k (keys %$defaults) {
if ($k eq 'dumpdir' || $k eq 'storage') {
$opts->{$k} = $defaults->{$k} if !defined ($opts->{dumpdir}) &&
!defined ($opts->{storage});
} else {
if (!defined ($opts->{$k}) or !$opts->{$k}) { $opts->{$k} = $defaults->{$k}; }
}
}
Last edited: