From 6bcc16d70e4922d486bb494e86426d64ea3f4485 Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Tue, 2 Oct 2012 13:35:10 +0200 Subject: [PATCH] create 'dump' directory if storage contains containers This is needed by openvz migrate to store state. --- Makefile | 2 +- PVE/Storage/Plugin.pm | 9 ++++++--- changelog.Debian | 6 ++++++ 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 5ec2dc2..1de6e25 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ RELEASE=2.2 VERSION=2.0 PACKAGE=libpve-storage-perl -PKGREL=32 +PKGREL=33 DESTDIR= PREFIX=/usr diff --git a/PVE/Storage/Plugin.pm b/PVE/Storage/Plugin.pm index 41427c5..08e505e 100644 --- a/PVE/Storage/Plugin.pm +++ b/PVE/Storage/Plugin.pm @@ -621,9 +621,12 @@ sub activate_storage { if (defined($scfg->{content})) { foreach my $vtype (keys %$vtype_subdirs) { - next if !defined($scfg->{content}->{$vtype}); - my $subdir = $class->get_subdir($scfg, $vtype); - mkpath $subdir if $subdir ne $path; + # OpenVZMigrate uses backup (dump) dir + if (defined($scfg->{content}->{$vtype}) || + ($vtype eq 'backup' && defined($scfg->{content}->{'rootdir'}))) { + my $subdir = $class->get_subdir($scfg, $vtype); + mkpath $subdir if $subdir ne $path; + } } } } diff --git a/changelog.Debian b/changelog.Debian index e424790..7adff92 100644 --- a/changelog.Debian +++ b/changelog.Debian @@ -1,3 +1,9 @@ +libpve-storage-perl (2.0-33) unstable; urgency=low + + * create 'dump' directory if storage contains containers + + -- Proxmox Support Team Tue, 02 Oct 2012 13:36:35 +0200 + libpve-storage-perl (2.0-32) unstable; urgency=low * qcow2 : preallocate metadatas at file creation