summaryrefslogtreecommitdiff
path: root/scripts/vyatta-update-cluster.pl
diff options
context:
space:
mode:
authorAn-Cheng Huang <ancheng@vyatta.com>2008-04-07 15:06:40 -0700
committerAn-Cheng Huang <ancheng@vyatta.com>2008-04-07 15:06:40 -0700
commit90bfb8446d408313e9c73335889629e10e616265 (patch)
treeaac3967b9fc078297a802f04d7b431b776624b34 /scripts/vyatta-update-cluster.pl
parent63d4544c809b1fbfea9e40ef00bca1f963113c6a (diff)
downloadvyatta-cluster-90bfb8446d408313e9c73335889629e10e616265.tar.gz
vyatta-cluster-90bfb8446d408313e9c73335889629e10e616265.zip
fix for bugs 2970, 3109, 3110:
* replace output messages. * add interface checks.
Diffstat (limited to 'scripts/vyatta-update-cluster.pl')
-rwxr-xr-xscripts/vyatta-update-cluster.pl13
1 files changed, 10 insertions, 3 deletions
diff --git a/scripts/vyatta-update-cluster.pl b/scripts/vyatta-update-cluster.pl
index 56545e5..ada461f 100755
--- a/scripts/vyatta-update-cluster.pl
+++ b/scripts/vyatta-update-cluster.pl
@@ -74,8 +74,15 @@ foreach (@init_services) {
# restart clustering.
# using "stop" + "start" ("restart" will cause a long wait).
# (may need to change to "restart".)
-system("$HA_INIT stop");
-system("$HA_INIT start");
-
+print "Starting clustering...";
+system("$HA_INIT stop >&/dev/null");
+system("$HA_INIT start >&/dev/null");
+if ($? >> 8) {
+ print "\nError: Clustering failed to start.\n";
+ print "Please make sure all clustering interfaces are functional\n";
+ print "and retry the commit.\n";
+ exit 1;
+}
+print " Done\n";
exit 0;