summaryrefslogtreecommitdiff
path: root/mysql-test/ndb
diff options
context:
space:
mode:
authorunknown <tomas@poseidon.ndb.mysql.com>2004-12-08 22:56:23 +0000
committerunknown <tomas@poseidon.ndb.mysql.com>2004-12-08 22:56:23 +0000
commit5380a3a600b0d0f13f80eb10071bafeb8a89b0ed (patch)
tree70bb7ee47ee35006e8c9b35e09f46506a1453388 /mysql-test/ndb
parent43a1ddcfcce4f9f9902e601b2435549cb6233c02 (diff)
downloadmariadb-git-5380a3a600b0d0f13f80eb10071bafeb8a89b0ed.tar.gz
ndbcluster.sh:
made compare of logs possible in ndb test restart_log.result, restart.test, restart.result: new file mysql-test/ndb/ndbcluster.sh: made compare of logs possible in ndb test
Diffstat (limited to 'mysql-test/ndb')
-rw-r--r--mysql-test/ndb/ndbcluster.sh24
-rw-r--r--mysql-test/ndb/restart.result16
-rw-r--r--mysql-test/ndb/restart.test12
-rw-r--r--mysql-test/ndb/restart_log.result20
4 files changed, 57 insertions, 15 deletions
diff --git a/mysql-test/ndb/ndbcluster.sh b/mysql-test/ndb/ndbcluster.sh
index 11cb8e77268..848223a091c 100644
--- a/mysql-test/ndb/ndbcluster.sh
+++ b/mysql-test/ndb/ndbcluster.sh
@@ -300,26 +300,20 @@ do_ndb_test ()
test_result=$fs_result/${test_name}.result
test_reject=$fs_result/${test_name}.reject
- cp $clusterlog $test_log_result
- cat ndb/${test_name}_log.result >> $test_log_result
+ clean_log='s/.*\[MgmSrvr\]//'
+
+ cat $clusterlog ndb/${test_name}_log.result | sed -e $clean_log > $test_log_result
cp ndb/${test_name}.result $test_result
cat ndb/${test_name}.test | $exec_mgmtclient > $test_reject
- cp $clusterlog $test_log_reject
- r=`diff -C 5 $test_result $test_reject`
- if [ $r ] ; then
- t="fail"
- else
- t="pass"
- fi
+ cat $clusterlog | sed -e $clean_log > $test_log_reject
+
+ t="pass"
+ diff -C 5 $test_result $test_reject || t="fail"
printf "ndb_mgm output %20s [%s]\n" $test_name $t
- r=`diff -C 5 $test_log_result $test_log_reject`
- if [ $r ] ; then
- t="fail"
- else
- t="pass"
- fi
+ t="pass"
+ diff -C 5 $test_log_result $test_log_reject || t="fail"
printf "clusterlog output %20s [%s]\n" $test_name $t
}
diff --git a/mysql-test/ndb/restart.result b/mysql-test/ndb/restart.result
new file mode 100644
index 00000000000..efa1399b5d9
--- /dev/null
+++ b/mysql-test/ndb/restart.result
@@ -0,0 +1,16 @@
+-- NDB Cluster -- Management Client --
+Connected to Management Server at: localhost:1186
+ALL disabled
+Cluster logging is enabled.
+ALERT enabled
+Executing CLUSTERLOG on node 1 OK!
+Executing CLUSTERLOG on node 2 OK!
+
+Node 1 is being restarted.
+
+Executing CLUSTERLOG on node 1 OK!
+Executing CLUSTERLOG on node 2 OK!
+
+Node 1 is being restarted.
+
+ALL enabled
diff --git a/mysql-test/ndb/restart.test b/mysql-test/ndb/restart.test
new file mode 100644
index 00000000000..6ea9e919368
--- /dev/null
+++ b/mysql-test/ndb/restart.test
@@ -0,0 +1,12 @@
+clusterlog off all
+clusterlog on
+clusterlog on alert
+all clusterlog connection=0
+sleep 1
+1 restart
+sleep 5
+all clusterlog connection=8
+sleep 1
+1 restart
+sleep 5
+clusterlog on all
diff --git a/mysql-test/ndb/restart_log.result b/mysql-test/ndb/restart_log.result
new file mode 100644
index 00000000000..2b25fc7b5b6
--- /dev/null
+++ b/mysql-test/ndb/restart_log.result
@@ -0,0 +1,20 @@
+ ALERT -- Node 2: Network partitioning - arbitration required
+ ALERT -- Node 2: Arbitration won - positive reply from node 3
+ ALERT -- Node 2: Node 1 has failed. The Node state at failure was 0
+ ALERT -- Node 2: Node failure of 1 DBLQH completed
+ ALERT -- Node 2: Node failure of 1 DBDICT completed
+ ALERT -- Node 2: Node failure of 1 DBDIH completed
+ ALERT -- Node 2: Node failure of 1 DBTC completed
+ ALERT -- Node 2: Node 2 completed failure of Node 1
+ ALERT -- Node 2: All nodes completed failure of Node 1
+ ALERT -- Node 3: Node 1 Disconnected
+ ALERT -- Node 2: Node 1 Disconnected
+ ALERT -- Node 2: Network partitioning - arbitration required
+ ALERT -- Node 2: Arbitration won - positive reply from node 3
+ ALERT -- Node 2: Node 1 has failed. The Node state at failure was 0
+ ALERT -- Node 2: Node failure of 1 DBLQH completed
+ ALERT -- Node 2: Node failure of 1 DBDICT completed
+ ALERT -- Node 2: Node failure of 1 DBDIH completed
+ ALERT -- Node 2: Node failure of 1 DBTC completed
+ ALERT -- Node 2: Node 2 completed failure of Node 1
+ ALERT -- Node 2: All nodes completed failure of Node 1