Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=a5875267a2eb0…
Commit: a5875267a2eb0137dc7a123340db44d42dee4ee9
Parent: 3f3ea2f4404ecc13e64368842bd91ea3ba881004
Author: J.H.M. Dassen (Ray) <rdassen(a)redhat.com>
AuthorDate: Tue Feb 5 09:53:30 2013 +0100
Committer: Ryan McCabe <rmccabe(a)redhat.com>
CommitterDate: Fri Apr 12 14:13:48 2013 -0400
rgmanager: Clean up comments in ASEHAagent.sh
Correct string reference in comment
Resolves: rhbz#841142
Acked-by: Ryan McCabe <rmccabe(a)redhat.com>
---
rgmanager/src/resources/ASEHAagent.sh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/rgmanager/src/resources/ASEHAagent.sh b/rgmanager/src/resources/ASEHAagent.sh
index bc5df42..489d49b 100755
--- a/rgmanager/src/resources/ASEHAagent.sh
+++ b/rgmanager/src/resources/ASEHAagent.sh
@@ -532,7 +532,7 @@ EOF
t=0
while [[ $t -lt $OCF_RESKEY_shutdown_timeout ]]
do
- # Search "usshutdown: exiting" in the server log. If found, it means the server has been shutted down.
+ # Search "ueshutdown: exiting" in the server log. If found, it means the server has been shutted down.
# Otherwise, we need to wait.
tail $CONSOLE_LOG | grep "ueshutdown: exiting" > /dev/null 2>&1
if [[ $? != 0 ]]
Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=02ae12174d1c1…
Commit: 02ae12174d1c1908acb53c67cb04d26a3d19b536
Parent: efdb438ad868b447e28cde5959530b5dc763186f
Author: Ryan McCabe <rmccabe(a)redhat.com>
AuthorDate: Tue Feb 26 11:36:04 2013 -0500
Committer: Ryan McCabe <rmccabe(a)redhat.com>
CommitterDate: Fri Apr 12 11:05:46 2013 -0400
rgmanager: Don't duplicate configuration change events
If a cluster configuration change is detected while there are events
on the event queue that take some time to process, a large number of
duplicate configuration update events are put onto the event queue.
With a large number of services and a small status poll interval,
thousands of duplicate events can be put onto the queue.
This patch causes rgmanager to queue only one config event per detected
configuration change.
Signed-off-by: Ryan McCabe <rmccabe(a)redhat.com>
---
rgmanager/src/daemons/main.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/rgmanager/src/daemons/main.c b/rgmanager/src/daemons/main.c
index 1c7f746..59150c3 100644
--- a/rgmanager/src/daemons/main.c
+++ b/rgmanager/src/daemons/main.c
@@ -73,6 +73,7 @@ static int port = RG_PORT;
static char *rgmanager_lsname = "rgmanager"; /* XXX default */
static int status_poll_interval = DEFAULT_CHECK_INTERVAL;
static int stops_queued = 0;
+static int lastqver = 0;
int next_node_id(cluster_member_list_t *membership, int me);
@@ -750,7 +751,7 @@ dump_internal_state(int fd)
int
event_loop(msgctx_t *localctx, msgctx_t *clusterctx)
{
- int n = 0, max, ret, oldver, newver;
+ int n = 0, max, ret, oldver = 0, newver = 0;
fd_set rfds;
msgctx_t *newctx;
struct timeval tv;
@@ -826,9 +827,14 @@ event_loop(msgctx_t *localctx, msgctx_t *clusterctx)
return 0;
if (need_reconfigure || check_config_update(&oldver, &newver)) {
+ /* Only queue configuration events once per detected config update */
+ if (!need_reconfigure && newver <= lastqver)
+ return 0;
+
need_reconfigure = 0;
configure_rgmanager(-1, 0, NULL);
config_event_q(oldver, newver);
+ lastqver = newver;
return 0;
}
Gitweb: http://git.fedorahosted.org/git/?p=gfs2-utils.git;a=commitdiff;h=b1b7518680…
Commit: b1b751868059ebc1188de3e13db1eadbb5ede16c
Parent: 9c6977dae8082767f07f96f1c29672556fa062bf
Author: Andrew Price <anprice(a)redhat.com>
AuthorDate: Tue Apr 9 16:52:25 2013 +0100
Committer: Andrew Price <anprice(a)redhat.com>
CommitterDate: Tue Apr 9 16:52:25 2013 +0100
gfs2-utils: Build system fixes
Previously we were disabling the whole test suite when check isn't
installed but tool_tests.sh doesn't require it so the conditional has
been moved into tests/Makefile.am so that tool_tests.sh is always
enabled.
Also fixes a problem where AC_PROG_YACC allowed the build to continue
when bison was not installed but byacc was. We use bison-specific
features so a specific check for bison has been added.
Signed-off-by: Andrew Price <anprice(a)redhat.com>
---
Makefile.am | 6 +-----
configure.ac | 5 ++++-
tests/Makefile.am | 6 +++++-
3 files changed, 10 insertions(+), 7 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 3cd0b85..210ab15 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -16,11 +16,7 @@ if BUILD_GFS_CONTROLD
DIR_GROUP = group
endif
-if BUILD_TESTS
-DIR_TESTS = tests
-endif
-
-SUBDIRS = po $(DIR_GROUP) gfs2 doc $(DIR_TESTS)
+SUBDIRS = po $(DIR_GROUP) gfs2 doc tests
install-exec-local:
$(INSTALL) -d $(DESTDIR)/$(LOGDIR)
diff --git a/configure.ac b/configure.ac
index b24fc86..45b38eb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -58,7 +58,8 @@ AC_PROG_LN_S
AC_PROG_INSTALL
AC_PROG_MAKE_SET
AC_PROG_LEX
-AC_PROG_YACC
+AC_CHECK_PROG([YACC], [bison], [bison -y])
+test x"$YACC" = x && AC_MSG_ERROR([bison not found])
## local helper functions
@@ -275,3 +276,5 @@ AC_CONFIG_FILES([Makefile
])
AC_OUTPUT
+
+test x"$BUILD_TESTS" = x && AC_MSG_NOTICE([package 'check' not found; unit tests will not be built])
diff --git a/tests/Makefile.am b/tests/Makefile.am
index d8aa8f2..a97b8c5 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -1,6 +1,7 @@
TESTS_ENVIRONMENT = TOPBUILDDIR=$(top_builddir)
-TESTS = check_libgfs2 tool_tests.sh
EXTRA_DIST = tool_tests.sh
+
+if BUILD_TESTS
check_PROGRAMS = check_libgfs2
check_libgfs2_SOURCES = check_meta.c \
$(top_srcdir)/gfs2/libgfs2/libgfs2.h
@@ -8,3 +9,6 @@ check_libgfs2_CFLAGS = -I$(top_srcdir)/gfs2/libgfs2 \
-I$(top_srcdir)/gfs2/include \
@check_CFLAGS@
check_libgfs2_LDADD = $(top_builddir)/gfs2/libgfs2/libgfs2.la @check_LIBS@
+endif
+
+TESTS = $(check_PROGRAMS) tool_tests.sh
Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=efdb438ad868b…
Commit: efdb438ad868b447e28cde5959530b5dc763186f
Parent: 60dd70f06444939ea14bb6a40cfb61ab1eea9616
Author: David Teigland <teigland(a)redhat.com>
AuthorDate: Thu Jan 10 10:29:49 2013 -0600
Committer: David Teigland <teigland(a)redhat.com>
CommitterDate: Mon Apr 8 15:33:18 2013 -0500
fenced: reconnect to ccs in more places
Reconnect to ccsd if connection descriptor times out during
processing.
bz 881217
Based on patch from John Ruemker <jruemker(a)redhat.com>
Signed-off-by: David Teigland <teigland(a)redhat.com>
---
fence/fenced/agent.c | 42 +++++++++++++++++++++++++++++++++++-------
1 files changed, 35 insertions(+), 7 deletions(-)
diff --git a/fence/fenced/agent.c b/fence/fenced/agent.c
index de4467c..604bbb9 100644
--- a/fence/fenced/agent.c
+++ b/fence/fenced/agent.c
@@ -302,6 +302,25 @@ void update_cman(char *victim, char *method)
cman_finish(ch);
}
+static int reconnect_ccs(void)
+{
+ int count = 0;
+ int cd;
+
+ syslog(LOG_INFO, "ccs connection timed out, retrying\n");
+
+ while ((cd = ccs_connect()) < 0) {
+ sleep(1);
+
+ count++;
+ if (!(count % 60)) {
+ syslog(LOG_WARNING, "ccs reconnect failing\n");
+ }
+ }
+
+ return cd;
+}
+
int dispatch_fence_agent(char *victim, int force)
{
char good_device[256];
@@ -328,14 +347,9 @@ int dispatch_fence_agent(char *victim, int force)
error = get_method(cd, victim, m, &method);
- /* if the connection timed out while we were trying
- * to fence, try to open the connection again
- */
+ /* ccs connection times out if prev call took too long */
if (error == -EBADR) {
- syslog(LOG_INFO, "ccs connection timed out, "
- "retrying\n");
- while ((cd = ccs_connect()) < 0)
- sleep(1);
+ cd = reconnect_ccs();
error = get_method(cd, victim, m, &method);
}
@@ -349,10 +363,24 @@ int dispatch_fence_agent(char *victim, int force)
for (d = 0; d < num_devices; d++) {
error = get_device(cd, victim, method, d, &device);
+
+ /* ccs connection times out if prev call took too long */
+ if (error == -EBADR) {
+ cd = reconnect_ccs();
+ error = get_device(cd, victim, method, d, &device);
+ }
+
if (error)
break;
error = use_device(cd, victim, method, d, device);
+
+ /* ccs connection times out if prev call took too long */
+ if (error == -EBADR) {
+ cd = reconnect_ccs();
+ error = use_device(cd, victim, method, d, device);
+ }
+
if (error)
break;