Gitweb:
http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=...
Commit: cdb8831463fd622a1bc24af5f9760ae0f456b039
Parent: a8cc8128e3bb815d2d8c7467929ee14b2edd92a6
Author: Jan Friesse <jfriesse(a)redhat.com>
AuthorDate: Mon Sep 27 15:20:16 2010 +0200
Committer: Fabio M. Di Nitto <fdinitto(a)redhat.com>
CommitterDate: Wed Jan 12 16:18:12 2011 +0100
Cman: Handle corosync exit codes
Resolves: rhbz#617247
---
cman/cman_tool/join.c | 32 +++++++++++++++++++-------------
1 files changed, 19 insertions(+), 13 deletions(-)
diff --git a/cman/cman_tool/join.c b/cman/cman_tool/join.c
index c6cf4ef..ed8b535 100644
--- a/cman/cman_tool/join.c
+++ b/cman/cman_tool/join.c
@@ -40,45 +40,51 @@ static const char *corosync_exit_reason(signed char status)
{
static char reason[256];
switch (status) {
- case -2:
+ case 1:
return "Could not determine UID to run as";
break;
- case -3:
+ case 2:
return "Could not determine GID to run as";
break;
- case -4:
+ case 3:
return "Error initialising memory pool";
break;
- case -5:
+ case 4:
return "Could not fork";
break;
- case -6:
+ case 5:
return "Could not bind to libais socket";
break;
- case -7:
+ case 6:
return "Could not bind to network socket";
break;
- case -8:
+ case 7:
return "Could not read security key for communications";
break;
- case -9:
+ case 8:
return "Could not read cluster configuration";
break;
- case -10:
+ case 9:
return "Could not set up logging";
break;
- case -11:
+ case 11:
return "Could not dynamically load modules";
break;
- case -12:
+ case 12:
return "Could not load and initialise object database";
break;
- case -13:
+ case 13:
return "Could not initialise all required services";
break;
- case -14:
+ case 14:
return "Out of memory";
break;
+ case 15:
+ return "Fatal error";
+ break;
+ case 16:
+ return "Required directory not present /var/lib/corosync.";
+ break;
default:
sprintf(reason, "Error, reason code is %d", status);
return reason;