[SCM] CTDB repository - branch master updated - ctdb-2.4-42-g9e18f3c
Amitay Isaacs
amitay at samba.org
Wed Sep 25 06:56:13 CEST 2013
The branch, master has been updated
via 9e18f3c173863919587e25d704f66372624ed8ed (commit)
via 8f660d0dd52013e5876806be908e8e603aa6e968 (commit)
via c700dd0c7b6b43b61b3e231643b5d7cbe2f9592a (commit)
via 49c87699fad151933a0aefebfee968fc850e6383 (commit)
via c8a6e5ce579e2fe320c40268e7e9ddfe68b8cd30 (commit)
from ff41ce5ef202f8f6342e285d195bb5df61d848ce (commit)
http://gitweb.samba.org/?p=ctdb.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 9e18f3c173863919587e25d704f66372624ed8ed
Author: Martin Schwenke <martin at meltin.net>
Date: Mon Sep 23 16:23:36 2013 +1000
tool/ltdbtool: -h option does not require an argument
Signed-off-by: Martin Schwenke <martin at meltin.net>
commit 8f660d0dd52013e5876806be908e8e603aa6e968
Author: Martin Schwenke <martin at meltin.net>
Date: Mon Sep 23 16:22:36 2013 +1000
scripts: Add support for optional ctdbd.conf configuration file
Signed-off-by: Martin Schwenke <martin at meltin.net>
Pair-programmed-with: Amitay Isaacs <amitay at gmail.com>
commit c700dd0c7b6b43b61b3e231643b5d7cbe2f9592a
Author: Martin Schwenke <martin at meltin.net>
Date: Mon Sep 23 16:21:30 2013 +1000
utils: Make debug level strings case-insensitive
Signed-off-by: Martin Schwenke <martin at meltin.net>
Pair-programmed-with: Amitay Isaacs <amitay at gmail.com>
commit 49c87699fad151933a0aefebfee968fc850e6383
Author: Martin Schwenke <martin at meltin.net>
Date: Mon Sep 23 16:20:42 2013 +1000
tools/ctdb: Fix help messages for ctdb commands
Signed-off-by: Martin Schwenke <martin at meltin.net>
commit c8a6e5ce579e2fe320c40268e7e9ddfe68b8cd30
Author: Martin Schwenke <martin at meltin.net>
Date: Mon Sep 23 16:19:52 2013 +1000
tools/ctdb: Ban time of 0 is invalid
Apparently it used to mean a permanent ban but it is unclear if this
was ever supported.
Signed-off-by: Martin Schwenke <martin at meltin.net>
-----------------------------------------------------------------------
Summary of changes:
common/ctdb_util.c | 2 +-
config/functions | 7 +++++++
tools/ctdb.c | 13 +++++++++----
tools/ltdbtool.c | 2 +-
4 files changed, 18 insertions(+), 6 deletions(-)
Changeset truncated at 500 lines:
diff --git a/common/ctdb_util.c b/common/ctdb_util.c
index 11f9d83..d4bfeeb 100644
--- a/common/ctdb_util.c
+++ b/common/ctdb_util.c
@@ -657,7 +657,7 @@ int32_t get_debug_by_desc(const char *desc)
int i;
for (i=0; debug_levels[i].description != NULL; i++) {
- if (!strcmp(debug_levels[i].description, desc)) {
+ if (!strcasecmp(debug_levels[i].description, desc)) {
return debug_levels[i].level;
}
}
diff --git a/config/functions b/config/functions
index d9cf127..dfee767 100755
--- a/config/functions
+++ b/config/functions
@@ -42,6 +42,13 @@ _loadconfig() {
elif [ -f $CTDB_BASE/sysconfig/$1 ]; then
. $CTDB_BASE/sysconfig/$1
fi
+
+ if [ "$1" = "ctdb" ] ; then
+ _config="${CTDB_BASE}/ctdbd.conf"
+ if [ -r "$_config" ] ; then
+ . "$_config"
+ fi
+ fi
}
loadconfig () {
diff --git a/tools/ctdb.c b/tools/ctdb.c
index d67975a..cb97ef9 100644
--- a/tools/ctdb.c
+++ b/tools/ctdb.c
@@ -3182,6 +3182,11 @@ static int control_ban(struct ctdb_context *ctdb, int argc, const char **argv)
bantime.pnn = options.pnn;
bantime.time = strtoul(argv[0], NULL, 0);
+ if (bantime.time == 0) {
+ DEBUG(DEBUG_ERR, ("Invalid ban time specified - must be >0\n"));
+ return -1;
+ }
+
return update_flags_and_ipreallocate(ctdb, &bantime,
update_state_banned,
NODE_FLAGS_BANNED,
@@ -6064,13 +6069,13 @@ static const struct {
{ "readkey", control_readkey, true, false, "read the content off a database key", "<tdb-file> <key>" },
{ "writekey", control_writekey, true, false, "write to a database key", "<tdb-file> <key> <value>" },
{ "checktcpport", control_chktcpport, false, true, "check if a service is bound to a specific tcp port or not", "<port>" },
- { "rebalancenode", control_rebalancenode, false, false, "release a node by allowing it to takeover ips", "<pnn>"},
+ { "rebalancenode", control_rebalancenode, false, false, "mark nodes as forced IP rebalancing targets", "[<pnn-list>]"},
{ "getdbseqnum", control_getdbseqnum, false, false, "get the sequence number off a database", "<dbname|dbid>" },
{ "setdbseqnum", control_setdbseqnum, false, false, "set the sequence number for a database", "<dbname|dbid> <seqnum>" },
- { "nodestatus", control_nodestatus, true, false, "show and return node status" },
+ { "nodestatus", control_nodestatus, true, false, "show and return node status", "[<pnn-list>]" },
{ "dbstatistics", control_dbstatistics, false, false, "show db statistics", "<dbname|dbid>" },
- { "reloadips", control_reloadips, false, false, "reload the public addresses file on a node" },
- { "ipiface", control_ipiface, false, true, "Find which interface an ip address is hsoted on", "<ip>" },
+ { "reloadips", control_reloadips, false, false, "reload the public addresses file on specified nodes" , "[<pnn-list>]" },
+ { "ipiface", control_ipiface, false, true, "Find which interface an ip address is hosted on", "<ip>" },
};
/*
diff --git a/tools/ltdbtool.c b/tools/ltdbtool.c
index add9c32..13fd7f9 100644
--- a/tools/ltdbtool.c
+++ b/tools/ltdbtool.c
@@ -212,7 +212,7 @@ int main(int argc, char* argv[])
int opt;
const char *cmd, *idb, *odb;
- while ((opt = getopt(argc, argv, "s:o:S:O:ph:e")) != -1) {
+ while ((opt = getopt(argc, argv, "s:o:S:O:phe")) != -1) {
switch (opt) {
case 's':
case 'S':
--
CTDB repository
More information about the samba-cvs
mailing list