Commit 5e5d2056 authored by Bjorn Munch's avatar Bjorn Munch

merge from trunk

parents 7b292f8c cd5804ac
......@@ -137,46 +137,48 @@ test-force-full:
test-force-mem:
$(MAKE) force=--force mem=--mem test
EXP = --experimental=collections/default.experimental
test-bt:
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=normal --force --timer \
--skip-ndbcluster --report-features
--skip-ndbcluster --report-features $(EXP)
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=ps --force --timer \
--skip-ndbcluster --ps-protocol
--skip-ndbcluster --ps-protocol $(EXP)
-if [ -e bin/ndbd -o -e storage/ndb/src/kernel/ndbd ] ; then \
cd mysql-test ; \
MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=ndb+rpl_ndb+ps --force --timer \
--ps-protocol --mysqld=--binlog-format=row --suite=ndb,rpl_ndb ; \
--ps-protocol --mysqld=--binlog-format=row --suite=ndb,rpl_ndb $(EXP) ; \
MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=ndb --force --timer \
--with-ndbcluster-only ; \
--with-ndbcluster-only $(EXP) ; \
else \
echo "no program found for 'ndbcluster' tests - skipped testing" ; \
fi
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=funcs1+ps --ps-protocol --reorder --suite=funcs_1
@PERL@ ./mysql-test-run.pl --force --comment=funcs1+ps --ps-protocol --reorder --suite=funcs_1 $(EXP)
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=funcs2 --suite=funcs_2
@PERL@ ./mysql-test-run.pl --force --comment=funcs2 --suite=funcs_2 $(EXP)
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=partitions --suite=parts
@PERL@ ./mysql-test-run.pl --force --comment=partitions --suite=parts $(EXP)
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=stress --suite=stress
@PERL@ ./mysql-test-run.pl --force --comment=stress --suite=stress $(EXP)
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=jp --suite=jp
@PERL@ ./mysql-test-run.pl --force --comment=jp --suite=jp $(EXP)
-if [ -d mysql-test/suite/nist ] ; then \
cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=nist --force --suite=nist ; \
@PERL@ ./mysql-test-run.pl --comment=nist --force --suite=nist $(EXP) ; \
fi
-if [ -d mysql-test/suite/nist ] ; then \
cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=nist+ps --force --suite=nist --ps-protocol ; \
@PERL@ ./mysql-test-run.pl --comment=nist+ps --force --suite=nist --ps-protocol $(EXP) ; \
fi
-if [ -e bin/mysqltest_embedded -o -e libmysqld/examples/mysqltest_embedded ] ; then \
cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=embedded --force --timer \
--embedded-server --skip-rpl --skip-ndbcluster ; \
--embedded-server --skip-rpl --skip-ndbcluster $(EXP) ; \
else \
echo "no program found for 'embedded' tests - skipped testing" ; \
fi
......@@ -184,22 +186,22 @@ test-bt:
test-bt-fast:
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=ps --force --timer \
--skip-ndbcluster --ps-protocol --report-features
--skip-ndbcluster --ps-protocol --report-features $(EXP)
-if [ -e bin/ndbd -o -e storage/ndb/src/kernel/ndbd ] ; then \
cd mysql-test ; \
MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=ndb --force --timer \
--with-ndbcluster-only ; \
--with-ndbcluster-only $(EXP) ; \
else \
echo "no program found for 'ndbcluster' tests - skipped testing" ; \
fi
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --force --comment=stress --suite=stress
@PERL@ ./mysql-test-run.pl --force --comment=stress --suite=stress $(EXP)
test-bt-debug:
-cd mysql-test ; MTR_BUILD_THREAD=auto \
@PERL@ ./mysql-test-run.pl --comment=debug --force --timer \
--skip-ndbcluster --skip-rpl --report-features
--skip-ndbcluster --skip-rpl --report-features $(EXP)
test-bt-debug-fast:
......
......@@ -10,7 +10,7 @@ AC_CANONICAL_SYSTEM
#
# When changing major version number please also check switch statement
# in client/mysqlbinlog.cc:check_master_version().
AM_INIT_AUTOMAKE(mysql, 5.4.5-beta)
AM_INIT_AUTOMAKE(mysql, 5.5.0-beta)
AM_CONFIG_HEADER([include/config.h:config.h.in])
PROTOCOL_VERSION=10
......
......@@ -2,18 +2,79 @@
# in alphabetical order. This also helps with merge conflict resolution.
binlog.binlog_tmp_table* # Bug#45578:2009-07-10 alik Test binlog_tmp_table fails ramdonly on PB2: Unknown table 't2'
funcs_1.charset_collation_1 # depends on compile-time decisions
innodb.innodb_information_schema # Bug#47449 2009-09-19 alik main.information_schema and innodb.innodb_information_schema fail sporadically
main.ctype_gbk_binlog @solaris # Bug#46010: main.ctype_gbk_binlog fails sporadically : Table 't2' already exists
main.information_schema # Bug#47449 2009-09-19 alik main.information_schema and innodb.innodb_information_schema fail sporadically
main.innodb-autoinc # Bug#44030 2009-09-24 alik Marking innodb-autoinc experimental while waiting for the patch to be merged
main.lock_multi_bug38499 # Bug#47448 2009-09-19 alik main.lock_multi_bug38499 times out sporadically
main.plugin* @solaris # Bug#47146 Linking problem with example plugin when dtrace enabled
main.plugin_load @solaris # Bug#47146
main.lock_multi_bug38691 @solaris # Bug#47792 2009-10-02 alik main.lock_multi_bug38691 times out sporadically on Solaris 10
main.log_tables # Bug#47924 2009-10-08 alik main.log_tables times out sporadically
main.plugin # Bug#47146 Linking problem with example plugin when dtrace enabled
main.plugin_load # Bug#47146
rpl.rpl_get_master_version_and_clock* # Bug#46931 2009-08-26 alik rpl.rpl_get_master_version_and_clock fails on hpux11.31
rpl.rpl_innodb_bug28430* @solaris # Bug#46029
rpl.rpl_innodb_bug30888* @solaris # Bug#47646 2009-09-25 alik rpl.rpl_innodb_bug30888 fails sporadically on Solaris
rpl.rpl_plugin_load* @solaris # Bug#47146
rpl.rpl_row_create_table* # Bug#45576: rpl_row_create_table fails on PB2
rpl_ndb.rpl_ndb_log # Bug#38998
rpl.rpl_log_pos* # Bug#47743 2009-10-02 alik rpl.rpl_log_pos fails sporadically
rpl.rpl_trigger* # Bug#46656 2009-09-25 alik InnoDB plugin: memory leaks (Valgrind)
# Declare all NDB-tests in ndb and rpl_ndb test suites experimental.
# Usually the test cases from ndb and rpl_ndb test suites are not run in PB,
# but they run by gcov.
#
ndb.*
rpl_ndb.*
# Declare all NDB-tests in other test suites experimental.
stress.ddl_ndb
sys_vars.ndb_log_update_as_write_basic
sys_vars.have_ndbcluster_basic
sys_vars.ndb_log_updated_only_basic
funcs_1.ndb_storedproc_10
funcs_1.ndb_bitdata
funcs_1.ndb_trig_03
funcs_1.ndb_trig_0102
funcs_1.is_tables_ndb
funcs_1.is_columns_ndb
funcs_1.ndb_trig_0407
funcs_1.ndb_trig_1011ext
funcs_1.ndb_storedproc_06
funcs_1.ndb_views
funcs_1.is_cml_ndb
funcs_1.ndb_storedproc_02
funcs_1.ndb_storedproc_03
funcs_1.ndb_trig_03e
funcs_1.is_engines_ndb
funcs_1.ndb_trig_08
funcs_1.ndb_storedproc_07
funcs_1.ndb_storedproc_08
funcs_1.ndb_func_view
funcs_1.ndb_trig_09
funcs_1.ndb_cursors
funcs_2.ndb_charset
ndb.n* # Consider all NDB tests experimental.
rpl_ndb.r* # Consider all NDB tests experimental.
parts.partition_engine_ndb
parts.ndb_dd_backuprestore
parts.partition_value_ndb
parts.partition_mgm_lc2_ndb
parts.partition_alter1_2_ndb
parts.partition_alter1_1_ndb
parts.part_supported_sql_func_ndb
parts.partition_int_ndb
parts.partition_mgm_lc1_ndb
parts.partition_auto_increment_ndb
parts.partition_syntax_ndb
parts.partition_alter1_1_2_ndb
parts.partition_basic_ndb
parts.partition_mgm_lc0_ndb
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=n_mix --mysqld=--binlog-format=mixed --suite=main,binlog,innodb,federated,rpl
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=ps_row --ps-protocol --mysqld=--binlog-format=row --suite=main,binlog,innodb,federated,rpl
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=embedded --embedded --suite=main,binlog,innodb,federated,rpl
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=rpl_binlog_row --mysqld=--binlog-format=row --suite=rpl,binlog
perl mysql-test-run.pl --timer --force --parallel=auto --experimental=collections/default.experimental --comment=funcs_1 --suite=funcs_1
This diff is collapsed.
......@@ -10,4 +10,4 @@
#
##############################################################################
ndb_trig_1011ext: Bug#32656 NDB: Duplicate key error aborts transaction in handler. Doesn't talk back to SQL
ndb_trig_1011ext: Bug#47564
innodb-index: InnoDB: Error: table `test`.`t1#1` already exists in InnoDB internal
innodb-index : Bug#47563 2009-06-11 svoj InnoDB: Error: table `test`.`t1#1` already exists in InnoDB internal
partition_basic_ndb : Bug#19899 Crashing the server
partition_basic_ndb : Bug#44919 parts-suite in mtr tries to use features not supported by ndb
# http://dev.mysql.com/doc/refman/5.1/en/mysql-cluster-limitations-syntax.html
partition_syntax_ndb : Bug#36735 Not supported
......@@ -10,4 +10,4 @@
#
##############################################################################
rpl_cross_version : Bug#42311 2009-03-27 joro rpl_cross_version fails on macosx
rpl_cross_version : Bug#43913 2009-03-27 joro rpl_cross_version can't pass on conflicts complainig clash with --slave-load-tm
......@@ -21,14 +21,10 @@ let $index_merge_random_rows_in_EXPLAIN = 1;
# InnoDB does not support Merge tables (affects include/index_merge1.inc)
let $merge_table_support= 0;
# The first two tests are disabled because of non deterministic explain output.
# If include/index_merge1.inc can be enabled for InnoDB and all other
# storage engines, please remove the subtest for Bug#21277 from
# include/index_merge2.inc.
# This test exists already in include/index_merge1.inc.
# -- [DISABLED Bug#45727]
# --source include/index_merge1.inc
# --source include/index_merge_ror.inc
# --source include/index_merge2.inc
--source include/index_merge2.inc
--source include/index_merge_2sweeps.inc
--source include/index_merge_ror_cpk.inc
......@@ -64,6 +64,7 @@ cflags="@CFLAGS@"
STRIP=1 # Option ignored
SILENT=0
MALLOC_LIB=
PLATFORM=""
TMP=/tmp
NEW_NAME="" # Final top directory and TAR package name
......@@ -76,6 +77,7 @@ for arg do
--tmp=*) TMP=`echo "$arg" | sed -e "s;--tmp=;;"` ;;
--suffix=*) SUFFIX=`echo "$arg" | sed -e "s;--suffix=;;"` ;;
--short-product-tag=*) SHORT_PRODUCT_TAG=`echo "$arg" | sed -e "s;--short-product-tag=;;"` ;;
--inject-malloc-lib=*) MALLOC_LIB=`echo "$arg" | sed -e 's;^[^=]*=;;'` ;;
--no-strip) STRIP=0 ;;
--machine=*) machine=`echo "$arg" | sed -e "s;--machine=;;"` ;;
--platform=*) PLATFORM=`echo "$arg" | sed -e "s;--platform=;;"` ;;
......@@ -293,6 +295,12 @@ if [ x"$BASE_SYSTEM" != x"netware" ] ; then
fi
fi
# If requested, add a malloc library .so into pkglibdir for use
# by mysqld_safe
if [ -n "$MALLOC_LIB" ]; then
cp "$MALLOC_LIB" "$DEST/lib/"
fi
# FIXME let this script be in "bin/", where it is in the RPMs?
# http://dev.mysql.com/doc/refman/5.1/en/mysql-install-db-problems.html
mkdir $DEST/scripts
......
......@@ -167,6 +167,10 @@ Options:
--port [$port]
--version [$version]
--libmysqld-libs [$embedded_libs]
--variable=VAR VAR is one of:
pkgincludedir [$pkgincludedir]
pkglibdir [$pkglibdir]
plugindir [$plugindir]
EOF
exit 1
}
......@@ -184,6 +188,15 @@ while test $# -gt 0; do
--port) echo "$port" ;;
--version) echo "$version" ;;
--embedded-libs | --embedded | --libmysqld-libs) echo "$embedded_libs" ;;
--variable=*)
var=`echo "$1" | sed 's,^[^=]*=,,'`
case "$var" in
pkgincludedir) echo "$pkgincludedir" ;;
pkglibdir) echo "$pkglibdir" ;;
plugindir) echo "$plugindir" ;;
*) usage ;;
esac
;;
*) usage ;;
esac
......
......@@ -11,9 +11,13 @@
# mysql.server works by first doing a cd to the base directory and from there
# executing mysqld_safe
# Initialize script globals
KILL_MYSQLD=1;
MYSQLD=
niceness=0
mysqld_ld_preload=
mysqld_ld_library_path=
# Initial logging status: error log is not open, and not using syslog
logging=init
want_syslog=0
......@@ -46,6 +50,7 @@ Usage: $0 [OPTIONS]
--open-files-limit=LIMIT Limit the number of open files
--core-file-size=LIMIT Limit core files to the specified size
--timezone=TZ Set the system timezone
--malloc-lib=LIB Preload shared library LIB if available
--mysqld=FILE Use the specified file as mysqld
--mysqld-version=VERSION Use "mysqld-VERSION" as mysqld
--nice=NICE Set the scheduling priority of mysqld
......@@ -172,6 +177,7 @@ parse_arguments() {
# mysqld_safe-specific options - must be set in my.cnf ([mysqld_safe])!
--core-file-size=*) core_file_size="$val" ;;
--ledir=*) ledir="$val" ;;
--malloc-lib=*) set_malloc_lib "$val" ;;
--mysqld=*) MYSQLD="$val" ;;
--mysqld-version=*)
if test -n "$val"
......@@ -202,6 +208,131 @@ parse_arguments() {
}
# Add a single shared library to the list of libraries which will be added to
# LD_PRELOAD for mysqld
#
# Since LD_PRELOAD is a space-separated value (for historical reasons), if a
# shared lib's path contains spaces, that path will be prepended to
# LD_LIBRARY_PATH and stripped from the lib value.
add_mysqld_ld_preload() {
lib_to_add="$1"
log_notice "Adding '$lib_to_add' to LD_PRELOAD for mysqld"
case "$lib_to_add" in
*' '*)
# Must strip path from lib, and add it to LD_LIBRARY_PATH
lib_file=`basename "$lib_to_add"`
case "$lib_file" in
*' '*)
# The lib file itself has a space in its name, and can't
# be used in LD_PRELOAD
log_error "library name '$lib_to_add' contains spaces and can not be used with LD_PRELOAD"
exit 1
;;
esac
lib_path=`dirname "$lib_to_add"`
lib_to_add="$lib_file"
[ -n "$mysqld_ld_library_path" ] && mysqld_ld_library_path="$mysqld_ld_library_path:"
mysqld_ld_library_path="$mysqld_ld_library_path$lib_path"
;;
esac
# LD_PRELOAD is a space-separated
[ -n "$mysqld_ld_preload" ] && mysqld_ld_preload="$mysqld_ld_preload "
mysqld_ld_preload="${mysqld_ld_preload}$lib_to_add"
}
# Returns LD_PRELOAD (and LD_LIBRARY_PATH, if needed) text, quoted to be
# suitable for use in the eval that calls mysqld.
#
# All values in mysqld_ld_preload are prepended to LD_PRELOAD.
mysqld_ld_preload_text() {
text=
if [ -n "$mysqld_ld_preload" ]; then
new_text="$mysqld_ld_preload"
[ -n "$LD_PRELOAD" ] && new_text="$new_text $LD_PRELOAD"
text="${text}LD_PRELOAD="`shell_quote_string "$new_text"`' '
fi
if [ -n "$mysqld_ld_library_path" ]; then
new_text="$mysqld_ld_library_path"
[ -n "$LD_LIBRARY_PATH" ] && new_text="$new_text:$LD_LIBRARY_PATH"
text="${text}LD_LIBRARY_PATH="`shell_quote_string "$new_text"`' '
fi
echo "$text"
}
mysql_config=
get_mysql_config() {
if [ -z "$mysql_config" ]; then
mysql_config=`echo "$0" | sed 's,/[^/][^/]*$,/mysql_config,'`
if [ ! -x "$mysql_config" ]; then
log_error "Can not run mysql_config $@ from '$mysql_config'"
exit 1
fi
fi
"$mysql_config" "$@"
}
# set_malloc_lib LIB
# - If LIB is empty, do nothing and return
# - If LIB is 'tcmalloc', look for tcmalloc shared library in /usr/lib
# then pkglibdir. tcmalloc is part of the Google perftools project.
# - If LIB is an absolute path, assume it is a malloc shared library
#
# Put LIB in mysqld_ld_preload, which will be added to LD_PRELOAD when
# running mysqld. See ld.so for details.
set_malloc_lib() {
malloc_lib="$1"
if [ "$malloc_lib" = tcmalloc ]; then
pkglibdir=`get_mysql_config --variable=pkglibdir`
malloc_lib=
# This list is kept intentionally simple. Simply set --malloc-lib
# to a full path if another location is desired.
for libdir in /usr/lib "$pkglibdir"; do
for flavor in _minimal '' _and_profiler _debug; do
tmp="$libdir/libtcmalloc$flavor.so"
#log_notice "DEBUG: Checking for malloc lib '$tmp'"
[ -r "$tmp" ] || continue
malloc_lib="$tmp"
break 2
done
done
if [ -z "$malloc_lib" ]; then
log_error "no shared library for --malloc-lib=tcmalloc found in /usr/lib or $pkglibdir"
exit 1
fi
fi
# Allow --malloc-lib='' to override other settings
[ -z "$malloc_lib" ] && return
case "$malloc_lib" in
/*)
if [ ! -r "$malloc_lib" ]; then
log_error "--malloc-lib '$malloc_lib' can not be read and will not be used"
exit 1
fi
;;
*)
log_error "--malloc-lib must be an absolute path or 'tcmalloc'; " \
"ignoring value '$malloc_lib'"
exit 1
;;
esac
add_mysqld_ld_preload "$malloc_lib"
}
#
# First, try to find BASEDIR and ledir (where mysqld is)
#
......@@ -549,7 +680,7 @@ fi
# ulimit -n 256 > /dev/null 2>&1 # Fix for BSD and FreeBSD systems
#fi
cmd="$NOHUP_NICENESS"
cmd="`mysqld_ld_preload_text`$NOHUP_NICENESS"
for i in "$ledir/$MYSQLD" "$defaults" "--basedir=$MY_BASEDIR_VERSION" \
"--datadir=$DATADIR" "$USER_OPTION"
......
......@@ -448,6 +448,13 @@ $MBD/libtool --mode=execute install -m 755 \
$RPM_BUILD_DIR/mysql-%{mysql_version}/mysql-debug-%{mysql_version}/sql/mysqld \
$RBR%{_sbindir}/mysqld-debug
%if %{?malloc_lib_target:1}%{!?malloc_lib_target:0}
# Even though this is a shared library, put it under /usr/lib/mysql, so it
# doesn't conflict with possible shared lib by the same name in /usr/lib. See
# `mysql_config --variable=pkglibdir` and mysqld_safe for how this is used.
install -m 644 "%{malloc_lib_source}" "$RBR%{_libdir}/mysql/%{malloc_lib_target}"
%endif
# install saved perror binary with NDB support (BUG#13740)
install -m 755 $MBD/extra/perror $RBR%{_bindir}/perror
......@@ -707,6 +714,10 @@ fi
%attr(755, root, root) %{_libdir}/mysql/plugin/ha_innodb_plugin.so*
%endif
%if %{?malloc_lib_target:1}%{!?malloc_lib_target:0}
%attr(755, root, root) %{_libdir}/mysql/%{malloc_lib_target}
%endif
%attr(755, root, root) %{_sbindir}/mysqld
%attr(755, root, root) %{_sbindir}/mysqld-debug
%attr(755, root, root) %{_sbindir}/rcmysql
......
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