public inbox for cluster-cvs@sourceware.org help / color / mirror / Atom feed
From: Lon Hohberger <lon@fedoraproject.org> To: cluster-cvs-relay@redhat.com Subject: RHEL5 - Revert "rgmanager: Implement wait-for-fence behavior" Date: Thu, 28 Aug 2008 19:57:00 -0000 [thread overview] Message-ID: <20080828193528.9C8B5120379@lists.fedorahosted.org> (raw) Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=65fc562dc3fca9b0f32a4dd2654dce31bcd6842b Commit: 65fc562dc3fca9b0f32a4dd2654dce31bcd6842b Parent: b856823dbc6310e3c4742bf986bf2fa991cdc334 Author: Lon Hohberger <lhh@redhat.com> AuthorDate: Thu Aug 28 15:35:22 2008 -0400 Committer: Lon Hohberger <lhh@redhat.com> CommitterDate: Thu Aug 28 15:35:22 2008 -0400 Revert "rgmanager: Implement wait-for-fence behavior" This reverts commit b856823dbc6310e3c4742bf986bf2fa991cdc334. This was done badly; we don't want libgroup as a shared library. --- group/lib/Makefile | 17 +++-------------- rgmanager/src/daemons/Makefile | 6 +++--- rgmanager/src/daemons/main.c | 25 +------------------------ rgmanager/src/daemons/rg_event.c | 21 --------------------- 4 files changed, 7 insertions(+), 62 deletions(-) diff --git a/group/lib/Makefile b/group/lib/Makefile index 733109a..fb86073 100644 --- a/group/lib/Makefile +++ b/group/lib/Makefile @@ -13,36 +13,25 @@ SOURCE=libgroup.c LIBNAME=libgroup -SHAREDLIB=$(LIBNAME).so.${RELEASE_MAJOR}.${RELEASE_MINOR} STATICLIB=$(LIBNAME).a top_srcdir=.. UNINSTALL=${top_srcdir}/scripts/uninstall.pl -include ${top_srcdir}/make/defines.mk +# include ${top_srcdir}/make/defines.mk CFLAGS += -g -O -I. -fPIC -I../daemon -all: $(STATICLIB) $(SHAREDLIB) +all: $(STATICLIB) $(LIBNAME).a: libgroup.o ${AR} r libgroup.a libgroup.o - ${RANLIB} libgroup.a - -$(LIBNAME).so.${RELEASE_MAJOR}.${RELEASE_MINOR}: libgroup.o - $(CC) -shared -o $@ -Wl,-soname=$(LIBNAME).so.$(RELEASE_MAJOR) $^ +# ${RANLIB} libgroup.a libgroup.o: libgroup.c $(CC) $(CFLAGS) -c -o $@ $< -I../daemon install: all - install -d ${incdir} - install libgroup.h ${incdir} - install -d ${libdir} - install $(LIBNAME).a ${libdir} - install $(LIBNAME).so.$(RELEASE_MAJOR).$(RELEASE_MINOR) ${libdir} - ln -sf $(LIBNAME).so.$(RELEASE_MAJOR).$(RELEASE_MINOR) ${libdir}/$(LIBNAME).so - ln -sf $(LIBNAME).so.$(RELEASE_MAJOR).$(RELEASE_MINOR) ${libdir}/$(LIBNAME).so.$(RELEASE_MAJOR) uninstall: diff --git a/rgmanager/src/daemons/Makefile b/rgmanager/src/daemons/Makefile index b743de7..5812fe6 100644 --- a/rgmanager/src/daemons/Makefile +++ b/rgmanager/src/daemons/Makefile @@ -14,12 +14,12 @@ top_srcdir=../.. UNINSTALL=${top_srcdir}/scripts/uninstall.pl include ${top_srcdir}/make/defines.mk -INCLUDE += -I $(top_srcdir)/include -I $(top_srcdir)/../cman/lib -I $(top_srcdir)/../ccs/lib -I $(top_srcdir)/../dlm/lib -I $(top_srcdir)/../group/lib +INCLUDE += -I $(top_srcdir)/include -I $(top_srcdir)/../cman/lib -I $(top_srcdir)/../ccs/lib -I $(top_srcdir)/../dlm/lib INCLUDE += -I${incdir} -I/usr/include/libxml2 -I/usr/include/slang CFLAGS+= -g -Wstrict-prototypes -Wshadow -fPIC -D_GNU_SOURCE -DWRAP_THREADS -Wall -Wextra -LDFLAGS+= -L ../clulib -L../../../cman/lib -L../../../ccs/lib -L../../../dlm/lib -L../../../group/lib -L${libdir} -lclulib -lxml2 -lpthread -ldl -Wl,-wrap,pthread_create,-wrap,pthread_exit +LDFLAGS+= -L ../clulib -L../../../cman/lib -L../../../ccs/lib -L../../../dlm/lib -L${libdir} -lclulib -lxml2 -lpthread -ldl -Wl,-wrap,pthread_create,-wrap,pthread_exit -rdynamic TARGETS=clurgmgrd clurmtabd rg_test all: ${TARGETS} @@ -41,7 +41,7 @@ clurgmgrd: rg_thread.o rg_locks.o main.o groups.o \ rg_event.o watchdog.o rg_state.o event_config.o \ slang_event.o service_op.o restart_counter.o \ ../clulib/libclulib.a - $(CC) -o $@ $^ $(INCLUDE) $(CFLAGS) $(LDFLAGS) -lccs -lcman -lgroup -lpthread -ldlm -lslang + $(CC) -o $@ $^ $(INCLUDE) $(CFLAGS) $(LDFLAGS) -lccs -lcman -lpthread -ldlm -lslang rg_script_test: slang_event.o $(CC) -o rg_script_test slang_event.o $(INCLUDE) $(CFLAGS) -lslang $(LDFLAGS) diff --git a/rgmanager/src/daemons/main.c b/rgmanager/src/daemons/main.c index b722ab2..8401bca 100644 --- a/rgmanager/src/daemons/main.c +++ b/rgmanager/src/daemons/main.c @@ -60,9 +60,6 @@ int svc_exists(char *); int watchdog_init(void); int32_t master_event_callback(char *key, uint64_t viewno, void *data, uint32_t datalen); -int node_has_fencing(int nodeid); -int fence_domain_joined(void); - int shutdown_pending = 0, running = 1, need_reconfigure = 0; char debug = 0; /* XXX* */ static int signalled = 0; @@ -912,25 +909,7 @@ clu_initialize(cman_handle_t *ch) while (cman_is_quorate(*ch) == 0) { sleep(1); } - clulog(LOG_NOTICE, "Quorum formed\n"); - } - -} - - -void -wait_for_fencing(void) -{ - if (node_has_fencing(my_id()) && !fence_domain_joined()) { - clulog(LOG_INFO, "Waiting for fence domain join operation " - "to complete\n"); - - while (fence_domain_joined() == 0) - sleep(1); - clulog(LOG_INFO, "Fence domain joined\n"); - } else { - clulog(LOG_DEBUG, "Fence domain already joined " - "or no fencing configured\n"); + clulog(LOG_NOTICE, "Quorum formed, starting\n"); } } @@ -1039,8 +1018,6 @@ main(int argc, char **argv) clulog(LOG_INFO, "I am node #%d\n", my_id()); - wait_for_fencing(); - /* We know we're quorate. At this point, we need to read the resource group trees from ccsd. diff --git a/rgmanager/src/daemons/rg_event.c b/rgmanager/src/daemons/rg_event.c index f8fcc1e..f614668 100644 --- a/rgmanager/src/daemons/rg_event.c +++ b/rgmanager/src/daemons/rg_event.c @@ -27,7 +27,6 @@ #include <stdint.h> #include <vf.h> #include <members.h> -#include <libgroup.h> /** @@ -175,26 +174,6 @@ node_has_fencing(int nodeid) } -/* Shameless cut-and-paste from gfs_controld */ -int -fence_domain_joined(void) -{ - group_data_t data; - int rv; - - memset(&data, 0, sizeof(data)); - - rv = group_get_group(0, "default", &data); - - if (rv || strcmp(data.client_name, "fence")) - return 0; - - if (data.member == 1) - return 1; - return 0; -} - - /** Quick query to cman to see if a node has been fenced. */
reply other threads:[~2008-08-28 19:36 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20080828193528.9C8B5120379@lists.fedorahosted.org \ --to=lon@fedoraproject.org \ --cc=cluster-cvs-relay@redhat.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).