Commit df803044 authored by joreland@mysql.com's avatar joreland@mysql.com

ndb - autotest

  use newly created script for faster handling of several configurations
parent 9d0c5428
......@@ -7,6 +7,7 @@ node_id=1
dir_file=/tmp/dirs.$$
config_file=/tmp/config.$$
cluster_file=/tmp/cluster.$$
add_procs(){
type=$1; shift
......@@ -55,6 +56,7 @@ add_proc (){
}
cnf=/dev/null
cat $1 | while read line
do
case $line in
......@@ -65,20 +67,29 @@ do
ndb:*) add_procs ndb `echo $line | sed 's/ndb[ ]*:[ ]*//g'`;;
mysqld:*) add_procs mysqld `echo $line | sed 's/mysqld[ ]*:[ ]*//g'`;;
mysql:*) add_procs mysql `echo $line | sed 's/mysql[ ]*:[ ]*//g'`;;
"-- cluster config")
if [ "$cnf" = "/dev/null" ]
then
cnf=$cluster_file
else
cnf=/dev/null
fi
;;
*) echo $line >> $cnf
esac
done
cat $dir_file | xargs mkdir
cat $dir_file | xargs mkdir -p
if [ "$2" ]
then
cat $2 $config_file >> /tmp/config2.$$
if [ -f $cluster_file ]
then
cat $cluster_file $config_file >> /tmp/config2.$$
mv /tmp/config2.$$ $config_file
fi
for i in `find . -type d -name '*.ndb_mgmd'`
do
do
cp $config_file $i/config.ini
done
rm -f $config_file $dir_file
rm -f $config_file $dir_file $cluster_file
#!/bin/sh
save_args=$*
VERSION="ndb-autotest.sh version 1.0"
VERSION="ndb-autotest.sh version 1.01"
DATE=`date '+%Y-%m-%d'`
export DATE
......@@ -76,6 +76,7 @@ then
eval $configure --prefix=$run_dir
make
make install
(cd $run_dir; ./bin/mysql_install_db)
fi
###
......@@ -103,6 +104,8 @@ fi
test_dir=$run_dir/mysql-test/ndb
atrt=$test_dir/atrt
html=$test_dir/make-html-reports.sh
mkconfig=$run_dir/mysql-test/ndb/make-config.sh
PATH=$test_dir:$PATH
export PATH
......@@ -214,7 +217,7 @@ do
run_hosts=`echo $avail_hosts| awk '{for(i=1;i<='$count';i++)print $i;}'`
choose $run_dir/d.template $run_hosts > $run_dir/d.txt
choose $run_dir/1.ndb_mgmd/initconfig.template $run_hosts > $run_dir/1.ndb_mgmd/config.ini
(cd $run_dir; $mkconfig d.txt )
echo $run_hosts >> /tmp/filter_hosts.$$
cd $run_dir
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment