Commit a500c7de authored by monty@hundin.mysql.fi's avatar monty@hundin.mysql.fi

Merge work:/home/bk/mysql into hundin.mysql.fi:/my/bk/mysql

parents 01bed722 4e5b0871
......@@ -344,7 +344,11 @@ SLAVE_MYSQLD=$MYSQLD #this can be changed later if we are doing gcov
#--
wait_for_server_start ()
{
$MYSQLADMIN --no-defaults -u $DBUSER --silent -O connect_timeout=10 -w2 --host=$hostname --port=$1 ping >/dev/null 2>&1
$MYSQLADMIN --no-defaults -u $DBUSER --silent -O connect_timeout=10 -w3 --host=$hostname --port=$1 ping >/dev/null 2>&1
exit_code=$?
if [ $exit_code != 0 ]; then
echo "Error: Could not start $2, exit code $exit_code";
fi
}
prompt_user ()
......@@ -553,7 +557,7 @@ start_master()
else
$MYSQLD $master_args >> $MASTER_MYERR 2>&1 &
fi
wait_for_server_start $MASTER_MYPORT
wait_for_server_start $MASTER_MYPORT master
MASTER_RUNNING=1
}
......@@ -610,7 +614,7 @@ start_slave()
else
$SLAVE_MYSQLD $slave_args >> $SLAVE_MYERR 2>&1 &
fi
wait_for_server_start $SLAVE_MYPORT
wait_for_server_start $SLAVE_MYPORT slave
SLAVE_RUNNING=1
}
......
......@@ -57,7 +57,7 @@ reap;
connection slave;
sync_with_master ;
#give the slave a chance to exit
sleep 0.5;
sleep 2;
# The following test can't be done because the result of Pos will differ
# on different computers
......
......@@ -50,7 +50,8 @@ Usage: $0 db_name[./table_regex/] [new_db_name | directory]
-?, --help display this helpscreen and exit
-u, --user=# user for database login if not current user
-p, --password=# password to use when connecting to server
-P, --port=# port to use when connecting to local server
-h, --host=# Hostname for local server when connecting over TCP/IP
-P, --port=# port to use when connecting to local server with TCP/IP
-S, --socket=# socket to use when connecting to local server
--allowold don\'t abort if target already exists (rename it _old)
......@@ -155,8 +156,8 @@ $opt{quiet} = 0 if $opt{debug};
$opt{allowold} = 1 if $opt{keepold};
# --- connect to the database ---
my $dsn = ";host=localhost";
$dsn = ";host=127.0.0.1" if $opt{port}; # use TCP/IP if port was given
my $dsn;
$dsn = ";host=" . (defined($opt{host}) ? $opt{host} : "localhost");
$dsn .= ";port=$opt{port}" if $opt{port};
$dsn .= ";mysql_socket=$opt{socket}" if $opt{socket};
......@@ -891,9 +892,15 @@ user for database login if not current user
password to use when connecting to server
=item -h, -h, --host=#
Hostname for local server when connecting over TCP/IP. By specifying this
different from 'localhost' will trigger mysqlhotcopy to use TCP/IP connection.
=item -P, --port=#
port to use when connecting to local server
port to use when connecting to MySQL server with TCP/IP. This is only used
when using the --host option.
=item -S, --socket=#
......
......@@ -26,7 +26,8 @@
#include "mysql_version.h"
#include "lex.h"
bool opt_search=0,opt_verbose=0;
bool opt_search=0;
uint opt_verbose=0;
ulong opt_count=100000;
#define max_allowed_array 8000 // Don't generate bigger arrays than this
......@@ -526,8 +527,7 @@ int main(int argc,char **argv)
best_functype);
}
if (opt_verbose && (i % 20000) == 0)
printf("\nstart_value=%ldL; best_t1=%ldL; best_t2=%ldL; best_type=%d;
/* mode=%d add=%d type: %d */\n",
printf("\nstart_value=%ldL; best_t1=%ldL; best_t2=%ldL; best_type=%d; /* mode=%d add=%d type: %d */\n",
best_start_value,best_t1,best_t2,best_type,best_mod,best_add,
best_functype);
}
......
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