diff options
author | unknown <jonas@perch.ndb.mysql.com> | 2007-03-09 11:50:32 +0100 |
---|---|---|
committer | unknown <jonas@perch.ndb.mysql.com> | 2007-03-09 11:50:32 +0100 |
commit | 019c72a43fb360b8d279c5ffd3fc2f75515d0891 (patch) | |
tree | d780d06fd44f68971dfeaff7345594c6505ae0b7 /storage/ndb/tools/waiter.cpp | |
parent | b76fb8f72ed184e6da1f299fef9dbf7bb641cf8f (diff) | |
parent | 3dbfc95c334e9acbaa0185e387fc2af2e986d3ff (diff) | |
download | mariadb-git-019c72a43fb360b8d279c5ffd3fc2f75515d0891.tar.gz |
Merge perch.ndb.mysql.com:/home/jonas/src/tmp/mysql-5.0-telco-gca
into perch.ndb.mysql.com:/home/jonas/src/tmp/mysql-5.1-telco-gca
storage/ndb/tools/waiter.cpp:
Auto merged
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp:
merge
storage/ndb/src/kernel/blocks/dbdict/Dbdict.hpp:
merge
Diffstat (limited to 'storage/ndb/tools/waiter.cpp')
-rw-r--r-- | storage/ndb/tools/waiter.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/storage/ndb/tools/waiter.cpp b/storage/ndb/tools/waiter.cpp index 39bcc29758a..de8d15ac17a 100644 --- a/storage/ndb/tools/waiter.cpp +++ b/storage/ndb/tools/waiter.cpp @@ -30,12 +30,14 @@ waitClusterStatus(const char* _addr, ndb_mgm_node_status _status, unsigned int _timeout); enum ndb_waiter_options { - OPT_WAIT_STATUS_NOT_STARTED = NDB_STD_OPTIONS_LAST + OPT_WAIT_STATUS_NOT_STARTED = NDB_STD_OPTIONS_LAST, + OPT_WAIT_STATUS_SINGLE_USER }; NDB_STD_OPTS_VARS; static int _no_contact = 0; static int _not_started = 0; +static int _single_user = 0; static int _timeout = 120; const char *load_default_groups[]= { "mysql_cluster",0 }; @@ -49,6 +51,10 @@ static struct my_option my_long_options[] = { "not-started", OPT_WAIT_STATUS_NOT_STARTED, "Wait for cluster not started", (gptr*) &_not_started, (gptr*) &_not_started, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, + { "single-user", OPT_WAIT_STATUS_SINGLE_USER, + "Wait for cluster to enter single user mode", + (gptr*) &_single_user, (gptr*) &_single_user, 0, + GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "timeout", 't', "Timeout to wait", (gptr*) &_timeout, (gptr*) &_timeout, 0, GET_INT, REQUIRED_ARG, 120, 0, 0, 0, 0, 0 }, @@ -90,6 +96,10 @@ int main(int argc, char** argv){ { wait_status= NDB_MGM_NODE_STATUS_NOT_STARTED; } + else if (_single_user) + { + wait_status= NDB_MGM_NODE_STATUS_SINGLEUSER; + } else { wait_status= NDB_MGM_NODE_STATUS_STARTED; |