[pve-devel] [PATCH cluster v3 02/14] tell cluster log when adding/deleting a node
Thomas Lamprecht
t.lamprecht at proxmox.com
Tue Dec 19 12:52:27 CET 2017
---
new in v3
data/PVE/API2/ClusterConfig.pm | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/data/PVE/API2/ClusterConfig.pm b/data/PVE/API2/ClusterConfig.pm
index fa01022..5b0aca8 100644
--- a/data/PVE/API2/ClusterConfig.pm
+++ b/data/PVE/API2/ClusterConfig.pm
@@ -216,6 +216,8 @@ __PACKAGE__->register_method ({
$nodelist->{$name}->{ring1_addr} = $param->{ring1_addr} if $param->{ring1_addr};
$nodelist->{$name}->{quorum_votes} = $param->{votes} if $param->{votes};
+ PVE::Cluster::log_msg('notice', 'root at pam', "adding node $name to cluster");
+
PVE::Corosync::update_nodelist($conf, $nodelist);
};
@@ -273,6 +275,8 @@ __PACKAGE__->register_method ({
die "Node/IP: $param->{node} is not a known host of the cluster.\n"
if !defined($node);
+ PVE::Cluster::log_msg('notice', 'root at pam', "deleting node $node from cluster");
+
delete $nodelist->{$node};
PVE::Corosync::update_nodelist($conf, $nodelist);
--
2.11.0
More information about the pve-devel
mailing list