# Test intentionally uses low timeouts --source include/not_valgrind.inc # # Test MySQL Server lifecycle, ie. # 1. stop/start # 2. stop/start without NDB # --source include/have_ndb.inc CREATE TABLE t1 ( a INT PRIMARY KEY, b VARCHAR(32) ) engine=ndb; INSERT INTO t1 VALUES (1, "row 1"); SELECT a FROM t1; --echo # --echo # 1. stop/start --echo # --echo # Restart MySQL Server --let $mysqld_name=mysqld.1.1 --source include/restart_mysqld.inc --source include/ndb_not_readonly.inc SELECT a FROM t1; --echo # --echo # 2. stop/start without NDB --echo # # Supress warning from Server starting up without NDB call mtr.add_suppression("Tables not available after [0-9]* seconds"); --echo # Stop data nodes --exec $NDB_MGM -e "all restart -n" --exec $NDB_WAITER --not-started 2>&1 > /dev/null --echo # Error since data nodes are down --error ER_GET_ERRMSG SELECT a FROM t1; --echo # Restart MySQL Server (with data nodes in no start) --let $mysqld_name=mysqld.1.1 --source include/restart_mysqld.inc --echo # Error since data nodes are still down --error ER_GET_ERRMSG SELECT a FROM t1; --echo # Start data nodes again --exec $NDB_MGM -e "all start" --exec $NDB_WAITER 2>&1 > /dev/null --source include/ndb_not_readonly.inc SELECT a FROM t1; DROP TABLE t1;