[SCM] CTDB repository - branch master updated -
ctdb-1.0.72-9-g7412c67
Ronnie Sahlberg
sahlberg at samba.org
Thu Feb 19 23:06:25 GMT 2009
The branch, master has been updated
via 7412c6706c2d8ec668d0a6a50471db369f3dbf2b (commit)
via e1c90b12290c682c2cba90e9afa3a09be014e20e (commit)
via 2f42429f6996e98c9bfad49eab9fa23e85d7bec2 (commit)
via e391bde5ac743956fb30ede65030973a1f13dae5 (commit)
via b9e50e3416fecef6a881be3f1b91be977299293f (commit)
via 9e2245b9bb795e2d757aacd706a9861a59d1638e (commit)
via 79b8c87338a2d40464e87e501daae403a2f14427 (commit)
via b0c6854d1e886456fabdc8f1c3bd21c89311c601 (commit)
via dbd90f6210617b23d5695c4c868392363c75d23b (commit)
from e1be8cb2dc32f56eabd537b658b47929818b8d01 (commit)
http://gitweb.samba.org/?p=sahlberg/ctdb.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 7412c6706c2d8ec668d0a6a50471db369f3dbf2b
Merge: e1c90b12290c682c2cba90e9afa3a09be014e20e e1be8cb2dc32f56eabd537b658b47929818b8d01
Author: Michael Adam <obnox at samba.org>
Date: Thu Feb 19 23:51:23 2009 +0100
Merge commit 'ctdb-ronnie/master'
commit e1c90b12290c682c2cba90e9afa3a09be014e20e
Merge: 2f42429f6996e98c9bfad49eab9fa23e85d7bec2 59a04a50e64aae0a89b165d0428e23a8bcf8eb24
Author: Michael Adam <obnox at samba.org>
Date: Tue Feb 10 00:28:08 2009 +0100
Merge commit 'ctdb-ronnie/master'
commit 2f42429f6996e98c9bfad49eab9fa23e85d7bec2
Author: Mathieu PARENT <math.parent at gmail.com>
Date: Wed Feb 4 00:50:46 2009 +0100
correct ctdbd(1) manpage warning
Signed-off-by: Michael Adam <obnox at samba.org>
commit e391bde5ac743956fb30ede65030973a1f13dae5
Author: Mathieu PARENT <math.parent at gmail.com>
Date: Wed Feb 4 00:48:56 2009 +0100
smnotify: fix popt.h include to allow use of system lib
Signed-off-by: Michael Adam <obnox at samba.org>
commit b9e50e3416fecef6a881be3f1b91be977299293f
Author: Michael Adam <obnox at samba.org>
Date: Wed Feb 4 00:42:33 2009 +0100
events 41.httpd: support suse and ubuntu/debian systems for managing apache
The httpd service on suse and ubuntu/debian systems is usually
called "apache2" nowadays.
Note: There are older installs with Apache 1.3 out there, in which case
the service is called "apache". An extra check for these installs could
be useful as a sequel to this patch...
Michael
commit 9e2245b9bb795e2d757aacd706a9861a59d1638e
Author: Michael Adam <obnox at samba.org>
Date: Wed Feb 4 00:28:16 2009 +0100
build: print default in help for --with-logdir
Michael
commit 79b8c87338a2d40464e87e501daae403a2f14427
Author: Michael Adam <obnox at samba.org>
Date: Wed Feb 4 00:22:01 2009 +0100
make: add a "showlayout" target for diagnostics
Michael
commit b0c6854d1e886456fabdc8f1c3bd21c89311c601
Author: Mathieu PARENT <math.parent at gmail.com>
Date: Wed Feb 4 00:15:57 2009 +0100
build: Make log-directory configurable indepently of VARDIR
This adds a new configure option "--with-logdir".
logdir defaults to "${localstatedir}/log" .
It is important to have logdir configurable for debian systems,
where localstatedir is set to "/var/lib" and not "/var".
Signed-off-by: Michael Adam <obnox at samba.org>
commit dbd90f6210617b23d5695c4c868392363c75d23b
Author: Michael Adam <obnox at samba.org>
Date: Wed Feb 4 00:01:15 2009 +0100
events.d/41.httpd: fix a typo in the fix of the comment typo
This is embarassing...
Michael
-----------------------------------------------------------------------
Summary of changes:
Makefile.in | 13 +++++++++++++
config/events.d/41.httpd | 34 +++++++++++++++++++++++++++++-----
configure.ac | 11 +++++++++++
doc/ctdbd.1 | 4 ++--
server/ctdbd.c | 2 +-
utils/smnotify/smnotify.c | 2 +-
6 files changed, 57 insertions(+), 9 deletions(-)
Changeset truncated at 500 lines:
diff --git a/Makefile.in b/Makefile.in
index a1a8f7d..03023b3 100755
--- a/Makefile.in
+++ b/Makefile.in
@@ -12,6 +12,7 @@ bindir = @bindir@
sbindir = @sbindir@
mandir = @mandir@
localstatedir = @localstatedir@
+logdir = @LOGDIR@
VPATH = @srcdir@:@tdbdir@:@tallocdir@:@libreplacedir@:@poptdir@
srcdir = @srcdir@
etcdir = @sysconfdir@
@@ -30,6 +31,7 @@ IPQ_LIBS = @IPQ_LIBS@
CFLAGS=-g -I$(srcdir)/include -Iinclude -Ilib -Ilib/util -I$(srcdir) \
-I at tallocdir@ -I at tdbdir@/include -I at libreplacedir@ \
-DVARDIR=\"$(localstatedir)\" -DETCDIR=\"$(etcdir)\" \
+ -DLOGDIR=\"$(logdir)\" \
-DUSE_MMAP=1 @CFLAGS@ $(POPT_CFLAGS)
LIB_FLAGS=@LDFLAGS@ -Llib @LIBS@ $(POPT_LIBS) @INFINIBAND_LIBS@ @CTDB_PCAP_LDFLAGS@
@@ -75,6 +77,17 @@ showflags:
@echo ' CFLAGS = $(CFLAGS)'
@echo ' LIBS = $(LIBS)'
+showlayout::
+ @echo "ctdb will be installed into:"
+ @echo " prefix: $(prefix)"
+ @echo " bindir: $(bindir)"
+ @echo " sbindir: $(sbindir)"
+ @echo " libdir: $(libdir)"
+ @echo " vardir: $(localstatedir)"
+ @echo " logdir: $(logdir)"
+ @echo " mandir: $(mandir)"
+ @echo " etcdir: $(etcdir)"
+
.c.o:
@echo Compiling $*.c
@mkdir -p `dirname $@`
diff --git a/config/events.d/41.httpd b/config/events.d/41.httpd
index 038392f..fae9f47 100755
--- a/config/events.d/41.httpd
+++ b/config/events.d/41.httpd
@@ -1,9 +1,33 @@
#!/bin/sh
-# event sript to manage httpd in a cluster environment
+# event script to manage httpd in a cluster environment
. $CTDB_BASE/functions
loadconfig ctdb
-loadconfig http
+
+detect_init_style
+
+case $CTDB_INIT_STYLE in
+ redhat)
+ CTDB_SERVICE_HTTP="httpd"
+ CTDB_CONFIG_HTTP="http"
+ ;;
+ suse)
+ CTDB_SERVICE_HTTP="apache2"
+ CTDB_CONFIG_HTTP="apache2"
+ ;;
+ ubuntu)
+ CTDB_SERVICE_HTTP="apache2"
+ CTDB_CONFIG_HTTP="apache2"
+ ;;
+ *)
+ # should not happen.
+ # for now use red hat style as default
+ CTDB_SERVICE_HTTP="httpd"
+ CTDB_CONFIG_HTTP="http"
+ ;;
+esac
+
+loadconfig "${CTDB_CONFIG_HTTP}"
[ "$CTDB_MANAGES_HTTPD" = "yes" ] || exit 0
@@ -12,12 +36,12 @@ shift
case $cmd in
startup)
- service httpd stop > /dev/null 2>&1
- service httpd start
+ service "${CTDB_SERVICE_HTTP}" stop > /dev/null 2>&1
+ service "${CTDB_SERVICE_HTTP}" start
;;
shutdown)
- service httpd stop
+ service "${CTDB_SERVICE_HTTP}" stop
;;
monitor)
diff --git a/configure.ac b/configure.ac
index d552eed..8b6102d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,6 +37,17 @@ if test "$ac_cv_prog_gcc" = yes; then
CFLAGS="$CFLAGS -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings"
fi
+LOGDIR='${localstatedir}/log'
+AC_ARG_WITH([logdir],
+ [ --with-logdir=DIR path to log directory [[LOCALSTATEDIR/log]]],
+ LOGDIR=$withval)
+if test ! -z "$LOGDIR"; then
+ if test "$LOGDIR" = "yes" -o "$LOGDIR" = "no"; then
+ AC_MSG_ERROR([--with-logdir must specify a path])
+ fi
+fi
+AC_SUBST(LOGDIR)
+
AC_CONFIG_HEADER(config.h)
EXTRA_OBJ=""
diff --git a/doc/ctdbd.1 b/doc/ctdbd.1
index 356818f..38ba41a 100644
--- a/doc/ctdbd.1
+++ b/doc/ctdbd.1
@@ -48,7 +48,7 @@
.it 1 an-trap
.nr an-no-space-flag 1
.nr an-break-flag 1
-\." make the size of the head bigger
+.\" make the size of the head bigger
.ps +3
.ft B
.ne (2v + 1u)
@@ -82,7 +82,7 @@
.nr an-no-space-flag 1
.nr an-break-flag 1
.ps \\n[PS-SS]u
-\." make the size of the head bigger
+.\" make the size of the head bigger
.ps +2
.ft B
.ne (2v + 1u)
diff --git a/server/ctdbd.c b/server/ctdbd.c
index ee433da..1d3b22a 100644
--- a/server/ctdbd.c
+++ b/server/ctdbd.c
@@ -52,7 +52,7 @@ static struct {
.nlist = ETCDIR "/ctdb/nodes",
.transport = "tcp",
.event_script_dir = ETCDIR "/ctdb/events.d",
- .logfile = VARDIR "/log/log.ctdb",
+ .logfile = LOGDIR "/log.ctdb",
.db_dir = VARDIR "/ctdb",
.db_dir_persistent = VARDIR "/ctdb/persistent",
.script_log_level = DEBUG_ERR,
diff --git a/utils/smnotify/smnotify.c b/utils/smnotify/smnotify.c
index 3f0058c..d7fd546 100644
--- a/utils/smnotify/smnotify.c
+++ b/utils/smnotify/smnotify.c
@@ -24,7 +24,7 @@
#include <netinet/in.h>
#include <arpa/inet.h>
#include "smnotify.h"
-#include "../../lib/popt/popt.h"
+#include "popt.h"
static char *client = NULL;
static const char *ip = NULL;
--
CTDB repository
More information about the samba-cvs
mailing list