[pve-devel] [PATCH container 3/3] use COMMON_TAR_FLAGS from pve-storage

Wolfgang Bumiller w.bumiller at proxmox.com
Mon Jun 26 09:33:00 CEST 2017


---
 src/PVE/LXC.pm        | 6 ------
 src/PVE/LXC/Create.pm | 2 +-
 src/PVE/VZDump/LXC.pm | 2 +-
 3 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/src/PVE/LXC.pm b/src/PVE/LXC.pm
index 32b0318..8d91b22 100644
--- a/src/PVE/LXC.pm
+++ b/src/PVE/LXC.pm
@@ -32,12 +32,6 @@ my $nodename = PVE::INotify::nodename();
 
 my $cpuinfo= PVE::ProcFSTools::read_cpuinfo();
 
-our $COMMON_TAR_FLAGS = [ '--sparse', '--numeric-owner', '--acls',
-                          '--xattrs',
-                          '--xattrs-include=user.*',
-                          '--xattrs-include=security.capability',
-                          '--warning=no-xattr-write' ];
-
 sub config_list {
     my $vmlist = PVE::Cluster::get_vmlist();
     my $res = {};
diff --git a/src/PVE/LXC/Create.pm b/src/PVE/LXC/Create.pm
index 8b9e876..b87cfc9 100644
--- a/src/PVE/LXC/Create.pm
+++ b/src/PVE/LXC/Create.pm
@@ -74,7 +74,7 @@ sub restore_archive {
     }
 
     my $cmd = [@$userns_cmd, 'tar', 'xpf', $tar_input_file, '--totals',
-               @$PVE::LXC::COMMON_TAR_FLAGS,
+               @PVE::Storage::Plugin::COMMON_TAR_FLAGS,
                '-C', $rootdir];
 
     # skip-old-files doesn't have anything to do with time (old/new), but is
diff --git a/src/PVE/VZDump/LXC.pm b/src/PVE/VZDump/LXC.pm
index fafffc6..45a851c 100644
--- a/src/PVE/VZDump/LXC.pm
+++ b/src/PVE/VZDump/LXC.pm
@@ -331,7 +331,7 @@ sub archive {
 
     my $userns_cmd = $task->{userns_cmd};
     my $tar = [@$userns_cmd, 'tar', 'cpf', '-', '--totals',
-               @$PVE::LXC::COMMON_TAR_FLAGS,
+               @PVE::Storage::Plugin::COMMON_TAR_FLAGS,
                '--one-file-system', '--warning=no-file-ignored'];
 
     # note: --remove-files does not work because we do not 
-- 
2.11.0





More information about the pve-devel mailing list