[pve-devel] [PATCH] remove non used parameter exclusive
Wolfgang Link
w.link at proxmox.com
Wed Sep 16 13:11:18 CEST 2015
This makes no sense because it should always be exclusive.
Also RDB checks it self.
LVM has not possibility to use lvchange.
DRBD is this feature not implemented.
---
PVE/Storage.pm | 4 ++--
PVE/Storage/DRBDPlugin.pm | 2 +-
PVE/Storage/GlusterfsPlugin.pm | 2 +-
PVE/Storage/ISCSIDirectPlugin.pm | 4 ++--
PVE/Storage/LVMPlugin.pm | 6 +++---
PVE/Storage/Plugin.pm | 2 +-
PVE/Storage/RBDPlugin.pm | 4 ++--
PVE/Storage/SheepdogPlugin.pm | 4 ++--
PVE/Storage/ZFSPoolPlugin.pm | 4 ++--
9 files changed, 16 insertions(+), 16 deletions(-)
diff --git a/PVE/Storage.pm b/PVE/Storage.pm
index 927219a..7622b1a 100755
--- a/PVE/Storage.pm
+++ b/PVE/Storage.pm
@@ -831,7 +831,7 @@ sub deactivate_storage {
}
sub activate_volumes {
- my ($cfg, $vollist, $exclusive) = @_;
+ my ($cfg, $vollist) = @_;
return if !($vollist && scalar(@$vollist));
@@ -849,7 +849,7 @@ sub activate_volumes {
my ($storeid, $volname) = parse_volume_id($volid);
my $scfg = storage_config($cfg, $storeid);
my $plugin = PVE::Storage::Plugin->lookup($scfg->{type});
- $plugin->activate_volume($storeid, $scfg, $volname, $exclusive, $cache);
+ $plugin->activate_volume($storeid, $scfg, $volname, $cache);
}
}
diff --git a/PVE/Storage/DRBDPlugin.pm b/PVE/Storage/DRBDPlugin.pm
index 97c1ca9..c4a5ee1 100644
--- a/PVE/Storage/DRBDPlugin.pm
+++ b/PVE/Storage/DRBDPlugin.pm
@@ -296,7 +296,7 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
my $path = $class->path($scfg, $volname);
diff --git a/PVE/Storage/GlusterfsPlugin.pm b/PVE/Storage/GlusterfsPlugin.pm
index 6ad3a8f..dee34c3 100644
--- a/PVE/Storage/GlusterfsPlugin.pm
+++ b/PVE/Storage/GlusterfsPlugin.pm
@@ -300,7 +300,7 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
# do nothing by default
}
diff --git a/PVE/Storage/ISCSIDirectPlugin.pm b/PVE/Storage/ISCSIDirectPlugin.pm
index d20fbe2..cece023 100644
--- a/PVE/Storage/ISCSIDirectPlugin.pm
+++ b/PVE/Storage/ISCSIDirectPlugin.pm
@@ -184,12 +184,12 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
sub deactivate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
diff --git a/PVE/Storage/LVMPlugin.pm b/PVE/Storage/LVMPlugin.pm
index 87945a8..e59c4a9 100644
--- a/PVE/Storage/LVMPlugin.pm
+++ b/PVE/Storage/LVMPlugin.pm
@@ -421,11 +421,11 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
-
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
+ #fix me lvmchange is not provided on
my $path = $class->path($scfg, $volname);
- my $lvm_activate_mode = $exclusive ? 'ey' : 'ly';
+ my $lvm_activate_mode = 'ey';
my $cmd = ['/sbin/lvchange', "-a$lvm_activate_mode", $path];
run_command($cmd, errmsg => "can't activate LV '$path'");
diff --git a/PVE/Storage/Plugin.pm b/PVE/Storage/Plugin.pm
index 6741fec..a245192 100644
--- a/PVE/Storage/Plugin.pm
+++ b/PVE/Storage/Plugin.pm
@@ -831,7 +831,7 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
my $path = $class->filesystem_path($scfg, $volname);
diff --git a/PVE/Storage/RBDPlugin.pm b/PVE/Storage/RBDPlugin.pm
index 7b1ab1b..4fe6345 100644
--- a/PVE/Storage/RBDPlugin.pm
+++ b/PVE/Storage/RBDPlugin.pm
@@ -489,7 +489,7 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1 if !$scfg->{krbd};
@@ -506,7 +506,7 @@ sub activate_volume {
}
sub deactivate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1 if !$scfg->{krbd};
diff --git a/PVE/Storage/SheepdogPlugin.pm b/PVE/Storage/SheepdogPlugin.pm
index 2ffc7b7..4241742 100644
--- a/PVE/Storage/SheepdogPlugin.pm
+++ b/PVE/Storage/SheepdogPlugin.pm
@@ -345,12 +345,12 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
sub deactivate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
diff --git a/PVE/Storage/ZFSPoolPlugin.pm b/PVE/Storage/ZFSPoolPlugin.pm
index 75704b0..880d504 100644
--- a/PVE/Storage/ZFSPoolPlugin.pm
+++ b/PVE/Storage/ZFSPoolPlugin.pm
@@ -505,12 +505,12 @@ sub deactivate_storage {
}
sub activate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
sub deactivate_volume {
- my ($class, $storeid, $scfg, $volname, $exclusive, $cache) = @_;
+ my ($class, $storeid, $scfg, $volname, $cache) = @_;
return 1;
}
--
2.1.4
More information about the pve-devel
mailing list