[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Cluster-devel] cluster/group/tool main.c



CVSROOT:	/cvs/cluster
Module name:	cluster
Changes by:	teigland sourceware org	2006-07-25 20:09:58

Modified files:
	group/tool     : main.c 

Log message:
	'group_tool dump fence' will dump fenced's debug buffer

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/group/tool/main.c.diff?cvsroot=cluster&r1=1.17&r2=1.18

--- cluster/group/tool/main.c	2006/07/14 18:57:25	1.17
+++ cluster/group/tool/main.c	2006/07/25 20:09:58	1.18
@@ -32,8 +32,11 @@
 /* copied from cluster/group/gfs_controld/lock_dlm.h */
 #define LOCK_DLM_SOCK_PATH		"gfs_controld_sock"
 
+/* copied from cluster/fence/fenced/fd.h */
+#define FENCED_SOCK_PATH		"fenced_socket"
+
 /* needs to match the same in cluster/group/daemon/gd_internal.h and
-   cluster/group/gfs_controld/lock_dlm.h */
+   cluster/group/gfs_controld/lock_dlm.h and cluster/fence/fenced/fd.h */
 #define DUMP_SIZE			(1024 * 1024)
 
 /* needs to match the same in cluster/group/gfs_controld/lock_dlm.h,
@@ -329,7 +332,7 @@
 	return 0;
 }
 
-int do_gfsdump(int argc, char **argv, int fd)
+int do_maxline_dump(int argc, char **argv, int fd)
 {
 	char inbuf[DUMP_SIZE];
 	char outbuf[MAXLINE];
@@ -373,7 +376,14 @@
 				fd = connect_daemon(LOCK_DLM_SOCK_PATH);
 				if (fd < 0)
 					return -1;
-				return do_gfsdump(argc, argv, fd);
+				return do_maxline_dump(argc, argv, fd);
+			}
+
+			if (!strncmp(argv[opt_ind], "fence", 5)) {
+				fd = connect_daemon(FENCED_SOCK_PATH);
+				if (fd < 0)
+					return -1;
+				return do_maxline_dump(argc, argv, fd);
 			}
 		}
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]