After merge fixes
This commit is contained in:
commit
ced195f8a9
@ -535,3 +535,4 @@ Docs/internals.html
|
||||
Docs/internals.pdf
|
||||
Docs/internals.txt
|
||||
Docs/internals_toc.html
|
||||
scripts/make_win_src_distribution
|
||||
|
@ -15,11 +15,14 @@ bell@laptop.sanja.is.com.ua
|
||||
bell@sanja.is.com.ua
|
||||
bk@admin.bk
|
||||
davida@isil.mysql.com
|
||||
dlenev@build.mysql.com
|
||||
dlenev@mysql.com
|
||||
gluh@gluh.(none)
|
||||
gluh@gluh.mysql.r18.ru
|
||||
greg@gcw.ath.cx
|
||||
greg@mysql.com
|
||||
guilhem@mysql.com
|
||||
gweir@build.mysql.com
|
||||
gweir@work.mysql.com
|
||||
heikki@donna.mysql.fi
|
||||
heikki@hundin.mysql.fi
|
||||
@ -111,6 +114,7 @@ vva@eagle.mysql.r18.ru
|
||||
vva@genie.(none)
|
||||
walrus@kishkin.ru
|
||||
walrus@mysql.com
|
||||
wax@mysql.com
|
||||
worm@altair.is.lan
|
||||
zak@balfor.local
|
||||
zak@linux.local
|
||||
|
@ -10,6 +10,7 @@
|
||||
# written by Lenz Grimmer <lenz@mysql.com>
|
||||
#
|
||||
|
||||
use Cwd;
|
||||
use Getopt::Long;
|
||||
Getopt::Long::Configure ("bundling");
|
||||
|
||||
@ -26,23 +27,25 @@ else
|
||||
|
||||
# Some predefined settings
|
||||
$build_command= "BUILD/compile-pentium-max";
|
||||
chomp ($LOGFILE= `pwd`);
|
||||
$LOGFILE.= "/Bootstrap.log";
|
||||
chomp ($opt_directory= `pwd`);
|
||||
$opt_docdir= $opt_directory . "/mysqldoc";
|
||||
$PWD= cwd();
|
||||
$LOGFILE= $PWD . "/Bootstrap.log";
|
||||
$opt_docdir= $PWD . "/mysqldoc";
|
||||
$opt_build_command= undef;
|
||||
$opt_changelog= undef;
|
||||
$opt_delete= undef;
|
||||
$opt_directory= $PWD;
|
||||
$opt_dry_run= undef;
|
||||
$opt_export_only= undef;
|
||||
$opt_help= $opt_verbose= 0;
|
||||
$opt_log= undef;
|
||||
$opt_mail= "";
|
||||
$opt_pull= undef;
|
||||
$opt_revision= undef;
|
||||
$opt_suffix= "";
|
||||
$opt_test= undef;
|
||||
$opt_skip_check= undef;
|
||||
$opt_skip_manual= undef;
|
||||
$opt_win_dist= undef;
|
||||
$version= "unknown";
|
||||
$major=$minor=$release=0;
|
||||
|
||||
@ -57,12 +60,14 @@ GetOptions(
|
||||
"help|h",
|
||||
"log|l:s",
|
||||
"mail|m=s",
|
||||
"pull|p",
|
||||
"revision|r=s",
|
||||
"skip-check|s",
|
||||
"skip-manual",
|
||||
"suffix=s",
|
||||
"test|t",
|
||||
"verbose|v"
|
||||
"verbose|v",
|
||||
"win-dist|w"
|
||||
) || print_help("");
|
||||
|
||||
#
|
||||
@ -78,8 +83,7 @@ if (defined $opt_log)
|
||||
}
|
||||
else
|
||||
{
|
||||
chomp ($LOGFILE= `pwd`);
|
||||
$LOGFILE.= "/" . $opt_log;
|
||||
$LOGFILE= $PWD . "/" . $opt_log;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -101,13 +105,30 @@ defined($REPO=$ARGV[0]) || print_help("Please enter the BK repository to be used
|
||||
system ("bk help > /dev/null") == 0 or &abort("Cannot execute BitKeeper binary!");
|
||||
system ("bk root $REPO > /dev/null 2>&1") == 0 or &abort("$REPO does not seem to be a valid BK repository!");
|
||||
|
||||
if (($opt_directory ne ".") && (!-d $opt_directory && !$opt_dry_run))
|
||||
if (($opt_directory ne $PWD) && (!-d $opt_directory && !$opt_dry_run))
|
||||
{
|
||||
&abort("Could not find target directory \"$opt_directory\"!");
|
||||
}
|
||||
|
||||
&logger("Logging to $LOGFILE") if (defined $opt_log);
|
||||
|
||||
#
|
||||
# Pull recent changes first
|
||||
#
|
||||
if ($opt_pull)
|
||||
{
|
||||
&logger("Updating BK tree $REPO to latest ChangeSet first");
|
||||
$command= "cd $REPO; bk pull; cd ..";
|
||||
&run_command($command, "Could not update $REPO!");
|
||||
|
||||
unless ($opt_skip_manual)
|
||||
{
|
||||
&logger("Updating manual tree in $opt_docdir");
|
||||
$command= "cd $opt_docdir; bk pull; cd ..";
|
||||
&run_command($command, "Could not update $opt_docdir!");
|
||||
}
|
||||
}
|
||||
|
||||
#
|
||||
# Use a temporary name until we know the version number
|
||||
#
|
||||
@ -251,7 +272,7 @@ if (defined $opt_changelog)
|
||||
#
|
||||
# Add the latest manual from the mysqldoc tree
|
||||
#
|
||||
if (!$opt_skip_manual)
|
||||
unless ($opt_skip_manual)
|
||||
{
|
||||
$msg= "Adding manual.texi";
|
||||
&logger($msg);
|
||||
@ -303,7 +324,17 @@ $command= "make dist";
|
||||
&run_command($command, "make dist failed!");
|
||||
|
||||
#
|
||||
# Run "make distcheck" to verify the source archive
|
||||
# Package the Windows source
|
||||
#
|
||||
if ($opt_win_dist)
|
||||
{
|
||||
&logger ("Creating Windows source package");
|
||||
$command= "./scripts/make_win_src_distribution --tar --zip";
|
||||
&run_command($command, "make_win_src_distribution failed!");
|
||||
}
|
||||
|
||||
#
|
||||
# Run "make distcheck" to verify the source archive
|
||||
#
|
||||
if (!$opt_skip_check)
|
||||
{
|
||||
@ -330,7 +361,7 @@ sub print_help
|
||||
print "ERROR: $message\n";
|
||||
}
|
||||
print <<EOF;
|
||||
|
||||
|
||||
Usage: Bootstrap [options] <bk repository>
|
||||
|
||||
Checks out (exports) a clear-text version of the given local BitKeeper
|
||||
@ -366,6 +397,7 @@ Options:
|
||||
include a log file snippet, if logging is enabled)
|
||||
Note that the \@-Sign needs to be quoted!
|
||||
Example: --mail=user\\\@domain.com
|
||||
-p, --pull Update the source BK trees before building
|
||||
-r, --revision=<rev> Export the tree as of revision <rev>
|
||||
(default is up to the latest revision)
|
||||
-s, --skip-check Skip checking the distribution with "make distcheck"
|
||||
@ -376,6 +408,7 @@ Options:
|
||||
(e.g. "-20020518").
|
||||
-t, --test Run the test suite after build
|
||||
-v, --verbose Be verbose
|
||||
-w, --win-dist Also make Windows source distribution
|
||||
|
||||
Example:
|
||||
|
||||
|
@ -8,7 +8,7 @@ use Getopt::Long;
|
||||
$opt_distribution=$opt_user=$opt_config_env="";
|
||||
$opt_dbd_options=$opt_perl_options=$opt_config_options=$opt_make_options=$opt_suffix="";
|
||||
$opt_tmp=$opt_version_suffix="";
|
||||
$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_debug=$opt_no_benchmark=$opt_no_mysqltest=0;
|
||||
$opt_help=$opt_delete=$opt_debug=$opt_stage=$opt_no_test=$opt_no_perl=$opt_with_low_memory=$opt_fast_benchmark=$opt_static_client=$opt_static_server=$opt_static_perl=$opt_sur=$opt_with_small_disk=$opt_local_perl=$opt_tcpip=$opt_build_thread=$opt_use_old_distribution=$opt_enable_shared=$opt_no_crash_me=$opt_no_strip=$opt_with_debug=$opt_no_benchmark=$opt_no_mysqltest=$opt_without_embedded=0;
|
||||
$opt_innodb=$opt_bdb=$opt_raid=$opt_libwrap=0;
|
||||
|
||||
GetOptions(
|
||||
@ -51,6 +51,7 @@ GetOptions(
|
||||
"with-low-memory",
|
||||
"with-other-libc=s",
|
||||
"with-small-disk",
|
||||
"without-embedded",
|
||||
) || usage();
|
||||
|
||||
usage() if ($opt_help);
|
||||
@ -230,6 +231,7 @@ if ($opt_stage <= 1)
|
||||
$opt_config_options.= " --with-low-memory" if ($opt_with_low_memory);
|
||||
$opt_config_options.= " --with-mysqld-ldflags=-all-static" if ($opt_static_server);
|
||||
$opt_config_options.= " --with-raid" if ($opt_raid);
|
||||
$opt_config_options.= " --with-embedded-server" unless ($opt_without_embedded);
|
||||
|
||||
# Only enable InnoDB when requested (required to be able to
|
||||
# build the "Classic" packages that do not include InnoDB)
|
||||
@ -551,6 +553,9 @@ non-standard location overriding default.
|
||||
--with-small-disk
|
||||
Clean up the build environment before testing the binary distribution
|
||||
(to save disk space)
|
||||
|
||||
--without-embedded
|
||||
Don't compile the embedded server.
|
||||
EOF
|
||||
exit 1;
|
||||
}
|
||||
|
@ -1,7 +1,9 @@
|
||||
#!/usr/bin/perl -w
|
||||
#
|
||||
# Do-pkg - convert a binary distribution into a Mac OS X PKG and put it
|
||||
# inside a Disk Image (.dmg)
|
||||
# inside a Disk Image (.dmg). Additionally, add a separate package,
|
||||
# including the required Startup Item to automatically start MySQL on
|
||||
# bootup.
|
||||
#
|
||||
# The script currently assumes the following environment (which should exist
|
||||
# like that, if the Do-compile script was used to build the binary
|
||||
@ -17,14 +19,19 @@
|
||||
# written by Lenz Grimmer <lenz@mysql.com>
|
||||
#
|
||||
|
||||
use Cwd;
|
||||
use File::Basename;
|
||||
use File::Copy;
|
||||
use Getopt::Long;
|
||||
Getopt::Long::Configure ("bundling");
|
||||
use Sys::Hostname;
|
||||
|
||||
$opt_dry_run= undef;
|
||||
$opt_help= undef;
|
||||
$opt_log= undef;
|
||||
$opt_mail= "";
|
||||
$opt_skip_dmg= undef;
|
||||
$opt_skip_si= undef;
|
||||
$opt_suffix= undef;
|
||||
$opt_verbose= undef;
|
||||
$opt_version= undef;
|
||||
@ -35,13 +42,14 @@ GetOptions(
|
||||
"log|l:s",
|
||||
"mail|m=s",
|
||||
"skip-dmg|skip-disk-image|s",
|
||||
"skip-si|skip-startup-item",
|
||||
"suffix=s",
|
||||
"verbose|v",
|
||||
"version=s",
|
||||
) || &print_help;
|
||||
|
||||
# Include helper functions
|
||||
chomp($PWD= `pwd`);
|
||||
$PWD= cwd();
|
||||
$LOGGER= "$PWD/logger.pm";
|
||||
if (-f "$LOGGER")
|
||||
{
|
||||
@ -54,7 +62,7 @@ else
|
||||
|
||||
$PM= "/Developer/Applications/PackageMaker.app/Contents/MacOS/PackageMaker";
|
||||
$TMP= $ENV{TMPDIR};
|
||||
$TMP eq "" ? $TMP= $TMP . "/PKGBUILD": $TMP= "/tmp/PKGBUILD";
|
||||
$TMP eq "" ? $TMP= $TMP . "/PKGBUILD.$$": $TMP= "/tmp/PKGBUILD.$$";
|
||||
$PKGROOT= "$TMP/PMROOT";
|
||||
$PKGDEST= "$TMP/PKG";
|
||||
$RESOURCE_DIR= "$TMP/Resources";
|
||||
@ -62,8 +70,8 @@ $SUFFIX= $opt_suffix;
|
||||
$VERSION= $opt_version;
|
||||
($MAJOR, $MINOR, $RELEASE)= split(/\./, $VERSION);
|
||||
$NAME= "mysql$SUFFIX-$VERSION";
|
||||
chomp($HOST= `hostname`);
|
||||
chomp($ID= `whoami`);
|
||||
$HOST= hostname();
|
||||
$ID= getpwuid($>);
|
||||
$HOST=~ /^([^.-]*)/;
|
||||
$HOST= $1;
|
||||
$LOGFILE= "$PWD/Logs/$HOST-$MAJOR.$MINOR$SUFFIX.log";
|
||||
@ -73,6 +81,12 @@ $SUPFILEDIR= <$SRCBASEDIR/support-files/MacOSX>;
|
||||
$TAR= <$BUILDDIR/$NAME-apple-darwin*-powerpc.tar.gz>;
|
||||
$INFO= <$SUPFILEDIR/Info.plist>;
|
||||
$DESC= <$SUPFILEDIR/Description.plist>;
|
||||
$SI_INFO= <$SUPFILEDIR/StartupItem.Info.plist>;
|
||||
$SI_DESC= <$SUPFILEDIR/StartupItem.Description.plist>;
|
||||
$SI_PARAMS= <$SUPFILEDIR/StartupParameters.plist>;
|
||||
$SI_POST= <$SUPFILEDIR/StartupItem.postinstall>;
|
||||
$SI_NAME= "MySQLStartupItem";
|
||||
$SI_SCRIPT= <$SUPFILEDIR/MySQL>;
|
||||
@RESOURCES= qw/ ReadMe.txt postinstall preinstall /;
|
||||
@LICENSES= ("$SRCBASEDIR/COPYING","$SRCBASEDIR/MySQLEULA.txt");
|
||||
|
||||
@ -99,7 +113,9 @@ if (defined $opt_log)
|
||||
# Creating the UFS disk image requires root privileges
|
||||
die("You must be root to run this script!") if ($ID ne "root" && !$opt_dry_run);
|
||||
|
||||
foreach $file ($TAR, $INFO, $DESC)
|
||||
@files= ($TAR, $INFO, $DESC);
|
||||
@files= (@files, $SI_INFO, $SI_DESC, $SI_POST, $SI_SCRIPT) unless $opt_skip_si;
|
||||
foreach $file (@files)
|
||||
{
|
||||
&abort("Unable to find $file!") unless (-f "$file");
|
||||
}
|
||||
@ -112,14 +128,22 @@ foreach $dir ($TMP, $PKGROOT, $PKGDEST, $RESOURCE_DIR)
|
||||
{
|
||||
if (!-d $dir)
|
||||
{
|
||||
&run_command("mkdir $dir", "Could not make directory $dir!");
|
||||
&logger("Creating directory $dir!");
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
mkdir($dir) or &abort("Could not make directory $dir!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach $resfile (@RESOURCES)
|
||||
{
|
||||
$command= "cp $SUPFILEDIR/$resfile $RESOURCE_DIR";
|
||||
&run_command($command, "Error while copying $SUPFILEDIR/$resfile to $RESOURCE_DIR");
|
||||
&logger("Copying $SUPFILEDIR/$resfile to $RESOURCE_DIR");
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
copy("$SUPFILEDIR/$resfile", "$RESOURCE_DIR") or
|
||||
&abort("Error while copying $SUPFILEDIR/$resfile to $RESOURCE_DIR");
|
||||
}
|
||||
}
|
||||
|
||||
# Search for license file
|
||||
@ -127,12 +151,17 @@ foreach $license (@LICENSES)
|
||||
{
|
||||
if (-f "$license")
|
||||
{
|
||||
$command= "cp $license $RESOURCE_DIR/License.txt";
|
||||
&run_command($command, "Error while copying $license to $RESOURCE_DIR");
|
||||
&logger("Copy $license to $RESOURCE_DIR/License.txt");
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
copy("$license", "$RESOURCE_DIR/License.txt") or
|
||||
&abort("Error while copying $license to $RESOURCE_DIR");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&abort("Could not find a license file!") unless (-f "$RESOURCE_DIR/License.txt");
|
||||
&abort("Could not find a license file!")
|
||||
unless (-f "$RESOURCE_DIR/License.txt");
|
||||
|
||||
# Extract the binary tarball and create the "mysql" symlink
|
||||
&logger("Extracting $TAR to $PKGROOT");
|
||||
@ -145,10 +174,38 @@ foreach $license (@LICENSES)
|
||||
# returning a non-zero value, even though the package was created correctly
|
||||
&logger("Running PackageMaker");
|
||||
$command= "$PM -build -p $PKGDEST/$NAME.pkg -f $PKGROOT -r $RESOURCE_DIR -i $INFO -d $DESC || true";
|
||||
&run_command($command, "Error while building package!");
|
||||
&run_command($command, "Error while building package $NAME.pkg!");
|
||||
|
||||
&logger("Removing $PKGROOT");
|
||||
&run_command("rm -rf $PKGROOT", "Unable to remove $PKGROOT!");
|
||||
#
|
||||
# Build the Startup Item PKG
|
||||
#
|
||||
unless ($opt_skip_si)
|
||||
{
|
||||
&logger("Cleaning up $PKGROOT");
|
||||
&run_command("rm -rf $PKGROOT/*", "Unable to clean up $PKGROOT!");
|
||||
&logger("Cleaning up $RESOURCE_DIR");
|
||||
&run_command("rm -rf $RESOURCE_DIR/*", "Unable to clean up $RESOURCE_DIR!");
|
||||
|
||||
&logger("Installing MySQL StartupItem files into $PKGROOT/MySQL");
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
mkdir("$PKGROOT/MySQL") or &abort("Error creating $PKGROOT/MySQL");
|
||||
copy("$SI_SCRIPT", "$PKGROOT/MySQL/")
|
||||
or &abort("Error copying $SI_SCRIPT!");
|
||||
chmod(0755, "$PKGROOT/MySQL/" . basename("$SI_SCRIPT"));
|
||||
copy("$SI_PARAMS", "$PKGROOT/MySQL/")
|
||||
or &abort("Error copying $SI_PARAMS!");
|
||||
chmod(0644, "$PKGROOT/MySQL/" . basename("$SI_PARAMS"));
|
||||
&run_command("chown -R root.wheel $PKGROOT/*", "Cannot chown $PKGROOT!");
|
||||
copy("$SI_POST", "$RESOURCE_DIR/postinstall")
|
||||
or &abort("Error copying $SI_POST!");
|
||||
chmod(0644, "$RESOURCE_DIR/postinstall");
|
||||
}
|
||||
|
||||
&logger("Building $SI_NAME.pkg using PackageMaker");
|
||||
$command= "$PM -build -p $PKGDEST/$SI_NAME.pkg -f $PKGROOT -r $RESOURCE_DIR -i $SI_INFO -d $SI_DESC || true";
|
||||
&run_command($command, "Error while building package $SI_NAME.pkg!");
|
||||
}
|
||||
|
||||
if ($opt_skip_dmg)
|
||||
{
|
||||
@ -159,7 +216,7 @@ if ($opt_skip_dmg)
|
||||
# Determine the size of the Disk image to be created and add a 5% safety
|
||||
# margin for filesystem overhead
|
||||
&logger("Determining required disk image size for $PKGDEST");
|
||||
if (! $opt_dry_run)
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
chomp($_= `du -sk $PKGDEST`);
|
||||
@size= split();
|
||||
@ -167,7 +224,10 @@ if (! $opt_dry_run)
|
||||
&logger("Disk image size: $size KB");
|
||||
}
|
||||
|
||||
&abort("Zero bytes? Something is wrong here!") if ($size == 0);
|
||||
unless($opt_dry_run)
|
||||
{
|
||||
&abort("Zero bytes? Something is wrong here!") if ($size == 0);
|
||||
}
|
||||
|
||||
# Now create and mount the disk image
|
||||
$TMPNAME= $NAME . ".tmp";
|
||||
@ -181,7 +241,7 @@ $command= "hdiutil create $TMPNAME -size ${size}k -ov -fs UFS -volname $NAME";
|
||||
chomp($mountpoint=`mount | grep "\/Volumes\/$NAME" | cut -f3 -d" "`) if (!$opt_dry_run);
|
||||
&logger("Copying $PKGDEST/$NAME.pkg to Disk image /Volumes/$NAME");
|
||||
&run_command("ditto $PKGDEST /Volumes/$NAME", "Could not copy $PKGDEST to /Volumes/$NAME!");
|
||||
&run_command("ditto $RESOURCE_DIR/ReadMe.txt /Volumes/$NAME", "Could not copy $RESOURCE_DIR/ReadMe.txt to /Volumes/$NAME!");
|
||||
&run_command("ditto $SUPFILEDIR/ReadMe.txt /Volumes/$NAME", "Could not copy $SPFILEDIR/ReadMe.txt to /Volumes/$NAME!");
|
||||
chomp($mountpoint=`mount | grep "\/Volumes\/$NAME" | cut -f1 -d" "`) if (!$opt_dry_run);
|
||||
&abort("/Volumes/$NAME not attached!") if (!$mountpoint && !$opt_dry_run);
|
||||
&logger("Unmounting $mountpoint");
|
||||
@ -221,20 +281,23 @@ NOTE: You need to run this script with root privileges (required
|
||||
|
||||
Options:
|
||||
|
||||
--dry-run Dry run without executing
|
||||
-h, --help Print this help
|
||||
-l, --log[=<filename>] Write a log file [to <filename>]
|
||||
(default is "$LOGFILE")
|
||||
-m, --mail=<address> Mail a failure report to the given address
|
||||
(and include a log file snippet, if logging
|
||||
is enabled)
|
||||
Note that the \@-Sign needs to be quoted!
|
||||
Example: --mail=user\\\@domain.com
|
||||
-s, --skip-disk-image Just build the PKG, don't put it into a
|
||||
disk image afterwards
|
||||
--suffix=<suffix> The package suffix (e.g. "-standard" or "-pro)
|
||||
--version=<version> The MySQL version number (e.g. 4.0.11-gamma)
|
||||
-v, --verbose Verbose execution
|
||||
--dry-run Dry run without executing
|
||||
-h, --help Print this help
|
||||
-l, --log[=<filename>] Write a log file [to <filename>]
|
||||
(default is "$LOGFILE")
|
||||
-m, --mail=<address> Mail a failure report to the given
|
||||
address (and include a log file snippet,
|
||||
if logging is enabled)
|
||||
Note that the \@-Sign needs to be quoted!
|
||||
Example: --mail=user\\\@domain.com
|
||||
-s, --skip-disk-image, --skip-dmg Just build the PKGs, don't put it into a
|
||||
disk image afterwards
|
||||
--skip-startup-item, --skip-si Skip the creation of the StartupItem PKG
|
||||
--suffix=<suffix> The package suffix
|
||||
(e.g. "-standard" or "-pro)
|
||||
--version=<version> The MySQL version number
|
||||
(e.g. 4.0.11-gamma)
|
||||
-v, --verbose Verbose execution
|
||||
|
||||
EOF
|
||||
exit 1;
|
||||
|
@ -1,259 +1,227 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/perl -w
|
||||
#
|
||||
# Do-rpm - compile RPM packages out of a source tarball and move the
|
||||
# resulting RPM packages into the current directory.
|
||||
#
|
||||
# The script currently assumes the following environment (which should exist
|
||||
# like that, if the Do-compile script was used to build the binary
|
||||
# distribution)
|
||||
#
|
||||
# - there must be a source distribution (mysql-<version>.tar.gz)
|
||||
# in the current directory
|
||||
# - there must be a spec file (mysql-<version>.spec) in the directory
|
||||
# $HOME/<hostname>/mysql-<version>/support-files/
|
||||
#
|
||||
# Use the "--help" option for more info!
|
||||
#
|
||||
# written by Lenz Grimmer <lenz@mysql.com>
|
||||
#
|
||||
|
||||
#helper functions
|
||||
use Cwd;
|
||||
use File::Basename;
|
||||
use File::Copy;
|
||||
use Getopt::Long;
|
||||
Getopt::Long::Configure ("bundling");
|
||||
use Sys::Hostname;
|
||||
|
||||
function copy_to_bmachine
|
||||
$opt_cc= undef;
|
||||
$opt_cflags= undef;
|
||||
$opt_clean= undef;
|
||||
$opt_cxx= undef;
|
||||
$opt_cxxflags= undef;
|
||||
$opt_dry_run= undef;
|
||||
$opt_help= undef;
|
||||
$opt_log= undef;
|
||||
$opt_mail= "";
|
||||
$opt_verbose= undef;
|
||||
|
||||
$MAJOR= $MINOR= $RELEASE= 0;
|
||||
|
||||
GetOptions(
|
||||
"cc=s",
|
||||
"cflags=s",
|
||||
"clean|c",
|
||||
"cxx=s",
|
||||
"cxxflags=s",
|
||||
"dry-run|t",
|
||||
"help|h",
|
||||
"log|l:s",
|
||||
"mail|m=s",
|
||||
"verbose|v",
|
||||
) || &print_help;
|
||||
|
||||
defined($VERSION=$ARGV[0]) || print_help("Please provide the MySQL version!");
|
||||
|
||||
# Include helper functions
|
||||
$PWD= cwd();
|
||||
$LOGGER= "$PWD/logger.pm";
|
||||
if (-f "$LOGGER")
|
||||
{
|
||||
if [ x$local_build = x1 ]; then
|
||||
rm -f $2
|
||||
cp $1 $2
|
||||
else
|
||||
scp $1 $owner@$bmachine:$2
|
||||
fi
|
||||
do "$LOGGER";
|
||||
}
|
||||
else
|
||||
{
|
||||
die "ERROR: $LOGGER cannot be found!\n";
|
||||
}
|
||||
|
||||
function copy_from_bmachine
|
||||
#
|
||||
# Override predefined Log file name
|
||||
#
|
||||
if (defined $opt_log)
|
||||
{
|
||||
if [ x$local_build = x1 ]; then
|
||||
rm -f $2
|
||||
cp $1 $2
|
||||
else
|
||||
scp $owner@$bmachine:$1 $2
|
||||
fi
|
||||
if ($opt_log ne "")
|
||||
{
|
||||
if ($opt_log =~ /^\/.*/)
|
||||
{
|
||||
$LOGFILE= $opt_log;
|
||||
}
|
||||
else
|
||||
{
|
||||
$LOGFILE= $PWD . "/" . $opt_log;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function run_command
|
||||
($MAJOR, $MINOR, $RELEASE)= split(/\./, $VERSION);
|
||||
$HOST= hostname();
|
||||
$HOST=~ /^([^.-]*)/;
|
||||
$HOST= $1;
|
||||
$LOGFILE= "$PWD/Logs/Do-rpm-$HOST-$MAJOR.$MINOR.log";
|
||||
|
||||
&print_help("") if ($opt_help);
|
||||
|
||||
#
|
||||
# Newer RPM versions ship with a separate tool "rpmbuild" to build RPMs
|
||||
#
|
||||
if (-x "/usr/bin/rpmbuild")
|
||||
{
|
||||
if [ x$local_build = x1 ]; then
|
||||
bash $1
|
||||
else
|
||||
cat $1 | ssh $owner@$bmachine bash
|
||||
fi
|
||||
$RPM= "/usr/bin/rpmbuild";
|
||||
}
|
||||
else
|
||||
{
|
||||
$RPM= "/bin/rpm";
|
||||
}
|
||||
|
||||
#Supply defaults
|
||||
if ($RPM)
|
||||
{
|
||||
&logger("Found rpm binary: $RPM");
|
||||
}
|
||||
else
|
||||
{
|
||||
&abort("Unable to find RPM binary!");
|
||||
}
|
||||
|
||||
# We built on one of two machines
|
||||
bmachine=work
|
||||
smachine=work
|
||||
owner=my
|
||||
#
|
||||
# determine some RPM settings for this host
|
||||
#
|
||||
chomp($RPMARCH= `$RPM --eval "%{_arch}" 2> /dev/null`);
|
||||
chomp($RPMDIR= `$RPM --eval "%{_rpmdir}" 2> /dev/null`);
|
||||
chomp($SOURCEDIR= `$RPM --eval "%{_sourcedir}" 2> /dev/null`);
|
||||
chomp($SPECDIR= `$RPM --eval "%{_specdir}" 2> /dev/null`);
|
||||
chomp($SRCRPMDIR= `$RPM --eval "%{_srcrpmdir}" 2> /dev/null`);
|
||||
|
||||
# Hard path!!
|
||||
bpath=`/bin/pwd`
|
||||
$SOURCEFILE= "mysql-$VERSION.tar.gz";
|
||||
$SPECFILE= "$PWD/$HOST/mysql-$VERSION/support-files/mysql-$VERSION.spec";
|
||||
|
||||
for d in /usr/src/redhat /usr/src/packages ; do
|
||||
if test -d "$d"
|
||||
then
|
||||
rpmdir=$d
|
||||
fi
|
||||
done
|
||||
&logger("Starting RPM build of MySQL-$VERSION on $HOST");
|
||||
|
||||
if test -z "$rpmdir"
|
||||
then
|
||||
echo "Could not find suitable rpmdir on this system"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
foreach $file ($SOURCEFILE, $SPECFILE)
|
||||
{
|
||||
&abort("Unable to find $file!") unless (-f "$file");
|
||||
}
|
||||
|
||||
logdir="$bpath/Logs"
|
||||
#
|
||||
# Install source and spec file
|
||||
#
|
||||
&logger("Copying SOURCE and SPEC file to build directories.");
|
||||
copy($SOURCEFILE, $SOURCEDIR)
|
||||
or &abort("Unable to copy $SOURCEFILE to $SOURCEDIR!");
|
||||
copy($SPECFILE, $SPECDIR)
|
||||
or &abort("Unable to copy $SPECFILE to $SPECDIR!");
|
||||
|
||||
###### Perl STUFF #####
|
||||
#
|
||||
# Set environment variables - these are being used in the
|
||||
# official MySQL RPM spec file
|
||||
#
|
||||
&logger("Setting special build environment variables")
|
||||
if ($opt_cc) or ($opt_cflags) or ($opt_cxxflags) or ($opt_cxx);
|
||||
$ENV{MYSQL_BUILD_CC}=$opt_cc if ($opt_cc);
|
||||
$ENV{MYSQL_BUILD_CFLAGS}=$opt_cflags if ($opt_cflags);
|
||||
$ENV{MYSQL_BUILD_CXXFLAGS}=$opt_cxxflags if ($opt_cxxflags);
|
||||
$ENV{MYSQL_BUILD_CXX}=$opt_cxx if ($opt_cxx);
|
||||
|
||||
# Perl version numbers. Should be autodetected from the files in the
|
||||
# Perl-mysql-modules/ directory.
|
||||
DBI_VERSION="1.14"
|
||||
DATA_SHOWTABLE_VERSION="3.3"
|
||||
DBD_MYSQL_VERSION="1.2215"
|
||||
MAKERPM="$rpmdir/SOURCES/makerpm.pl"
|
||||
#
|
||||
# Build the RPMs
|
||||
#
|
||||
$command= "$RPM";
|
||||
$command.= " -v" if ($opt_verbose);
|
||||
$command.= " -ba";
|
||||
$command.= " --clean" if $opt_clean;
|
||||
$command.= " $SPECDIR/";
|
||||
$command.= basename($SPECFILE);
|
||||
&logger("Building RPM.");
|
||||
&run_command($command, "Error while building the RPMs!");
|
||||
|
||||
#######################
|
||||
AM_MAKEFLAGS="-j 2"
|
||||
#
|
||||
# Move the resulting RPMs into the pwd
|
||||
#
|
||||
$command= "mv";
|
||||
$command.= " -v " if ($opt_verbose);
|
||||
$command.= "$SRCRPMDIR/MySQL*$VERSION*.src.rpm $PWD";
|
||||
&run_command($command, "Error moving source RPM!");
|
||||
|
||||
VER=`grep "AM_INIT_AUTOMAKE(mysql, " $bpath/configure.in | \
|
||||
sed -e 's;AM_INIT_AUTOMAKE(mysql, ;;' -e 's;);;'`
|
||||
VER_NO_DASH=`echo $VER | sed -e "s|-.*$||"`
|
||||
tarball=$bpath/mysql-$VER.tar.gz
|
||||
$command= "mv";
|
||||
$command.= " -v " if ($opt_verbose);
|
||||
$command.= "$RPMDIR/$RPMARCH/MySQL*$VERSION*.$RPMARCH.rpm $PWD";
|
||||
&run_command($command, "Error moving binary RPMs!");
|
||||
|
||||
while test $# -gt 0; do
|
||||
case "$1" in
|
||||
--rpmdir=*)
|
||||
rpmdir=`echo $1 | sed -e "s;--rpmdir=;;"`
|
||||
;;
|
||||
--smachine=*)
|
||||
smachine=`echo $1 | sed -e "s;--smachine=;;"`
|
||||
;;
|
||||
--bmachine=*)
|
||||
bmachine=`echo $1 | sed -e "s;--bmachine=;;"`
|
||||
;;
|
||||
--owner=*)
|
||||
owner=`echo $1 | sed -e "s;--owner=;;"`
|
||||
;;
|
||||
--tarball=*)
|
||||
tarball=`echo $1 | sed -e "s;--tarball=;;"`
|
||||
;;
|
||||
--logdir=*)
|
||||
logdir=`echo $1 | sed -e "s;--logdir=;;"`
|
||||
;;
|
||||
--local )
|
||||
local_build=1
|
||||
;;
|
||||
--skip-perl )
|
||||
skip_perl=1
|
||||
;;
|
||||
* ) break ;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
#
|
||||
# Clean up
|
||||
#
|
||||
if ($opt_clean)
|
||||
{
|
||||
&logger("Removing spec file and source package");
|
||||
unlink("$SPECDIR/" . basename($SPECFILE));
|
||||
unlink("$SOURCEDIR/$SOURCEFILE");
|
||||
}
|
||||
|
||||
echo "Removing old MySQL packages"
|
||||
rm -f $bpath/NEW-RPMS/MySQL-*rpm
|
||||
&logger("SUCCESS: RPM files successfully created.") if (!$opt_dry_run);
|
||||
exit 0;
|
||||
|
||||
if [ ! -d "$logdir" ]; then
|
||||
echo "$logdir does not exist, creating"
|
||||
mkdir -p $logdir
|
||||
fi
|
||||
sub print_help
|
||||
{
|
||||
my $message= $_[0];
|
||||
if ($message ne "")
|
||||
{
|
||||
print "\n";
|
||||
print "ERROR: $message\n\n}";
|
||||
}
|
||||
print <<EOF;
|
||||
|
||||
if [ ! -f "$tarball" ]; then
|
||||
echo "Tarball file $tarball does not exist, please make one first"
|
||||
exit 1
|
||||
fi
|
||||
Usage: Do-rpm <options> <version>
|
||||
|
||||
log=$logdir/Log-RPM-`date +%y%m%d-%H%M`
|
||||
Creates a binary RPM package out of a MySQL source distribution and moves the
|
||||
resulting RPMs into the current directory. <version> is the MySQL version
|
||||
number (e.g. 4.0.11-gamma)
|
||||
|
||||
echo "Building RPM for MySQL version $VER on $bmachine"
|
||||
echo "Details in $log"
|
||||
Options:
|
||||
|
||||
(
|
||||
set -x
|
||||
# remove old stuff
|
||||
rm -rf $rpmdir/BUILD/mysql-*
|
||||
rm -f $rpmdir/SOURCES/mysql-*
|
||||
rm -f $rpmdir/SRPMS/MySQL-*
|
||||
rm -f $rpmdir/SPECS/mysql-*
|
||||
rm -rf /var/tmp/mysql
|
||||
--cc=<compiler> Use <compiler> to compile C code
|
||||
--ccflags=<flags> Use special C compiler flags
|
||||
--cxx=<compiler> Use <compiler> to compile C++ code
|
||||
--cxxflags=<flags> Use special C++ compiler flags
|
||||
-c, --clean Clean up after the build
|
||||
-t, --dry-run Dry run without executing
|
||||
-h, --help Print this help
|
||||
-l, --log[=<filename>] Write a log file [to <filename>]
|
||||
(default is "$LOGFILE")
|
||||
-m, --mail=<address> Mail a failure report to the given address
|
||||
(and include a log file snippet, if logging
|
||||
is enabled)
|
||||
Note that the \@-Sign needs to be quoted!
|
||||
Example: --mail=user\\\@domain.com
|
||||
-v, --verbose Verbose execution
|
||||
|
||||
# Copy MySQL source and spec files
|
||||
|
||||
#Sasha: I left the scp stuff commented out instead of deleted to make it
|
||||
#easy to revert in a hurry, if there is a need. Once everything is tested
|
||||
#and works perfectly, the scp stuff should be deleted to avoid confusion
|
||||
|
||||
#scp $bpath/mysql-$VER.tar.gz $owner@$bmachine:$rpmdir/SOURCES
|
||||
copy_to_bmachine $tarball $rpmdir/SOURCES
|
||||
#scp $bpath/Docs/Images/mysql-logo.gif $owner@$bmachine:$rpmdir/SOURCES/mysql.gif
|
||||
copy_to_bmachine $bpath/Docs/Images/mysql-logo.gif $rpmdir/SOURCES/mysql.gif
|
||||
#scp $bpath/support-files/mysql-$VER.spec $owner@$bmachine:$rpmdir/SPECS
|
||||
copy_to_bmachine $bpath/support-files/mysql-$VER.spec $rpmdir/SPECS
|
||||
|
||||
# Copy perl things. Has to be uncompressed since Compress.pm is not
|
||||
# installed yet. Set CEXT to .gz when we support compression.
|
||||
CEXT=
|
||||
#scp $bpath/Perl-mysql-modules/To-SOURCES/* $owner@$bmachine:$rpmdir/SOURCES
|
||||
|
||||
# This had to be installed on the target machince!
|
||||
# http://www.perl.com/CPAN/modules/by-module/Archive/Archive-Tar-0.21.tar.gz
|
||||
# cd /usr/lib/perl5/site_perl/5.005; ln -s ../* .; rm -f 5.005
|
||||
|
||||
TMP_SCRIPT_MYSQL=00-temp-for-do-rpm.$$
|
||||
cat > $logdir/$TMP_SCRIPT_MYSQL <<END
|
||||
set -x
|
||||
|
||||
# Check environment
|
||||
#export MYSQL_BUILD_PATH="/usr/local/bin:/my/gnu/bin:/usr/bin:/bin"
|
||||
#export MYSQL_BUILD_CFLAGS="-O6 -fno-omit-frame-pointer -mcpu=pentiumpro"
|
||||
#export MYSQL_BUILD_CXXFLAGS="-O6 -fno-omit-frame-pointer \
|
||||
# -felide-constructors -fno-exceptions -fno-rtti -mcpu=pentiumpro"
|
||||
export MYSQL_BUILD_PATH="/usr/bin:/bin"
|
||||
export MYSQL_BUILD_CFLAGS="-O6 -fno-omit-frame-pointer -mpentium"
|
||||
export MYSQL_BUILD_CXXFLAGS="-O6 -fno-omit-frame-pointer \
|
||||
-felide-constructors -fno-exceptions -fno-rtti -mpentium"
|
||||
gcc -v
|
||||
|
||||
# Make RPM
|
||||
rpm -ba $rpmdir/SPECS/mysql-$VER.spec
|
||||
rm -f /tmp/$TMP_SCRIPT_MYSQL
|
||||
END
|
||||
|
||||
if [ ! x$skip_perl=x1 ]; then
|
||||
|
||||
TMP_SCRIPT_PERL=00-temp-for-perl-rpm.$$
|
||||
cat > $logdir/$TMP_SCRIPT_PERL <<END
|
||||
set -x
|
||||
|
||||
# First clean up so we do not get old versions when wildcard matching
|
||||
rm -f $rpmdir/SOURCES/DBI-*.spec $rpmdir/SOURCES/mysql*
|
||||
rm -f $rpmdir/RPMS/i386/Perl-*.rpm
|
||||
rm -f $rpmdir/SRPMS/Perl-*.rpm
|
||||
rm -f $rpmdir/RPMS/i386/MySQL*-$VER_NO_DASH*.rpm
|
||||
rm -f $rpmdir/SRPMS/MySQL*-$VER_NO_DASH*.rpm
|
||||
|
||||
chmod a+x ${MAKERPM}
|
||||
rm
|
||||
|
||||
${MAKERPM} --verbose --package-name=DBI --package-version ${DBI_VERSION} \
|
||||
--specs --source=DBI-${DBI_VERSION}.tar$CEXT
|
||||
|
||||
rpm -ba $rpmdir/SPECS/DBI-${DBI_VERSION}.spec
|
||||
|
||||
${MAKERPM} --verbose --package-name=Data-ShowTable \
|
||||
--package-version ${DATA_SHOWTABLE_VERSION} \
|
||||
--specs --source=Data-ShowTable-${DATA_SHOWTABLE_VERSION}.tar$CEXT
|
||||
|
||||
rpm -ba $rpmdir/SPECS/Data-ShowTable-${DATA_SHOWTABLE_VERSION}.spec
|
||||
|
||||
for v in ${DBD_MYSQL_VERSION}; do
|
||||
${MAKERPM}
|
||||
--specs \
|
||||
--source=Msql-Mysql-modules-$v.tar$CEXT \
|
||||
--setup-dir=Msql-Mysql-modules-$v \
|
||||
--package-name=DBD-mysql \
|
||||
--package-version=$v \
|
||||
--makemakeropts='--noprompt --mysql-install --mysql-install-nodbd \
|
||||
--nomsql-install --nomsql1-install' \
|
||||
--require=perl-Data-ShowTable --require=perl-DBI
|
||||
rpm -ba $rpmdir/SPECS/DBD-mysql-$v.spec
|
||||
done
|
||||
|
||||
for srcrpm in $rpmdir/SRPMS/perl-*.src.rpm
|
||||
do
|
||||
rpm --rebuild $srcrpm
|
||||
done
|
||||
|
||||
rm -f /tmp/$TMP_SCRIPT_PERL
|
||||
END
|
||||
fi
|
||||
|
||||
# scp $bpath/Logs/$TMP_SCRIPT_MYSQL $owner@$bmachine:/tmp/$TMP_SCRIPT_MYSQL
|
||||
|
||||
# ssh $bmachine -l $owner bash $bpath/Logs/$TMP_SCRIPT_MYSQL
|
||||
|
||||
cmd=$logdir/$TMP_SCRIPT_MYSQL
|
||||
run_command $cmd
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
echo "$cmd failed, perhaps the following will help figure out why:"
|
||||
tail $log
|
||||
fi
|
||||
|
||||
if [ x$local_build != x1 ]; then
|
||||
|
||||
# Build perl RPM (we currently need to be root to do this and that is
|
||||
# not possible)
|
||||
|
||||
#scp $bpath/Logs/$TMP_SCRIPT_PERL $owner@$bmachine:/tmp/$TMP_SCRIPT_PERL
|
||||
#ssh $bmachine -l root bash /tmp/$TMP_SCRIPT_PERL
|
||||
|
||||
# Copy RPMs back to the source dir. We must do this here since the
|
||||
# $bmachine may not have permission to access $smachine.
|
||||
scp $owner@$bmachine:$rpmdir/RPMS/i386/MySQL*-$VER_NO_DASH*.rpm $bpath/NEW-RPMS
|
||||
scp $owner@$bmachine:$rpmdir/SRPMS/MySQL*-$VER_NO_DASH*.rpm $bpath/NEW-RPMS
|
||||
|
||||
# And the perl ones
|
||||
#scp $owner@$bmachine:$rpmdir/RPMS/i386/Perl*-*.rpm $bpath/NEW-RPMS
|
||||
#scp $owner@$bmachine:$rpmdir/SRPMS/Perl*-*.rpm $bpath/NEW-RPMS
|
||||
|
||||
#Remove some of the files that can interfere with future builds
|
||||
|
||||
rm -rf /var/tmp/mysql
|
||||
fi
|
||||
) > $log 2>&1
|
||||
EOF
|
||||
exit 1;
|
||||
}
|
||||
|
@ -41,10 +41,10 @@ paper: manual_a4.ps manual_letter.ps $(PDFMANUAL)
|
||||
# The Makefile contains the previous version so we can not use that
|
||||
include.texi: ../configure.in
|
||||
echo "@c This file is autogenerated by the Makefile" > $@
|
||||
echo -n "@set mysql_version " >> $@
|
||||
echo -n "@set mysqlversion " >> $@
|
||||
grep "AM_INIT_AUTOMAKE(mysql, " ../configure.in | \
|
||||
sed -e 's;AM_INIT_AUTOMAKE(mysql, ;;' -e 's;);;' >> $@
|
||||
echo -n "@set default_port " >> $@
|
||||
echo -n "@set defaultport " >> $@
|
||||
grep "MYSQL_TCP_PORT_DEFAULT=" ../configure.in | \
|
||||
sed -e 's;MYSQL_TCP_PORT_DEFAULT=;;' >> $@
|
||||
|
||||
|
@ -1,20 +1,21 @@
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIDQjCCAqugAwIBAgIBADANBgkqhkiG9w0BAQQFADB6MQswCQYDVQQGEwJSVTET
|
||||
MBEGA1UECBMKU29tZS1TdGF0ZTERMA8GA1UEBxMIT3JlbmJ1cmcxETAPB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V2ZWxvcGVyQG15c3FsLmNv
|
||||
bYIBADAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBBAUAA4GBAJFucCIj0wREcF9P
|
||||
vOaKVbvcaBwgit6oXOf7ZOPcIUQxQJOnXLVkWIdMP2mP/zHAUsCmXT2k8aXWRegB
|
||||
6kh/PjV/vSYFbGtE/vh/12x/nSIUU+Y9B1EwvoeskuOwu34Ih514Y1z1bPMNt18N
|
||||
4LGzMEBeklJ3gxBPlRXER9BSUpRH
|
||||
-----END CERTIFICATE-----
|
||||
|
@ -3,24 +3,24 @@ Certificate:
|
||||
Version: 3 (0x2)
|
||||
Serial Number: 2 (0x2)
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
Issuer: C=RU, ST=Some-State, L=Orenburg, O=MySQL AB, CN=Walrus/Email=walrus@mysql.com
|
||||
Issuer: C=SE, L=Uppsala, O=MySQL AB, CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com
|
||||
Validity
|
||||
Not Before: Aug 2 22:08:07 2002 GMT
|
||||
Not After : Aug 2 22:08:07 2003 GMT
|
||||
Subject: C=RU, L=orenburg, O=MySQL AB, OU=client, CN=walrus/Email=walrus@mysql.com
|
||||
Not Before: Aug 7 11:41:56 2003 GMT
|
||||
Not After : Aug 4 11:41:56 2013 GMT
|
||||
Subject: C=SE, L=Uppsala, O=MySQL AB, CN=MySQL Client/Email=abstract.mysql.developer@mysql.com
|
||||
Subject Public Key Info:
|
||||
Public Key Algorithm: rsaEncryption
|
||||
RSA Public Key: (1024 bit)
|
||||
Modulus (1024 bit):
|
||||
00:ab:27:e4:1e:f0:34:8b:a9:50:df:0a:b0:55:20:
|
||||
b3:1f:0f:cf:f1:51:1e:66:48:a6:f8:4e:0d:d4:49:
|
||||
f4:ea:d3:41:6b:7e:06:78:3c:29:9d:8e:d3:33:4d:
|
||||
0b:fc:34:4d:18:88:48:61:af:11:da:db:84:c0:92:
|
||||
91:81:6a:b6:21:d5:8e:9b:f2:6f:d8:06:ad:d6:77:
|
||||
f6:8b:bd:07:d5:b7:fb:c6:f0:64:e6:3f:58:f0:6a:
|
||||
1e:81:73:97:6d:9d:c6:ec:b0:5e:1e:c6:57:82:b0:
|
||||
98:9c:ae:26:84:43:0d:98:6c:b4:d8:52:13:70:15:
|
||||
79:61:40:84:19:ea:f6:63:3f
|
||||
00:c4:03:0a:ee:e3:b1:12:fc:ee:b4:19:f4:e1:60:
|
||||
1d:e0:28:c3:96:2d:df:82:69:cd:74:7c:54:58:d0:
|
||||
ae:b3:59:3f:0c:19:1c:99:10:a6:12:c9:cf:3a:64:
|
||||
05:43:8e:bf:d2:65:36:80:91:0b:65:b0:27:26:38:
|
||||
c9:23:d8:36:a2:4a:f0:f7:c0:2f:68:38:70:01:27:
|
||||
29:ff:b2:c5:52:e1:6b:f1:c8:d7:c3:5c:ee:f0:37:
|
||||
6c:2a:9b:96:1a:05:9e:eb:33:a2:39:5a:77:66:62:
|
||||
27:75:1f:2f:6f:38:da:e5:9f:78:af:ca:6b:22:3f:
|
||||
57:2b:bc:a6:8f:47:d1:99:6f
|
||||
Exponent: 65537 (0x10001)
|
||||
X509v3 extensions:
|
||||
X509v3 Basic Constraints:
|
||||
@ -28,39 +28,40 @@ Certificate:
|
||||
Netscape Comment:
|
||||
OpenSSL Generated Certificate
|
||||
X509v3 Subject Key Identifier:
|
||||
A6:D9:70:92:AC:2B:F6:48:A5:FB:29:CF:78:4A:57:B5:3B:43:97:EE
|
||||
80:81:A9:22:EB:AB:D6:CA:7E:3F:8D:BB:D1:AC:2A:F4:87:9D:13:29
|
||||
X509v3 Authority Key Identifier:
|
||||
keyid:D9:D8:6A:7D:AB:CE:10:62:1A:16:FC:E9:6A:F4:DC:F1:66:AC:D0:B9
|
||||
DirName:/C=RU/ST=Some-State/L=Orenburg/O=MySQL AB/CN=Walrus/Email=walrus@mysql.com
|
||||
keyid:95:4A:41:3E:F1:5C:12:B4:7B:3E:9F:3B:0C:23:66:90:3D:7F:4E:D8
|
||||
DirName:/C=SE/L=Uppsala/O=MySQL AB/CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com
|
||||
serial:00
|
||||
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
15:96:43:10:89:e0:a6:82:a4:91:0f:7e:2e:d8:80:54:ba:63:
|
||||
e2:8f:b0:aa:ea:be:35:2c:8f:0d:03:a9:86:2e:32:51:33:8a:
|
||||
cc:b2:5e:b3:12:cb:b7:42:06:40:89:ce:92:87:40:f1:6a:79:
|
||||
0c:3e:00:1d:06:bf:3c:c1:da:f6:3b:e1:42:e6:55:4c:31:e1:
|
||||
b9:79:f3:99:14:f6:68:9e:67:2b:e3:71:88:6b:2b:e2:08:bd:
|
||||
67:79:ea:0e:7d:34:0d:41:22:3a:f4:8f:4d:51:07:6f:5a:44:
|
||||
34:05:d1:b3:ca:cf:09:2b:43:25:a1:7f:ac:f4:54:f1:e3:93:
|
||||
47:44
|
||||
6d:8a:af:34:07:ac:95:72:a4:78:fe:f8:b8:30:9a:e0:d9:74:
|
||||
82:34:5c:fd:11:15:dd:63:fd:65:20:04:7e:b5:8f:2e:26:ef:
|
||||
ab:b9:10:5f:9b:40:65:76:ab:ed:bd:bf:d5:bc:89:7f:19:d8:
|
||||
a7:b5:9e:24:bd:c7:ac:8e:16:35:83:c8:ce:8d:85:7c:b4:36:
|
||||
28:dd:3a:97:e5:b2:dd:8f:88:4d:5b:50:bd:97:28:61:8e:e7:
|
||||
05:5c:c2:bb:46:a1:ac:7e:ee:ac:7d:72:d5:a7:07:4e:1d:68:
|
||||
4e:80:e2:35:7d:db:24:73:be:bc:0d:ca:f4:ae:4e:21:52:3b:
|
||||
ae:81
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIDajCCAtOgAwIBAgIBAjANBgkqhkiG9w0BAQQFADB6MQswCQYDVQQGEwJSVTET
|
||||
MBEGA1UECBMKU29tZS1TdGF0ZTERMA8GA1UEBxMIT3JlbmJ1cmcxETAPBgNVBAoT
|
||||
CE15U1F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y+py0Rn0i5Ay0N3T715vkThf
|
||||
CfOHE3L91dLlmYpL5xVqOpugY/2sHyxwctv97DgS6tHZ
|
||||
-----END RSA PRIVATE KEY-----
|
||||
|
@ -1,30 +1,12 @@
|
||||
-----BEGIN RSA PRIVATE KEY-----
|
||||
Proc-Type: 4,ENCRYPTED
|
||||
DEK-Info: DES-EDE3-CBC,8CE2AB38FB50D4B9
|
||||
|
||||
rrnYZLUKlzV4U7+wqe5CWzTd4RLJb5h4M77aBRQfuHGejSaRsskN2ffpO8uQEAYM
|
||||
WTJSRC+NO+jDMBZhzt1ktWqCs8d6l6azHoBybIrMJsbUhwybm+OiOfp23RrbNoS/
|
||||
S4fsgNdAAGhsRvKDdsItCyYvdH8nTzn+g9r/z2V4tOOXd6MYuT42XA6Uz2tis2SZ
|
||||
GWEGa7mAweApzSiibE+pzjPS+fdX4E12n6NCVYLhn1JuvzVva/KFSebs4Wh75miC
|
||||
WvRgkt/5eDQn+vkV67hE3I6p9pPcLh1+PMfaQ25U8VM/r7ejnVFWm7teGH6GKPKJ
|
||||
cU+PYfblyWcgtiO/fwfGMIqSyNtHj/C3VFVie5D1MTJzBopiPGEcfz00LjBccjjh
|
||||
j1meTRVN8pMZTgkxlnIFwbU6TPPvx8a9urFVQIJ4z8r2EMvYh5Cqpq87+lH9Pn0C
|
||||
vzCl78Tz5QLghXNnMbbdD2aPP0PwPEXgh86iZxo06g85n0l26WUzYJlWzBYD4DrF
|
||||
SbnEUAftTujEOm6MqJNLpJN6UPOtq/HvSaHl1bykGK+zU4gqHj0ur03HlF0l4xNg
|
||||
OfsoNsJV+O9RUUJ0+D5eqUALJjN8TCV1wNMXOVzr/ue3QCVdlWVfZY4RPffwK9Yp
|
||||
Fh52T7a2v+shhqZUQNtFDAg50Ac7deUthSWNmi5N680POnJg9KdtBdMhYLa1j3rP
|
||||
D9oasSK0ugevHuQ6wUiD/95CzZlJXE9K4kTTYmaRk5MTWXhFQxdqHZo1v+pGtaNI
|
||||
f+/E7q7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34JpzXR8
|
||||
VFjQrrNZPwwZHJkQphLJzzpkBUOOv9JlNoCRC2WwJyY4ySPYNqJK8PfAL2g4cAEn
|
||||
Kf+yxVLha/HI18Nc7vA3bCqblhoFnuszojlad2ZiJ3UfL2842uWfeK/KayI/Vyu8
|
||||
po9H0ZlvAgMBAAGgADANBgkqhkiG9w0BAQQFAAOBgQAnKdk68dGJXvlj/GXwBUWN
|
||||
oXWF7hq4fDmwyhmcFUqk8qZKPKFUxkcER0GLzYeUgvD2URSfaS3/YW0d7K7kXGwP
|
||||
rB5edb+suaYf6mjm/w37xw/EJI9rdSKcB/3SSu8mALds7sUHDAO+MO0WkA/9d7t0
|
||||
LOsUqcDvMkKpZuYwNILwLw==
|
||||
-----END CERTIFICATE REQUEST-----
|
||||
|
@ -3,24 +3,24 @@ Certificate:
|
||||
Version: 3 (0x2)
|
||||
Serial Number: 1 (0x1)
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
Issuer: C=RU, ST=Some-State, L=Orenburg, O=MySQL AB, CN=Walrus/Email=walrus@mysql.com
|
||||
Issuer: C=SE, L=Uppsala, O=MySQL AB, CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com
|
||||
Validity
|
||||
Not Before: Aug 2 21:59:26 2002 GMT
|
||||
Not After : Aug 2 21:59:26 2003 GMT
|
||||
Subject: C=RU, L=Orenburg, O=MySQL AB, CN=server/Email=walrus@mysql.com
|
||||
Not Before: Aug 7 11:39:27 2003 GMT
|
||||
Not After : Aug 4 11:39:27 2013 GMT
|
||||
Subject: C=SE, L=Uppsala, O=MySQL AB, CN=MySQL Server/Email=abstract.mysql.developer@mysql.com
|
||||
Subject Public Key Info:
|
||||
Public Key Algorithm: rsaEncryption
|
||||
RSA Public Key: (1024 bit)
|
||||
Modulus (1024 bit):
|
||||
00:bd:7d:f1:91:51:38:fe:4b:79:b5:ff:e0:41:ae:
|
||||
0e:a8:bb:7b:60:42:95:01:75:e7:22:74:55:7d:74:
|
||||
4d:50:51:0c:5e:09:4b:2b:0c:8e:3f:9f:14:3f:5e:
|
||||
d9:25:36:9b:cc:77:35:30:e9:8c:bf:3b:bd:da:62:
|
||||
85:4c:90:c8:de:71:2c:0a:7b:dc:e6:85:fd:b4:24:
|
||||
88:a7:8f:03:3d:15:7c:59:3d:f8:73:f0:36:2a:b8:
|
||||
80:7c:d8:c7:d6:1f:6d:b2:b7:b7:48:9f:24:56:81:
|
||||
2c:2e:9c:b9:95:48:50:56:9f:1a:60:96:c4:c0:eb:
|
||||
8d:2d:55:38:3f:6b:82:bc:b3
|
||||
00:e9:86:7a:55:84:88:4c:be:a4:f8:92:73:30:12:
|
||||
49:0b:7a:85:87:39:34:39:0d:7d:0b:8d:18:c2:17:
|
||||
95:13:52:d2:3f:55:10:57:c8:3f:5a:f5:b2:fa:8b:
|
||||
d0:67:49:cc:aa:82:fc:9f:ce:00:b4:73:f3:36:d2:
|
||||
3a:d3:c2:b0:0e:14:c3:d4:b2:21:74:a1:f0:31:81:
|
||||
60:87:98:73:5c:10:c1:b1:1a:4d:f1:f3:b0:98:3f:
|
||||
f0:d7:97:9b:2b:fd:d5:21:79:b2:2f:eb:64:15:c9:
|
||||
9b:9d:fc:9e:2d:d4:f8:04:5b:ea:a9:75:4b:42:c3:
|
||||
3d:0e:4d:2a:a8:b8:ca:99:8d
|
||||
Exponent: 65537 (0x10001)
|
||||
X509v3 extensions:
|
||||
X509v3 Basic Constraints:
|
||||
@ -28,38 +28,40 @@ Certificate:
|
||||
Netscape Comment:
|
||||
OpenSSL Generated Certificate
|
||||
X509v3 Subject Key Identifier:
|
||||
C9:D0:D2:F7:17:79:27:1C:4B:C9:E7:92:D5:5E:8C:7E:F2:FE:A7:B7
|
||||
6E:E4:9B:6A:C5:EA:E4:E6:C7:EF:D7:1E:C8:63:45:60:2B:1B:D4:D4
|
||||
X509v3 Authority Key Identifier:
|
||||
keyid:D9:D8:6A:7D:AB:CE:10:62:1A:16:FC:E9:6A:F4:DC:F1:66:AC:D0:B9
|
||||
DirName:/C=RU/ST=Some-State/L=Orenburg/O=MySQL AB/CN=Walrus/Email=walrus@mysql.com
|
||||
keyid:95:4A:41:3E:F1:5C:12:B4:7B:3E:9F:3B:0C:23:66:90:3D:7F:4E:D8
|
||||
DirName:/C=SE/L=Uppsala/O=MySQL AB/CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com
|
||||
serial:00
|
||||
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
62:77:bc:16:dc:4c:70:63:4d:03:ce:19:5e:c4:6c:31:0e:57:
|
||||
26:d8:6e:25:08:f2:01:ae:98:59:0a:ba:b7:32:c0:39:69:b8:
|
||||
4b:aa:59:7c:97:72:4e:50:02:ee:ef:d6:d6:62:b8:25:36:91:
|
||||
b6:3b:8f:6f:2f:3c:d8:9d:b7:cf:8f:f6:29:50:e9:31:54:77:
|
||||
2b:7b:21:72:0f:60:4c:d4:1c:bb:c4:46:e5:fd:a7:5f:ea:46:
|
||||
e4:df:e9:95:77:2d:91:f8:3b:33:78:83:5d:10:de:98:7c:38:
|
||||
91:27:f6:52:8a:b6:54:f1:0f:7a:f0:1d:da:a5:22:d2:75:cc:
|
||||
4c:c3
|
||||
7c:b6:9c:fc:ea:9e:e6:88:32:f5:24:81:9b:89:c0:13:fa:75:
|
||||
18:51:af:77:ae:b8:4e:12:5f:48:ab:0c:e6:c5:a4:87:93:6e:
|
||||
98:97:f5:f3:d3:0b:e0:fc:5e:34:3e:f2:93:58:73:97:b6:a7:
|
||||
66:96:81:cd:73:48:f3:75:24:64:61:13:78:3e:ed:df:7c:4d:
|
||||
fa:2e:3a:64:99:12:24:9e:a2:51:5c:23:85:0b:0c:bb:f5:8e:
|
||||
89:80:27:ba:7c:d2:68:90:ff:1f:68:2e:1b:fd:06:bc:c8:41:
|
||||
d7:b2:be:9c:94:5c:6d:1e:96:3b:75:bc:12:f0:44:bd:36:00:
|
||||
84:cd
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIDWTCCAsKgAwIBA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VwStHs+nzsMI2aQPX9O2KGB
|
||||
jqSBizCBiDELMAkGA1UEBhMCU0UxEDAOBgNVBAcTB1VwcHNhbGExETAPBgNVBAoT
|
||||
CE15U1FMIEFCMSEwHwYDVQQDExhBYnN0cmFjdCBNeVNRTCBEZXZlbG9wZXIxMTAv
|
||||
BgkqhkiG9w0BCQEWImFic3RyYWN0Lm15c3FsLmRldmVsb3BlckBteXNxbC5jb22C
|
||||
AQAwDQYJKoZIhvcNAQEEBQADgYEAfLac/Oqe5ogy9SSBm4nAE/p1GFGvd664ThJf
|
||||
SKsM5sWkh5NumJf189ML4PxeND7yk1hzl7anZpaBzXNI83UkZGETeD7t33xN+i46
|
||||
ZJkSJJ6iUVwjhQsMu/WOiYAnunzSaJD/H2guG/0GvMhB17K+nJRcbR6WO3W8EvBE
|
||||
vTYAhM0=
|
||||
-----END CERTIFICATE-----
|
||||
|
@ -1,15 +1,15 @@
|
||||
-----BEGIN RSA PRIVATE KEY-----
|
||||
MIICXAIBAAKBgQC9ffGRUTj+S3m1/+BBrg6ou3tgQpUBdecidFV9dE1QUQxeCUsr
|
||||
DI4/nxQ/XtklNpvMdzUw6Yy/O73aYoVMkMjecSwKe9zmhf20JIinjwM9FXxZPfhz
|
||||
8DYquIB82MfWH22yt7dInyRWgSwunLmVSFBWnxpglsTA640tVTg/a4K8swIDAQAB
|
||||
AoGARciG2NRHn+aduPe1V5rJDTyWD/oVM8d+ykJ7ZUsaWdSvMEZN51mlXSqxYzED
|
||||
2N+GesL/1LZ9vcM7hJw5qNu9DQOc7CtMT4k/bmhPJsT226roKKVbw/ocOEY5dK8+
|
||||
T9/x8qgo7zC3Qk/bKgjj61m8cQ7Mz/J7ZCEMmDNNrORCzRECQQDrcvJlsBTALilr
|
||||
MaAqNyaa0tykEabzg2mUFx5uvmzlwNx9ApSidoU5Xop9c6u00zgCDpsDlcwjhOs1
|
||||
jcqRkBTrAkEAzggY7BeN3FnW8tsV0Wq4LL6vK30pe0JIylxrKsFjY4LTo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hehCQEqoW+qDSy5fc4orI7eU
|
||||
SuMUa2OgCjGqv7p6wKFJAkEAznmum/MbVOBpC4FsdnIGkxyFKIbh2OLY2aUb2KkK
|
||||
Ouf4S8Y5Ldgszi0fnDPRaxWJzewwZKvcff2zj+mYZeAXbA==
|
||||
-----END RSA PRIVATE KEY-----
|
||||
|
@ -1,30 +1,12 @@
|
||||
-----BEGIN RSA PRIVATE KEY-----
|
||||
Proc-Type: 4,ENCRYPTED
|
||||
DEK-Info: DES-EDE3-CBC,6CBD09E71246DC01
|
||||
|
||||
byRzq5+j3r8FX2kQerTUZT5Bw/N6zrN3cmH6NHGJcrqD+vcPdtWf+Rk+mpNXgSQn
|
||||
ldkfmniU/htzJ0cUV+KE229Qx10Hx9mIJIbf0Y/rBCUBuaXWVrQB36W9w3rkNPFA
|
||||
EEuRMkreOJF42RD16+NBJv+RcHIGzGejXecJKUGF5DKlN0U8YHXnkXTQl54kIdr0
|
||||
H7rTrvJygwPk9/ik0M9/vmwduAMvTaHDmvgeolpMlJkxwz8vYkbUnFFJZhB6XNCb
|
||||
1w3lJ0EmRJicK5BnZmCEmgt8xiv0PAtg00jBbwddQbn1reAyViBtBT9iXdusHXS5
|
||||
Po63rSt7r3MO8aetcMQ6FkklH+ChuS/vFoNY57AwrzF4uEI4GSoZP0ESrRC5Ar5W
|
||||
Lzg/HrQAWbPCRlb6Jj3db1woRzFS8joOashROsZdeV/5P4Emhc6J7QMTvB1OHAhQ
|
||||
ugOJazJtxjg0DN8+9cM1wtHI7N89PLHhOg13LZNLeeehzIlPwKI2JLqXUc6oR407
|
||||
i+S7GCqu7wU+if0Enux8Dj7yrvnTUiqVCL2dyKTS3sBq0Cm2UhbecHclor13y6no
|
||||
y1o50TKKD6Zig2hZmSpqKznMxGMVIT36BE0aOMQUmk+aVnRuROclwTTL0ZNLzA+g
|
||||
QRTRfQ6iNMf34ypqAMdAMPzDGLPycKuFdxVQxFEVaM2/mrdWFwVAqFsLvzyGvdrh
|
||||
nkNyR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20wgZ8wDQYJ
|
||||
KoZIhvcNAQEBBQADgY0AMIGJAoGBAOmGelWEiEy+pPiSczASSQt6hYc5NDkNfQuN
|
||||
GMIXlRNS0j9VEFfIP1r1svqL0GdJzKqC/J/OALRz8zbSOtPCsA4Uw9SyIXSh8DGB
|
||||
YIeYc1wQwbEaTfHzsJg/8NeXmyv91SF5si/rZBXJm538ni3U+ARb6ql1S0LDPQ5N
|
||||
Kqi4ypmNAgMBAAGgADANBgkqhkiG9w0BAQQFAAOBgQCagJxGHBC+G5aSh3OguFn6
|
||||
z+qAC7u3B181kPBgNv20zMgLeq7YiAh3iNx4XO2+QXRGzMznFKx1tFr/mavCpgLs
|
||||
p3+dCvQt5FHEFFK1D1pDeXy4146X07hOTtC9jc/jSWeVnH4ujuX5gMtZqisOyYWV
|
||||
/gpw6dBtkTYlhS+y86kM/Q==
|
||||
-----END CERTIFICATE REQUEST-----
|
||||
|
39
acinclude.m4
39
acinclude.m4
@ -50,7 +50,7 @@ mysql_cv_btype_last_arg_accept=none
|
||||
],
|
||||
[int a = accept(1, (struct sockaddr *) 0, (socklen_t *) 0); return (a != 0);],
|
||||
mysql_cv_btype_last_arg_accept=socklen_t)]
|
||||
if test $mysql_cv_btype_last_arg_accept = none; then
|
||||
if test "$mysql_cv_btype_last_arg_accept" = "none"; then
|
||||
[AC_TRY_COMPILE([#if defined(inline)
|
||||
#undef inline
|
||||
#endif
|
||||
@ -61,7 +61,7 @@ if test $mysql_cv_btype_last_arg_accept = none; then
|
||||
[int a = accept(1, (struct sockaddr *) 0, (size_t *) 0); return (a != 0);],
|
||||
mysql_cv_btype_last_arg_accept=size_t)]
|
||||
fi
|
||||
if test $mysql_cv_btype_last_arg_accept = none; then
|
||||
if test "$mysql_cv_btype_last_arg_accept" = "none"; then
|
||||
mysql_cv_btype_last_arg_accept=int
|
||||
fi)
|
||||
AC_LANG_RESTORE
|
||||
@ -353,11 +353,11 @@ AC_CACHE_VAL(mysql_cv_termcap_lib,
|
||||
[AC_CHECK_LIB(termcap, tgetent, mysql_cv_termcap_lib=libtermcap,
|
||||
mysql_cv_termcap_lib=NOT_FOUND)])])])
|
||||
AC_MSG_CHECKING(for termcap functions library)
|
||||
if test $mysql_cv_termcap_lib = NOT_FOUND; then
|
||||
if test "$mysql_cv_termcap_lib" = "NOT_FOUND"; then
|
||||
AC_MSG_ERROR([No curses/termcap library found])
|
||||
elif test $mysql_cv_termcap_lib = libtermcap; then
|
||||
elif test "$mysql_cv_termcap_lib" = "libtermcap"; then
|
||||
TERMCAP_LIB=-ltermcap
|
||||
elif test $mysql_cv_termcap_lib = libncurses; then
|
||||
elif test "$mysql_cv_termcap_lib" = "libncurses"; then
|
||||
TERMCAP_LIB=-lncurses
|
||||
else
|
||||
TERMCAP_LIB=-lcurses
|
||||
@ -413,7 +413,7 @@ AC_CACHE_VAL(mysql_cv_can_redecl_getpw,
|
||||
extern struct passwd *getpwent();], [struct passwd *z; z = getpwent();],
|
||||
mysql_cv_can_redecl_getpw=yes,mysql_cv_can_redecl_getpw=no)])
|
||||
AC_MSG_RESULT($mysql_cv_can_redecl_getpw)
|
||||
if test $mysql_cv_can_redecl_getpw = no; then
|
||||
if test "$mysql_cv_can_redecl_getpw" = "no"; then
|
||||
AC_DEFINE(HAVE_GETPW_DECLS)
|
||||
fi
|
||||
])
|
||||
@ -425,7 +425,7 @@ AC_CACHE_VAL(mysql_cv_tiocgwinsz_in_ioctl,
|
||||
#include <sys/ioctl.h>], [int x = TIOCGWINSZ;],
|
||||
mysql_cv_tiocgwinsz_in_ioctl=yes,mysql_cv_tiocgwinsz_in_ioctl=no)])
|
||||
AC_MSG_RESULT($mysql_cv_tiocgwinsz_in_ioctl)
|
||||
if test $mysql_cv_tiocgwinsz_in_ioctl = yes; then
|
||||
if test "$mysql_cv_tiocgwinsz_in_ioctl" = "yes"; then
|
||||
AC_DEFINE(GWINSZ_IN_SYS_IOCTL)
|
||||
fi
|
||||
])
|
||||
@ -437,7 +437,7 @@ AC_CACHE_VAL(mysql_cv_fionread_in_ioctl,
|
||||
#include <sys/ioctl.h>], [int x = FIONREAD;],
|
||||
mysql_cv_fionread_in_ioctl=yes,mysql_cv_fionread_in_ioctl=no)])
|
||||
AC_MSG_RESULT($mysql_cv_fionread_in_ioctl)
|
||||
if test $mysql_cv_fionread_in_ioctl = yes; then
|
||||
if test "$mysql_cv_fionread_in_ioctl" = "yes"; then
|
||||
AC_DEFINE(FIONREAD_IN_SYS_IOCTL)
|
||||
fi
|
||||
])
|
||||
@ -449,7 +449,7 @@ AC_CACHE_VAL(mysql_cv_tiocstat_in_ioctl,
|
||||
#include <sys/ioctl.h>], [int x = TIOCSTAT;],
|
||||
mysql_cv_tiocstat_in_ioctl=yes,mysql_cv_tiocstat_in_ioctl=no)])
|
||||
AC_MSG_RESULT($mysql_cv_tiocstat_in_ioctl)
|
||||
if test $mysql_cv_tiocstat_in_ioctl = yes; then
|
||||
if test "$mysql_cv_tiocstat_in_ioctl" = "yes"; then
|
||||
AC_DEFINE(TIOCSTAT_IN_SYS_IOCTL)
|
||||
fi
|
||||
])
|
||||
@ -482,7 +482,7 @@ AC_CACHE_VAL(mysql_cv_dirent_has_dino,
|
||||
struct dirent d; int z; z = d.d_ino;
|
||||
], mysql_cv_dirent_has_dino=yes, mysql_cv_dirent_has_dino=no)])
|
||||
AC_MSG_RESULT($mysql_cv_dirent_has_dino)
|
||||
if test $mysql_cv_dirent_has_dino = yes; then
|
||||
if test "$mysql_cv_dirent_has_dino" = "yes"; then
|
||||
AC_DEFINE(STRUCT_DIRENT_HAS_D_INO)
|
||||
fi
|
||||
])
|
||||
@ -501,7 +501,7 @@ extern "C"
|
||||
void (*signal ()) ();],
|
||||
[int i;], mysql_cv_void_sighandler=yes, mysql_cv_void_sighandler=no)])dnl
|
||||
AC_MSG_RESULT($mysql_cv_void_sighandler)
|
||||
if test $mysql_cv_void_sighandler = yes; then
|
||||
if test "$mysql_cv_void_sighandler" = "yes"; then
|
||||
AC_DEFINE(VOID_SIGHANDLER)
|
||||
fi
|
||||
])
|
||||
@ -560,7 +560,7 @@ then
|
||||
AC_CACHE_CHECK([for working alloca.h], ac_cv_header_alloca_h,
|
||||
[AC_TRY_LINK([#include <alloca.h>], [char *p = alloca(2 * sizeof(int));],
|
||||
ac_cv_header_alloca_h=yes, ac_cv_header_alloca_h=no)])
|
||||
if test $ac_cv_header_alloca_h = yes
|
||||
if test "$ac_cv_header_alloca_h" = "yes"
|
||||
then
|
||||
AC_DEFINE(HAVE_ALLOCA)
|
||||
fi
|
||||
@ -584,11 +584,11 @@ then
|
||||
#endif
|
||||
], [char *p = (char *) alloca(1);],
|
||||
ac_cv_func_alloca_works=yes, ac_cv_func_alloca_works=no)])
|
||||
if test $ac_cv_func_alloca_works = yes; then
|
||||
if test "$ac_cv_func_alloca_works" = "yes"; then
|
||||
AC_DEFINE(HAVE_ALLOCA)
|
||||
fi
|
||||
|
||||
if test $ac_cv_func_alloca_works = no; then
|
||||
if test "$ac_cv_func_alloca_works" = "no"; then
|
||||
# The SVR3 libPW and SVR4 libucb both contain incompatible functions
|
||||
# that cause trouble. Some versions do not even contain alloca or
|
||||
# contain a buggy version. If you still want to use their alloca,
|
||||
@ -604,7 +604,7 @@ then
|
||||
wenotbecray
|
||||
#endif
|
||||
], ac_cv_os_cray=yes, ac_cv_os_cray=no)])
|
||||
if test $ac_cv_os_cray = yes; then
|
||||
if test "$ac_cv_os_cray" = "yes"; then
|
||||
for ac_func in _getb67 GETB67 getb67; do
|
||||
AC_CHECK_FUNC($ac_func, [AC_DEFINE_UNQUOTED(CRAY_STACKSEG_END, $ac_func)
|
||||
break])
|
||||
@ -745,7 +745,7 @@ AC_DEFUN(MYSQL_FIND_OPENSSL, [
|
||||
for d in /usr/kerberos/include
|
||||
do
|
||||
if test -f $d/krb5.h ; then
|
||||
OPENSSL_INCLUDE="$OPENSSL_INCLUDE -I$d"
|
||||
OPENSSL_KERBEROS_INCLUDE="$d"
|
||||
fi
|
||||
done
|
||||
|
||||
@ -794,10 +794,15 @@ AC_MSG_CHECKING(for OpenSSL)
|
||||
openssl_libs="-L$OPENSSL_LIB -lssl -lcrypto"
|
||||
# Don't set openssl_includes to /usr/include as this gives us a lot of
|
||||
# compiler warnings when using gcc 3.x
|
||||
openssl_includes=""
|
||||
if test "$OPENSSL_INCLUDE" != "-I/usr/include"
|
||||
then
|
||||
openssl_includes="$OPENSSL_INCLUDE"
|
||||
fi
|
||||
if test "$OPENSSL_KERBEROS_INCLUDE"
|
||||
then
|
||||
openssl_includes="$openssl_includes -I$OPENSSL_KERBEROS_INCLUDE"
|
||||
fi
|
||||
AC_DEFINE(HAVE_OPENSSL)
|
||||
|
||||
# openssl-devel-0.9.6 requires dlopen() and we can't link staticly
|
||||
@ -807,7 +812,7 @@ AC_MSG_CHECKING(for OpenSSL)
|
||||
case "$CLIENT_EXTRA_LDFLAGS $MYSQLD_EXTRA_LDFLAGS" in
|
||||
*-all-static*) using_static="yes" ;;
|
||||
esac
|
||||
if test $using_static = "yes"
|
||||
if test "$using_static" = "yes"
|
||||
then
|
||||
echo "You can't use the --all-static link option when using openssl."
|
||||
exit 1
|
||||
|
@ -183,7 +183,16 @@ public:
|
||||
void process(Append_block_log_event *ae)
|
||||
{
|
||||
if (ae->file_id >= file_names.elements)
|
||||
die("Skiped CreateFile event for file_id: %u",ae->file_id);
|
||||
{
|
||||
/*
|
||||
There is no Create_file event (a bad binlog or a big
|
||||
--position). Assuming it's a big --position, we just do nothing and
|
||||
print a warning.
|
||||
*/
|
||||
fprintf(stderr,"Warning: ignoring Append_block as there is no \
|
||||
Create_file event for file_id: %u\n",ae->file_id);
|
||||
return;
|
||||
}
|
||||
Create_file_log_event* ce=
|
||||
*((Create_file_log_event**)file_names.buffer + ae->file_id);
|
||||
append_to_file(ce->fname,O_APPEND|O_BINARY|O_WRONLY,ae->block,ae->block_len);
|
||||
@ -568,45 +577,49 @@ Could not read entry at offset %s : Error in log format or read error",
|
||||
}
|
||||
if (rec_count >= offset)
|
||||
{
|
||||
// see if we should skip this event (only care about queries for now)
|
||||
if (one_database)
|
||||
{
|
||||
if (ev->get_type_code() == QUERY_EVENT)
|
||||
{
|
||||
//const char * log_dbname = ev->get_db();
|
||||
const char * log_dbname = ((Query_log_event*)ev)->db;
|
||||
//printf("entry: %llu, database: %s\n", rec_count, log_dbname);
|
||||
|
||||
if ((log_dbname != NULL) && (strcmp(log_dbname, database)))
|
||||
{
|
||||
//printf("skipping, %s is not %s\n", log_dbname, database);
|
||||
rec_count++;
|
||||
delete ev;
|
||||
continue; // next
|
||||
}
|
||||
#ifndef DBUG_OFF
|
||||
else
|
||||
{
|
||||
printf("no skip\n");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#ifndef DBUG_OFF
|
||||
else
|
||||
{
|
||||
const char * query_type = ev->get_type_str();
|
||||
printf("not query -- %s\n", query_type);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
if (!short_form)
|
||||
fprintf(result_file, "# at %s\n",llstr(old_off,llbuff));
|
||||
|
||||
switch (ev->get_type_code()) {
|
||||
case QUERY_EVENT:
|
||||
if (one_database)
|
||||
{
|
||||
const char * log_dbname = ((Query_log_event*)ev)->db;
|
||||
if ((log_dbname != NULL) && (strcmp(log_dbname, database)))
|
||||
{
|
||||
rec_count++;
|
||||
delete ev;
|
||||
continue; // next
|
||||
}
|
||||
}
|
||||
ev->print(result_file, short_form, last_db);
|
||||
break;
|
||||
case CREATE_FILE_EVENT:
|
||||
{
|
||||
Create_file_log_event* ce= (Create_file_log_event*)ev;
|
||||
ce->print(result_file, short_form, last_db,true);
|
||||
if (one_database)
|
||||
{
|
||||
/*
|
||||
We test if this event has to be ignored. If yes, we don't save this
|
||||
event; this will have the good side-effect of ignoring all related
|
||||
Append_block and Exec_load.
|
||||
Note that Load event from 3.23 is not tested.
|
||||
*/
|
||||
const char * log_dbname = ce->db;
|
||||
if ((log_dbname != NULL) && (strcmp(log_dbname, database)))
|
||||
{
|
||||
rec_count++;
|
||||
delete ev;
|
||||
continue; // next
|
||||
}
|
||||
}
|
||||
/*
|
||||
We print the event, but with a leading '#': this is just to inform the
|
||||
user of the original command; the command we want to execute will be a
|
||||
derivation of this original command (we will change the filename and
|
||||
use LOCAL), prepared in the 'case EXEC_LOAD_EVENT' below.
|
||||
*/
|
||||
ce->print(result_file, short_form, last_db, true);
|
||||
load_processor.process(ce);
|
||||
ev= 0;
|
||||
break;
|
||||
@ -620,9 +633,20 @@ Could not read entry at offset %s : Error in log format or read error",
|
||||
ev->print(result_file, short_form, last_db);
|
||||
Execute_load_log_event *exv= (Execute_load_log_event*)ev;
|
||||
Create_file_log_event *ce= load_processor.grab_event(exv->file_id);
|
||||
ce->print(result_file, short_form, last_db,true);
|
||||
my_free((char*)ce->fname,MYF(MY_WME));
|
||||
delete ce;
|
||||
/*
|
||||
if ce is 0, it probably means that we have not seen the Create_file
|
||||
event (a bad binlog, or most probably --position is after the
|
||||
Create_file event). Print a warning comment.
|
||||
*/
|
||||
if (ce)
|
||||
{
|
||||
ce->print(result_file, short_form, last_db,true);
|
||||
my_free((char*)ce->fname,MYF(MY_WME));
|
||||
delete ce;
|
||||
}
|
||||
else
|
||||
fprintf(stderr,"Warning: ignoring Exec_load as there is no \
|
||||
Create_file event for file_id: %u\n",exv->file_id);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
@ -634,7 +658,7 @@ Could not read entry at offset %s : Error in log format or read error",
|
||||
delete ev;
|
||||
}
|
||||
if (fd >= 0)
|
||||
my_close(fd, MYF(MY_WME));
|
||||
my_close(fd, MYF(MY_WME));
|
||||
end_io_cache(file);
|
||||
}
|
||||
|
||||
|
@ -1459,9 +1459,8 @@ int main(int argc, char **argv)
|
||||
fprintf(md_result_file,
|
||||
"\n--\n-- Position to start replication from\n--\n\n");
|
||||
fprintf(md_result_file,
|
||||
"CHANGE MASTER TO MASTER_LOG_FILE='%s' ;\n", row[0]);
|
||||
fprintf(md_result_file, "CHANGE MASTER TO MASTER_LOG_POS=%s ;\n",
|
||||
row[1]);
|
||||
"CHANGE MASTER TO MASTER_LOG_FILE='%s', \
|
||||
MASTER_LOG_POS=%s ;\n",row[0],row[1]);
|
||||
}
|
||||
mysql_free_result(master);
|
||||
}
|
||||
|
@ -238,7 +238,7 @@ static int get_options(int *argc, char ***argv)
|
||||
static int write_to_table(char *filename, MYSQL *sock)
|
||||
{
|
||||
char tablename[FN_REFLEN], hard_path[FN_REFLEN],
|
||||
sql_statement[FN_REFLEN*2+256], *end;
|
||||
sql_statement[FN_REFLEN*16+256], *end;
|
||||
my_bool local_file;
|
||||
DBUG_ENTER("write_to_table");
|
||||
DBUG_PRINT("enter",("filename: %s",filename));
|
||||
|
@ -42,7 +42,7 @@
|
||||
|
||||
**********************************************************************/
|
||||
|
||||
#define MTEST_VERSION "1.27"
|
||||
#define MTEST_VERSION "1.28"
|
||||
|
||||
#include <my_global.h>
|
||||
#include <mysql_embed.h>
|
||||
@ -221,6 +221,13 @@ const char *command_names[]=
|
||||
"connection",
|
||||
"query",
|
||||
"connect",
|
||||
/* the difference between sleep and real_sleep is that sleep will use
|
||||
the delay from command line (--sleep) if there is one.
|
||||
real_sleep always uses delay from it's argument.
|
||||
the logic is that sometimes delays are cpu-dependent (and --sleep
|
||||
can be used to set this delay. real_sleep is used for cpu-independent
|
||||
delays
|
||||
*/
|
||||
"sleep",
|
||||
"real_sleep",
|
||||
"inc",
|
||||
@ -845,7 +852,28 @@ int var_query_set(VAR* v, const char* p, const char** p_end)
|
||||
}
|
||||
|
||||
if ((row = mysql_fetch_row(res)) && row[0])
|
||||
eval_expr(v, row[0], 0);
|
||||
{
|
||||
/*
|
||||
Concatenate all row results with tab in between to allow us to work
|
||||
with results from many columns (for example from SHOW VARIABLES)
|
||||
*/
|
||||
DYNAMIC_STRING result;
|
||||
uint i;
|
||||
ulong *lengths;
|
||||
char *end;
|
||||
|
||||
init_dynamic_string(&result, "", 16384, 65536);
|
||||
lengths= mysql_fetch_lengths(res);
|
||||
for (i=0; i < mysql_num_fields(res); i++)
|
||||
{
|
||||
if (row[0])
|
||||
dynstr_append_mem(&result, row[i], lengths[i]);
|
||||
dynstr_append_mem(&result, "\t", 1);
|
||||
}
|
||||
end= result.str + result.length-1;
|
||||
eval_expr(v, result.str, (const char**) &end);
|
||||
dynstr_free(&result);
|
||||
}
|
||||
else
|
||||
eval_expr(v, "", 0);
|
||||
|
||||
@ -902,8 +930,6 @@ int eval_expr(VAR* v, const char* p, const char** p_end)
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (p_end)
|
||||
*p_end = 0;
|
||||
die("Invalid expr: %s", p);
|
||||
return 1;
|
||||
}
|
||||
@ -1197,7 +1223,7 @@ static char *get_string(char **to_ptr, char **from_ptr,
|
||||
VAR *var=var_get(start, &end, 0, 1);
|
||||
if (var && to == (char*) end+1)
|
||||
{
|
||||
DBUG_PRINT("info",("var: %s -> %s", start, var->str_val));
|
||||
DBUG_PRINT("info",("var: '%s' -> '%s'", start, var->str_val));
|
||||
DBUG_RETURN(var->str_val); /* return found variable value */
|
||||
}
|
||||
}
|
||||
|
@ -109,7 +109,7 @@ static int get_options(int *argc,char ***argv)
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
struct hostent *hpaddr;
|
||||
u_long taddr;
|
||||
in_addr_t taddr;
|
||||
char *ip,**q;
|
||||
int error=0;
|
||||
|
||||
|
@ -276,6 +276,7 @@ inline double ulonglong2double(ulonglong value)
|
||||
#define HAVE_ISAM /* We want to have support for ISAM in 4.0 */
|
||||
#define HAVE_QUERY_CACHE
|
||||
#define SPRINTF_RETURNS_INT
|
||||
#define HAVE_SETFILEPOINTER
|
||||
|
||||
#ifdef NOT_USED
|
||||
#define HAVE_SNPRINTF /* Gave link error */
|
||||
|
@ -119,6 +119,16 @@ extern void bmove_allign(gptr dst,const gptr src,uint len);
|
||||
#define bmove512(A,B,C) memcpy(A,B,C)
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_purify
|
||||
#include <assert.h>
|
||||
#define memcpy_overlap(A,B,C) \
|
||||
DBUG_ASSERT((A) == (B) || ((A)+(C)) <= (B) || ((B)+(C)) <= (A)); \
|
||||
bmove((byte*) key,(byte*) from,(size_t) length);
|
||||
#else
|
||||
#define memcpy_overlap(A,B,C) memcpy((A), (B), (C))
|
||||
#endif /* HAVE_purify */
|
||||
|
||||
|
||||
/* Prototypes for string functions */
|
||||
|
||||
#if !defined(bfill) && !defined(HAVE_BFILL)
|
||||
|
@ -677,6 +677,8 @@ extern int _my_b_get(IO_CACHE *info);
|
||||
extern int _my_b_async_read(IO_CACHE *info,byte *Buffer,uint Count);
|
||||
extern int _my_b_write(IO_CACHE *info,const byte *Buffer,uint Count);
|
||||
extern int my_b_append(IO_CACHE *info,const byte *Buffer,uint Count);
|
||||
extern int my_b_safe_write(IO_CACHE *info,const byte *Buffer,uint Count);
|
||||
|
||||
extern int my_block_write(IO_CACHE *info, const byte *Buffer,
|
||||
uint Count, my_off_t pos);
|
||||
extern int _flush_io_cache(IO_CACHE *info, int need_append_buffer_lock);
|
||||
|
@ -34,6 +34,7 @@ Created 11/5/1995 Heikki Tuuri
|
||||
#include "ibuf0ibuf.h"
|
||||
#include "dict0dict.h"
|
||||
#include "log0recv.h"
|
||||
#include "log0log.h"
|
||||
#include "trx0undo.h"
|
||||
#include "srv0srv.h"
|
||||
|
||||
@ -273,6 +274,7 @@ buf_page_is_corrupted(
|
||||
ulint old_checksum;
|
||||
ulint checksum_field;
|
||||
ulint old_checksum_field;
|
||||
dulint current_lsn;
|
||||
|
||||
if (mach_read_from_4(read_buf + FIL_PAGE_LSN + 4)
|
||||
!= mach_read_from_4(read_buf + UNIV_PAGE_SIZE
|
||||
@ -284,6 +286,27 @@ buf_page_is_corrupted(
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
#ifndef UNIV_HOTBACKUP
|
||||
if (recv_lsn_checks_on && log_peek_lsn(¤t_lsn)) {
|
||||
if (ut_dulint_cmp(current_lsn,
|
||||
mach_read_from_8(read_buf + FIL_PAGE_LSN))
|
||||
< 0) {
|
||||
ut_print_timestamp(stderr);
|
||||
|
||||
fprintf(stderr,
|
||||
" InnoDB: Error: page %lu log sequence number %lu %lu\n"
|
||||
"InnoDB: is in the future! Current system log sequence number %lu %lu.\n"
|
||||
"InnoDB: Your database may be corrupt.\n",
|
||||
mach_read_from_4(read_buf + FIL_PAGE_OFFSET),
|
||||
ut_dulint_get_high(
|
||||
mach_read_from_8(read_buf + FIL_PAGE_LSN)),
|
||||
ut_dulint_get_low(
|
||||
mach_read_from_8(read_buf + FIL_PAGE_LSN)),
|
||||
ut_dulint_get_high(current_lsn),
|
||||
ut_dulint_get_low(current_lsn));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
old_checksum = buf_calc_page_old_checksum(read_buf);
|
||||
|
||||
old_checksum_field = mach_read_from_4(read_buf + UNIV_PAGE_SIZE
|
||||
|
@ -2405,9 +2405,12 @@ dict_strip_comments(
|
||||
ptr = str;
|
||||
|
||||
for (;;) {
|
||||
scan_more:
|
||||
if (*sptr == '\0') {
|
||||
*ptr = '\0';
|
||||
|
||||
ut_a(ptr <= str + strlen(sql_string));
|
||||
|
||||
return(str);
|
||||
}
|
||||
|
||||
@ -2421,7 +2424,7 @@ dict_strip_comments(
|
||||
|| *sptr == (char)0x0D
|
||||
|| *sptr == '\0') {
|
||||
|
||||
break;
|
||||
goto scan_more;
|
||||
}
|
||||
|
||||
sptr++;
|
||||
@ -2435,12 +2438,12 @@ dict_strip_comments(
|
||||
|
||||
sptr += 2;
|
||||
|
||||
break;
|
||||
goto scan_more;
|
||||
}
|
||||
|
||||
if (*sptr == '\0') {
|
||||
|
||||
break;
|
||||
goto scan_more;
|
||||
}
|
||||
|
||||
sptr++;
|
||||
|
@ -831,6 +831,34 @@ fil_space_release_free_extents(
|
||||
mutex_exit(&(system->mutex));
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
Gets the number of reserved extents. If the database is silent, this number
|
||||
should be zero. */
|
||||
|
||||
ulint
|
||||
fil_space_get_n_reserved_extents(
|
||||
/*=============================*/
|
||||
ulint id) /* in: space id */
|
||||
{
|
||||
fil_space_t* space;
|
||||
fil_system_t* system = fil_system;
|
||||
ulint n;
|
||||
|
||||
ut_ad(system);
|
||||
|
||||
mutex_enter(&(system->mutex));
|
||||
|
||||
HASH_SEARCH(hash, system->spaces, id, space, space->id == id);
|
||||
|
||||
ut_a(space);
|
||||
|
||||
n = space->n_reserved_extents;
|
||||
|
||||
mutex_exit(&(system->mutex));
|
||||
|
||||
return(n);
|
||||
}
|
||||
|
||||
/************************************************************************
|
||||
Prepares a file node for i/o. Opens the file if it is closed. Updates the
|
||||
pending i/o's field in the node and the system appropriately. Takes the node
|
||||
|
@ -2709,10 +2709,52 @@ fseg_free_page_low(
|
||||
return;
|
||||
}
|
||||
|
||||
/*
|
||||
fprintf(stderr,
|
||||
"InnoDB: InnoDB is freeing space %lu page %lu,\n"
|
||||
"InnoDB: which belongs to descr seg %lu %lu\n"
|
||||
"InnoDB: segment %lu %lu.\n",
|
||||
space, page,
|
||||
ut_dulint_get_high(
|
||||
mtr_read_dulint(descr + XDES_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_low(
|
||||
mtr_read_dulint(descr + XDES_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_high(
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_low(
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr)));
|
||||
*/
|
||||
/* If we get here, the page is in some extent of the segment */
|
||||
ut_a(0 == ut_dulint_cmp(
|
||||
if (0 != ut_dulint_cmp(
|
||||
mtr_read_dulint(descr + XDES_ID, MLOG_8BYTES, mtr),
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr)));
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr))) {
|
||||
|
||||
ut_sprintf_buf(errbuf, descr, 40);
|
||||
fprintf(stderr,
|
||||
"InnoDB: Dump of the tablespace extent descriptor: %s\n", errbuf);
|
||||
ut_sprintf_buf(errbuf, seg_inode, 40);
|
||||
fprintf(stderr,
|
||||
"InnoDB: Dump of the segment inode: %s\n", errbuf);
|
||||
|
||||
fprintf(stderr,
|
||||
"InnoDB: Serious error: InnoDB is trying to free space %lu page %lu,\n"
|
||||
"InnoDB: which does not belong to segment %lu %lu but belongs\n"
|
||||
"InnoDB: to segment %lu %lu.\n",
|
||||
space, page,
|
||||
ut_dulint_get_high(
|
||||
mtr_read_dulint(descr + XDES_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_low(
|
||||
mtr_read_dulint(descr + XDES_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_high(
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr)),
|
||||
ut_dulint_get_low(
|
||||
mtr_read_dulint(seg_inode + FSEG_ID, MLOG_8BYTES, mtr)));
|
||||
|
||||
fprintf(stderr,
|
||||
"InnoDB: If the InnoDB recovery crashes here, see section 6.1\n"
|
||||
"InnoDB: of http://www.innodb.com/ibman.html about forcing recovery.\n");
|
||||
ut_a(0);
|
||||
}
|
||||
|
||||
not_full_n_used = mtr_read_ulint(seg_inode + FSEG_NOT_FULL_N_USED,
|
||||
MLOG_4BYTES, mtr);
|
||||
|
@ -386,6 +386,14 @@ fil_space_release_free_extents(
|
||||
/*===========================*/
|
||||
ulint id, /* in: space id */
|
||||
ulint n_reserved); /* in: how many one reserved */
|
||||
/***********************************************************************
|
||||
Gets the number of reserved extents. If the database is silent, this number
|
||||
should be zero. */
|
||||
|
||||
ulint
|
||||
fil_space_get_n_reserved_extents(
|
||||
/*=============================*/
|
||||
ulint id); /* in: space id */
|
||||
|
||||
typedef struct fil_space_struct fil_space_t;
|
||||
|
||||
|
@ -513,6 +513,15 @@ log_print(
|
||||
/*======*/
|
||||
char* buf, /* in/out: buffer where to print */
|
||||
char* buf_end);/* in: buffer end */
|
||||
/**********************************************************
|
||||
Peeks the current lsn. */
|
||||
|
||||
ibool
|
||||
log_peek_lsn(
|
||||
/*=========*/
|
||||
/* out: TRUE if success, FALSE if could not get the
|
||||
log system mutex */
|
||||
dulint* lsn); /* out: if returns TRUE, current lsn is here */
|
||||
/**************************************************************************
|
||||
Refreshes the statistics used to print per-second averages. */
|
||||
|
||||
@ -785,6 +794,11 @@ struct log_struct{
|
||||
called */
|
||||
|
||||
/* Fields involved in checkpoints */
|
||||
ulint log_group_capacity; /* capacity of the log group; if
|
||||
the checkpoint age exceeds this, it is
|
||||
a serious error because it is possible
|
||||
we will then overwrite log and spoil
|
||||
crash recovery */
|
||||
ulint max_modified_age_async;
|
||||
/* when this recommended value for lsn
|
||||
- buf_pool_get_oldest_modification()
|
||||
|
@ -333,6 +333,8 @@ extern ibool recv_recovery_on;
|
||||
extern ibool recv_no_ibuf_operations;
|
||||
extern ibool recv_needed_recovery;
|
||||
|
||||
extern ibool recv_lsn_checks_on;
|
||||
|
||||
extern ibool recv_is_making_a_backup;
|
||||
extern ulint recv_max_parsed_page_no;
|
||||
|
||||
|
@ -33,6 +33,11 @@ log_t* log_sys = NULL;
|
||||
ibool log_do_write = TRUE;
|
||||
ibool log_debug_writes = FALSE;
|
||||
|
||||
/* These control how often we print warnings if the last checkpoint is too
|
||||
old */
|
||||
ibool log_has_printed_chkp_warning = FALSE;
|
||||
time_t log_last_warning_time;
|
||||
|
||||
/* Pointer to this variable is used as the i/o-message when we do i/o to an
|
||||
archive */
|
||||
byte log_archive_io;
|
||||
@ -299,6 +304,7 @@ log_close(void)
|
||||
dulint oldest_lsn;
|
||||
dulint lsn;
|
||||
log_t* log = log_sys;
|
||||
ulint checkpoint_age;
|
||||
|
||||
ut_ad(mutex_own(&(log->mutex)));
|
||||
|
||||
@ -322,8 +328,34 @@ log_close(void)
|
||||
log->check_flush_or_checkpoint = TRUE;
|
||||
}
|
||||
|
||||
if (ut_dulint_minus(lsn, log->last_checkpoint_lsn)
|
||||
<= log->max_modified_age_async) {
|
||||
checkpoint_age = ut_dulint_minus(lsn, log->last_checkpoint_lsn);
|
||||
|
||||
if (checkpoint_age >= log->log_group_capacity) {
|
||||
/* TODO: split btr_store_big_rec_extern_fields() into small
|
||||
steps so that we can release all latches in the middle, and
|
||||
call log_free_check() to ensure we never write over log written
|
||||
after the latest checkpoint. In principle, we should split all
|
||||
big_rec operations, but other operations are smaller. */
|
||||
|
||||
if (!log_has_printed_chkp_warning
|
||||
|| difftime(time(NULL), log_last_warning_time) > 15) {
|
||||
|
||||
log_has_printed_chkp_warning = TRUE;
|
||||
log_last_warning_time = time(NULL);
|
||||
|
||||
ut_print_timestamp(stderr);
|
||||
fprintf(stderr,
|
||||
" InnoDB: ERROR: the age of the last checkpoint is %lu,\n"
|
||||
"InnoDB: which exceeds the log group capacity %lu.\n"
|
||||
"InnoDB: If you are using big BLOB or TEXT rows, you must set the\n"
|
||||
"InnoDB: combined size of log files at least 10 times bigger than the\n"
|
||||
"InnoDB: largest such row.\n",
|
||||
checkpoint_age, log->log_group_capacity);
|
||||
}
|
||||
}
|
||||
|
||||
if (checkpoint_age <= log->max_modified_age_async) {
|
||||
|
||||
goto function_exit;
|
||||
}
|
||||
|
||||
@ -332,8 +364,7 @@ log_close(void)
|
||||
if (ut_dulint_is_zero(oldest_lsn)
|
||||
|| (ut_dulint_minus(lsn, oldest_lsn)
|
||||
> log->max_modified_age_async)
|
||||
|| (ut_dulint_minus(lsn, log->last_checkpoint_lsn)
|
||||
> log->max_checkpoint_age_async)) {
|
||||
|| checkpoint_age > log->max_checkpoint_age_async) {
|
||||
|
||||
log->check_flush_or_checkpoint = TRUE;
|
||||
}
|
||||
@ -469,7 +500,7 @@ log_group_calc_lsn_offset(
|
||||
|
||||
offset = (gr_lsn_size_offset + difference) % group_size;
|
||||
|
||||
ut_a(offset <= 0xFFFFFFFF);
|
||||
ut_a(offset < (((ib_longlong) 1) << 32)); /* offset must be < 4 GB */
|
||||
|
||||
/* printf("Offset is %lu gr_lsn_offset is %lu difference is %lu\n",
|
||||
(ulint)offset,(ulint)gr_lsn_size_offset, (ulint)difference);
|
||||
@ -551,7 +582,6 @@ log_calc_max_ages(void)
|
||||
the database server */
|
||||
{
|
||||
log_group_t* group;
|
||||
ulint n_threads;
|
||||
ulint margin;
|
||||
ulint free;
|
||||
ibool success = TRUE;
|
||||
@ -561,8 +591,6 @@ log_calc_max_ages(void)
|
||||
|
||||
ut_ad(!mutex_own(&(log_sys->mutex)));
|
||||
|
||||
n_threads = srv_get_n_threads();
|
||||
|
||||
mutex_enter(&(log_sys->mutex));
|
||||
|
||||
group = UT_LIST_GET_FIRST(log_sys->log_groups);
|
||||
@ -590,12 +618,15 @@ log_calc_max_ages(void)
|
||||
group = UT_LIST_GET_NEXT(log_groups, group);
|
||||
}
|
||||
|
||||
/* Add extra safety */
|
||||
smallest_capacity = smallest_capacity - smallest_capacity / 10;
|
||||
|
||||
/* For each OS thread we must reserve so much free space in the
|
||||
smallest log group that it can accommodate the log entries produced
|
||||
by single query steps: running out of free log space is a serious
|
||||
system error which requires rebooting the database. */
|
||||
|
||||
free = LOG_CHECKPOINT_FREE_PER_THREAD * n_threads
|
||||
free = LOG_CHECKPOINT_FREE_PER_THREAD * (10 + srv_thread_concurrency)
|
||||
+ LOG_CHECKPOINT_EXTRA_FREE;
|
||||
if (free >= smallest_capacity / 2) {
|
||||
success = FALSE;
|
||||
@ -607,6 +638,10 @@ log_calc_max_ages(void)
|
||||
|
||||
margin = ut_min(margin, log_sys->adm_checkpoint_interval);
|
||||
|
||||
margin = margin - margin / 10; /* Add still some extra safety */
|
||||
|
||||
log_sys->log_group_capacity = smallest_capacity;
|
||||
|
||||
log_sys->max_modified_age_async = margin
|
||||
- margin / LOG_POOL_PREFLUSH_RATIO_ASYNC;
|
||||
log_sys->max_modified_age_sync = margin
|
||||
@ -626,7 +661,7 @@ failure:
|
||||
|
||||
if (!success) {
|
||||
fprintf(stderr,
|
||||
"Error: log file group too small for the number of threads\n");
|
||||
"InnoDB: Error: log file group too small for innodb_thread_concurrency\n");
|
||||
}
|
||||
|
||||
return(success);
|
||||
@ -3111,6 +3146,28 @@ log_check_log_recs(
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
/**********************************************************
|
||||
Peeks the current lsn. */
|
||||
|
||||
ibool
|
||||
log_peek_lsn(
|
||||
/*=========*/
|
||||
/* out: TRUE if success, FALSE if could not get the
|
||||
log system mutex */
|
||||
dulint* lsn) /* out: if returns TRUE, current lsn is here */
|
||||
{
|
||||
if (0 == mutex_enter_nowait(&(log_sys->mutex), (char*)__FILE__,
|
||||
__LINE__)) {
|
||||
*lsn = log_sys->lsn;
|
||||
|
||||
mutex_exit(&(log_sys->mutex));
|
||||
|
||||
return(TRUE);
|
||||
}
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
/**********************************************************
|
||||
Prints info of the log. */
|
||||
|
||||
|
@ -46,6 +46,8 @@ ibool recv_recovery_from_backup_on = FALSE;
|
||||
|
||||
ibool recv_needed_recovery = FALSE;
|
||||
|
||||
ibool recv_lsn_checks_on = FALSE;
|
||||
|
||||
/* If the following is TRUE, the buffer pool file pages must be invalidated
|
||||
after recovery and no ibuf operations are allowed; this becomes TRUE if
|
||||
the log record hash table becomes too full, and log records must be merged
|
||||
@ -71,6 +73,12 @@ ulint recv_previous_parsed_rec_is_multi = 0;
|
||||
|
||||
ulint recv_max_parsed_page_no = 0;
|
||||
|
||||
/* The maximum lsn we see for a page during the recovery process. If this
|
||||
is bigger than the lsn we are able to scan up to, that is an indication that
|
||||
the recovery failed and the database may be corrupt. */
|
||||
|
||||
dulint recv_max_page_lsn;
|
||||
|
||||
/************************************************************
|
||||
Creates the recovery system. */
|
||||
|
||||
@ -132,6 +140,8 @@ recv_sys_init(
|
||||
OS_FILE_LOG_BLOCK_SIZE);
|
||||
recv_sys->found_corrupt_log = FALSE;
|
||||
|
||||
recv_max_page_lsn = ut_dulint_zero;
|
||||
|
||||
mutex_exit(&(recv_sys->mutex));
|
||||
}
|
||||
|
||||
@ -1124,6 +1134,10 @@ recv_recover_page(
|
||||
|
||||
mutex_enter(&(recv_sys->mutex));
|
||||
|
||||
if (ut_dulint_cmp(recv_max_page_lsn, page_lsn) < 0) {
|
||||
recv_max_page_lsn = page_lsn;
|
||||
}
|
||||
|
||||
recv_addr->state = RECV_PROCESSED;
|
||||
|
||||
ut_a(recv_sys->n_addrs);
|
||||
@ -2192,9 +2206,12 @@ recv_scan_log_recs(
|
||||
while (log_block < buf + len && !finished) {
|
||||
|
||||
no = log_block_get_hdr_no(log_block);
|
||||
/*
|
||||
fprintf(stderr, "Log block header no %lu\n", no);
|
||||
|
||||
/* fprintf(stderr, "Log block header no %lu\n", no); */
|
||||
|
||||
fprintf(stderr, "Scanned lsn no %lu\n",
|
||||
log_block_convert_lsn_to_no(scanned_lsn));
|
||||
*/
|
||||
if (no != log_block_convert_lsn_to_no(scanned_lsn)
|
||||
|| !log_block_checksum_is_ok_or_old_format(log_block)) {
|
||||
|
||||
@ -2586,7 +2603,6 @@ recv_recovery_from_checkpoint_start(
|
||||
|
||||
recv_group_scan_log_recs(group, &contiguous_lsn,
|
||||
&group_scanned_lsn);
|
||||
|
||||
group->scanned_lsn = group_scanned_lsn;
|
||||
|
||||
if (ut_dulint_cmp(old_scanned_lsn, group_scanned_lsn) < 0) {
|
||||
@ -2603,6 +2619,31 @@ recv_recovery_from_checkpoint_start(
|
||||
group = UT_LIST_GET_NEXT(log_groups, group);
|
||||
}
|
||||
|
||||
/* We currently have only one log group */
|
||||
if (ut_dulint_cmp(group_scanned_lsn, checkpoint_lsn) < 0) {
|
||||
ut_print_timestamp(stderr);
|
||||
fprintf(stderr,
|
||||
" InnoDB: ERROR: We were only able to scan the log up to\n"
|
||||
"InnoDB: %lu %lu, but a checkpoint was at %lu %lu.\n"
|
||||
"InnoDB: It is possible that the database is now corrupt!\n",
|
||||
ut_dulint_get_high(group_scanned_lsn),
|
||||
ut_dulint_get_low(group_scanned_lsn),
|
||||
ut_dulint_get_high(checkpoint_lsn),
|
||||
ut_dulint_get_low(checkpoint_lsn));
|
||||
}
|
||||
|
||||
if (ut_dulint_cmp(group_scanned_lsn, recv_max_page_lsn) < 0) {
|
||||
ut_print_timestamp(stderr);
|
||||
fprintf(stderr,
|
||||
" InnoDB: ERROR: We were only able to scan the log up to %lu %lu\n"
|
||||
"InnoDB: but a database page a had an lsn %lu %lu. It is possible that the\n"
|
||||
"InnoDB: database is now corrupt!\n",
|
||||
ut_dulint_get_high(group_scanned_lsn),
|
||||
ut_dulint_get_low(group_scanned_lsn),
|
||||
ut_dulint_get_high(recv_max_page_lsn),
|
||||
ut_dulint_get_low(recv_max_page_lsn));
|
||||
}
|
||||
|
||||
if (ut_dulint_cmp(recv_sys->recovered_lsn, checkpoint_lsn) < 0) {
|
||||
|
||||
mutex_exit(&(log_sys->mutex));
|
||||
@ -2656,6 +2697,8 @@ recv_recovery_from_checkpoint_start(
|
||||
|
||||
sync_order_checks_on = FALSE;
|
||||
|
||||
recv_lsn_checks_on = TRUE;
|
||||
|
||||
/* The database is now ready to start almost normal processing of user
|
||||
transactions: transaction rollbacks and the application of the log
|
||||
records in the hash table can be run in background. */
|
||||
|
@ -1030,6 +1030,7 @@ os_file_flush(
|
||||
#ifdef HAVE_FDATASYNC
|
||||
ret = fdatasync(file);
|
||||
#else
|
||||
/* printf("Flushing to file %lu\n", (ulint)file); */
|
||||
ret = fsync(file);
|
||||
#endif
|
||||
os_n_fsyncs++;
|
||||
|
@ -1798,8 +1798,12 @@ retry:
|
||||
|
||||
os_fast_mutex_unlock(&srv_conc_mutex);
|
||||
|
||||
trx->op_info = (char*)"sleeping before joining InnoDB queue";
|
||||
|
||||
os_thread_sleep(50000);
|
||||
|
||||
trx->op_info = (char*)"";
|
||||
|
||||
os_fast_mutex_lock(&srv_conc_mutex);
|
||||
|
||||
srv_conc_n_waiting_threads--;
|
||||
@ -2299,6 +2303,7 @@ srv_sprintf_innodb_monitor(
|
||||
char* buf_end = buf + len - 2000;
|
||||
double time_elapsed;
|
||||
time_t current_time;
|
||||
ulint n_reserved;
|
||||
|
||||
mutex_enter(&srv_innodb_monitor_mutex);
|
||||
|
||||
@ -2414,8 +2419,16 @@ srv_sprintf_innodb_monitor(
|
||||
"ROW OPERATIONS\n"
|
||||
"--------------\n");
|
||||
buf += sprintf(buf,
|
||||
"%ld queries inside InnoDB, %ld queries in queue\n",
|
||||
"%ld queries inside InnoDB, %lu queries in queue\n",
|
||||
srv_conc_n_threads, srv_conc_n_waiting_threads);
|
||||
|
||||
n_reserved = fil_space_get_n_reserved_extents(0);
|
||||
if (n_reserved > 0) {
|
||||
buf += sprintf(buf,
|
||||
"%lu tablespace extents now reserved for B-tree split operations\n",
|
||||
n_reserved);
|
||||
}
|
||||
|
||||
#ifdef UNIV_LINUX
|
||||
buf += sprintf(buf,
|
||||
"Main thread process no. %lu, id %lu, state: %s\n",
|
||||
|
@ -1624,6 +1624,13 @@ trx_print(
|
||||
}
|
||||
|
||||
buf += sprintf(buf, "\n");
|
||||
|
||||
if (trx->n_mysql_tables_in_use > 0 || trx->mysql_n_tables_locked > 0) {
|
||||
|
||||
buf += sprintf(buf, "mysql tables in use %lu, locked %lu\n",
|
||||
trx->n_mysql_tables_in_use,
|
||||
trx->mysql_n_tables_locked);
|
||||
}
|
||||
|
||||
start_of_line = buf;
|
||||
|
||||
|
@ -119,7 +119,7 @@ int _nisam_search(register N_INFO *info, register N_KEYDEF *keyinfo, uchar *key,
|
||||
{
|
||||
keypos=_nisam_get_last_key(info,keyinfo,buff,lastkey,keypos);
|
||||
if ((nextflag & SEARCH_LAST) &&
|
||||
_nisam_key_cmp(keyinfo->seg, info->lastkey, key, key_len, SEARCH_FIND))
|
||||
_nisam_key_cmp(keyinfo->seg, lastkey, key, key_len, SEARCH_FIND))
|
||||
{
|
||||
my_errno=HA_ERR_KEY_NOT_FOUND; /* Didn't find key */
|
||||
goto err;
|
||||
|
@ -26,24 +26,24 @@ const char *client_errors[]=
|
||||
{
|
||||
"Unbekannter MySQL Fehler",
|
||||
"Kann UNIX-Socket nicht anlegen (%d)",
|
||||
"Keine Verbindung zu lokalem MySQL Server, socket: '%-.64s' (%d)",
|
||||
"Keine Verbindung zu MySQL Server auf %-.64s (%d)",
|
||||
"Keine Verbindung zu lokalem MySQL Server, socket: '%-.100s' (%d)",
|
||||
"Keine Verbindung zu MySQL Server auf %-.100s (%d)",
|
||||
"Kann TCP/IP-Socket nicht anlegen (%d)",
|
||||
"Unbekannter MySQL Server Host (%-.64s) (%d)",
|
||||
"Unbekannter MySQL Server Host (%-.100s) (%d)",
|
||||
"MySQL Server nicht vorhanden",
|
||||
"Protokolle ungleich. Server Version = % d Client Version = %d",
|
||||
"MySQL client got out of memory",
|
||||
"Wrong host info",
|
||||
"Localhost via UNIX socket",
|
||||
"%-.64s via TCP/IP",
|
||||
"%-.100s via TCP/IP",
|
||||
"Error in server handshake",
|
||||
"Lost connection to MySQL server during query",
|
||||
"Commands out of sync; You can't run this command now",
|
||||
"Verbindung ueber Named Pipe; Host: %-.64s",
|
||||
"Verbindung ueber Named Pipe; Host: %-.100s",
|
||||
"Kann nicht auf Named Pipe warten. Host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Kann Named Pipe nicht oeffnen. Host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Kann den Status der Named Pipe nicht setzen. Host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Can't initialize character set %-.64s (path: %-.64s)",
|
||||
"Can't initialize character set %-.32s (path: %-.100s)",
|
||||
"Got packet bigger than 'max_allowed_packet'",
|
||||
"Embedded server",
|
||||
"Error on SHOW SLAVE STATUS:",
|
||||
@ -61,24 +61,24 @@ const char *client_errors[]=
|
||||
{
|
||||
"Erro desconhecido do MySQL",
|
||||
"Não pode criar 'UNIX socket' (%d)",
|
||||
"Não pode se conectar ao servidor MySQL local através do 'socket' '%-.64s' (%d)",
|
||||
"Não pode se conectar ao servidor MySQL em '%-.64s' (%d)",
|
||||
"Não pode se conectar ao servidor MySQL local através do 'socket' '%-.100s' (%d)",
|
||||
"Não pode se conectar ao servidor MySQL em '%-.100s' (%d)",
|
||||
"Não pode criar 'socket TCP/IP' (%d)",
|
||||
"'Host' servidor MySQL '%-.64s' (%d) desconhecido",
|
||||
"'Host' servidor MySQL '%-.100s' (%d) desconhecido",
|
||||
"Servidor MySQL desapareceu",
|
||||
"Incompatibilidade de protocolos. Versão do Servidor: %d - Versão do Cliente: %d",
|
||||
"Cliente do MySQL com falta de memória",
|
||||
"Informação inválida de 'host'",
|
||||
"Localhost via 'UNIX socket'",
|
||||
"%-.64s via 'TCP/IP'",
|
||||
"%-.100s via 'TCP/IP'",
|
||||
"Erro na negociação de acesso ao servidor",
|
||||
"Conexão perdida com servidor MySQL durante 'query'",
|
||||
"Comandos fora de sincronismo. Você não pode executar este comando agora",
|
||||
"%-.64s via 'named pipe'",
|
||||
"%-.100s via 'named pipe'",
|
||||
"Não pode esperar pelo 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
|
||||
"Não pode abrir 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
|
||||
"Não pode estabelecer o estado do 'named pipe' para o 'host' %-.64s - 'pipe' %-.32s (%lu)",
|
||||
"Não pode inicializar conjunto de caracteres %-.64s (caminho %-.64s)",
|
||||
"Não pode inicializar conjunto de caracteres %-.32s (caminho %-.100s)",
|
||||
"Obteve pacote maior do que 'max_allowed_packet'",
|
||||
"Embedded server"
|
||||
"Error on SHOW SLAVE STATUS:",
|
||||
@ -94,24 +94,24 @@ const char *client_errors[]=
|
||||
{
|
||||
"Unknown MySQL error",
|
||||
"Can't create UNIX socket (%d)",
|
||||
"Can't connect to local MySQL server through socket '%-.64s' (%d)",
|
||||
"Can't connect to MySQL server on '%-.64s' (%d)",
|
||||
"Can't connect to local MySQL server through socket '%-.100s' (%d)",
|
||||
"Can't connect to MySQL server on '%-.100s' (%d)",
|
||||
"Can't create TCP/IP socket (%d)",
|
||||
"Unknown MySQL Server Host '%-.64s' (%d)",
|
||||
"Unknown MySQL Server Host '%-.100s' (%d)",
|
||||
"MySQL server has gone away",
|
||||
"Protocol mismatch. Server Version = %d Client Version = %d",
|
||||
"MySQL client run out of memory",
|
||||
"Wrong host info",
|
||||
"Localhost via UNIX socket",
|
||||
"%-.64s via TCP/IP",
|
||||
"%-.100s via TCP/IP",
|
||||
"Error in server handshake",
|
||||
"Lost connection to MySQL server during query",
|
||||
"Commands out of sync; You can't run this command now",
|
||||
"%-.64s via named pipe",
|
||||
"%-.100s via named pipe",
|
||||
"Can't wait for named pipe to host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Can't open named pipe to host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Can't set state of named pipe to host: %-.64s pipe: %-.32s (%lu)",
|
||||
"Can't initialize character set %-.64s (path: %-.64s)",
|
||||
"Can't initialize character set %-.32s (path: %-.100s)",
|
||||
"Got packet bigger than 'max_allowed_packet'",
|
||||
"Embedded server",
|
||||
"Error on SHOW SLAVE STATUS:",
|
||||
|
@ -110,9 +110,16 @@ void STDCALL mysql_server_end()
|
||||
{
|
||||
/* If library called my_init(), free memory allocated by it */
|
||||
if (!org_my_init_done)
|
||||
{
|
||||
my_end(0);
|
||||
#ifndef THREAD
|
||||
/* Remove TRACING, if enabled by mysql_debug() */
|
||||
DBUG_POP();
|
||||
#endif
|
||||
}
|
||||
else
|
||||
mysql_thread_end();
|
||||
mysql_client_init= org_my_init_done= 0;
|
||||
}
|
||||
|
||||
my_bool STDCALL mysql_thread_init()
|
||||
|
@ -299,7 +299,7 @@ FT_INFO * ft_init_boolean_search(MI_INFO *info, uint keynr, byte *query,
|
||||
default_charset_info :
|
||||
info->s->keyinfo[keynr].seg->charset);
|
||||
ftb->with_scan=0;
|
||||
ftb->lastpos=0;
|
||||
ftb->lastpos=HA_POS_ERROR;
|
||||
bzero(& ftb->no_dupes, sizeof(TREE));
|
||||
|
||||
init_alloc_root(&ftb->mem_root, 1024, 1024);
|
||||
@ -543,7 +543,7 @@ float ft_boolean_find_relevance(FT_INFO *ftb, byte *record, uint length)
|
||||
if (!ftb->queue.elements)
|
||||
return 0;
|
||||
|
||||
if (ftb->state != INDEX_SEARCH && docid < ftb->lastpos)
|
||||
if (ftb->state != INDEX_SEARCH && docid <= ftb->lastpos)
|
||||
{
|
||||
FTB_EXPR *x;
|
||||
uint i;
|
||||
|
@ -130,7 +130,11 @@ int main(int argc,char *argv[])
|
||||
#error
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SNPRINTF
|
||||
snprintf(buf,MAX_LEN,"%.*s",(int) keylen,info->lastkey+1);
|
||||
#else
|
||||
sprintf(buf,"%.*s",(int) keylen,info->lastkey+1);
|
||||
#endif
|
||||
casedn_str(buf);
|
||||
total++;
|
||||
lengths[keylen]++;
|
||||
|
@ -67,12 +67,9 @@ static int FT_SUPERDOC_cmp(void* cmp_arg __attribute__((unused)),
|
||||
static int walk_and_match(FT_WORD *word, uint32 count, ALL_IN_ONE *aio)
|
||||
{
|
||||
uint keylen, r, doc_cnt;
|
||||
#ifdef EVAL_RUN
|
||||
uint cnt;
|
||||
double sum, sum2, suml;
|
||||
#endif /* EVAL_RUN */
|
||||
FT_SUPERDOC sdoc, *sptr;
|
||||
TREE_ELEMENT *selem;
|
||||
double gweight=1;
|
||||
#if HA_FT_WTYPE == HA_KEYTYPE_FLOAT
|
||||
float tmp_weight;
|
||||
#else
|
||||
@ -84,42 +81,27 @@ static int walk_and_match(FT_WORD *word, uint32 count, ALL_IN_ONE *aio)
|
||||
word->weight=LWS_FOR_QUERY;
|
||||
|
||||
keylen=_ft_make_key(aio->info,aio->keynr,(char*) aio->keybuff,word,0);
|
||||
#ifdef EVAL_RUN
|
||||
keylen-=1+HA_FT_WLEN;
|
||||
#else /* EVAL_RUN */
|
||||
keylen-=HA_FT_WLEN;
|
||||
#endif /* EVAL_RUN */
|
||||
|
||||
#ifdef EVAL_RUN
|
||||
sum=sum2=suml=
|
||||
#endif /* EVAL_RUN */
|
||||
doc_cnt=0;
|
||||
|
||||
r=_mi_search(aio->info, aio->keyinfo, aio->keybuff, keylen,
|
||||
SEARCH_FIND | SEARCH_PREFIX, aio->key_root);
|
||||
aio->info->update|= HA_STATE_AKTIV; /* for _mi_test_if_changed() */
|
||||
|
||||
while (!r)
|
||||
while (!r && gweight)
|
||||
{
|
||||
if (_mi_compare_text(aio->charset,
|
||||
aio->info->lastkey,keylen,
|
||||
aio->keybuff,keylen,0)) break;
|
||||
|
||||
#if HA_FT_WTYPE == HA_KEYTYPE_FLOAT
|
||||
#ifdef EVAL_RUN
|
||||
mi_float4get(tmp_weight,aio->info->lastkey+keylen+1);
|
||||
#else /* EVAL_RUN */
|
||||
mi_float4get(tmp_weight,aio->info->lastkey+keylen);
|
||||
#endif /* EVAL_RUN */
|
||||
#else
|
||||
#error
|
||||
#endif
|
||||
if(tmp_weight==0) DBUG_RETURN(doc_cnt); /* stopword, doc_cnt should be 0 */
|
||||
|
||||
#ifdef EVAL_RUN
|
||||
cnt=*(byte *)(aio->info->lastkey+keylen);
|
||||
#endif /* EVAL_RUN */
|
||||
|
||||
sdoc.doc.dpos=aio->info->lastpos;
|
||||
|
||||
/* saving document matched into dtree */
|
||||
@ -137,11 +119,10 @@ static int walk_and_match(FT_WORD *word, uint32 count, ALL_IN_ONE *aio)
|
||||
sptr->tmp_weight=tmp_weight;
|
||||
|
||||
doc_cnt++;
|
||||
#ifdef EVAL_RUN
|
||||
sum +=cnt;
|
||||
sum2+=cnt*cnt;
|
||||
suml+=cnt*log(cnt);
|
||||
#endif /* EVAL_RUN */
|
||||
|
||||
gweight=word->weight*GWS_IN_USE;
|
||||
if (gweight < 0 || doc_cnt > 2000000)
|
||||
gweight=0;
|
||||
|
||||
if (_mi_test_if_changed(aio->info) == 0)
|
||||
r=_mi_search_next(aio->info, aio->keyinfo, aio->info->lastkey,
|
||||
@ -152,13 +133,9 @@ static int walk_and_match(FT_WORD *word, uint32 count, ALL_IN_ONE *aio)
|
||||
aio->info->lastkey_length, SEARCH_BIGGER,
|
||||
aio->key_root);
|
||||
}
|
||||
if (doc_cnt)
|
||||
{
|
||||
word->weight*=GWS_IN_USE;
|
||||
if (word->weight < 0)
|
||||
word->weight=0;
|
||||
|
||||
}
|
||||
word->weight=gweight;
|
||||
|
||||
DBUG_RETURN(0);
|
||||
}
|
||||
|
||||
|
@ -3562,10 +3562,13 @@ int update_state_info(MI_CHECK *param, MI_INFO *info,uint update)
|
||||
uint i, key_parts= mi_uint2korr(share->state.header.key_parts);
|
||||
share->state.rec_per_key_rows=info->state->records;
|
||||
share->state.changed&= ~STATE_NOT_ANALYZED;
|
||||
for (i=0; i<key_parts; i++)
|
||||
if (info->state->records)
|
||||
{
|
||||
if (!(share->state.rec_per_key_part[i]=param->rec_per_key_part[i]))
|
||||
share->state.changed|= STATE_NOT_ANALYZED;
|
||||
for (i=0; i<key_parts; i++)
|
||||
{
|
||||
if (!(share->state.rec_per_key_part[i]=param->rec_per_key_part[i]))
|
||||
share->state.changed|= STATE_NOT_ANALYZED;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (update & (UPDATE_STAT | UPDATE_SORT | UPDATE_TIME | UPDATE_AUTO_INC))
|
||||
|
@ -286,7 +286,7 @@ int mi_create(const char *name,uint keys,MI_KEYDEF *keydefs,
|
||||
keydef->seg[0].type == (int) HA_KEYTYPE_NUM)
|
||||
keydef->seg[0].flag&= ~HA_SPACE_PACK;
|
||||
|
||||
/* Only use HA_PACK_KEY if the first segment is a variable length key */
|
||||
/* Only use HA_PACK_KEY when first segment is a variable length key */
|
||||
if (!(keydef->seg[0].flag & (HA_SPACE_PACK | HA_BLOB_PART |
|
||||
HA_VAR_LENGTH)))
|
||||
{
|
||||
|
@ -165,7 +165,9 @@ my_bool _mi_read_pack_info(MI_INFO *info, pbool fix_keys)
|
||||
diff_length=(int) rec_reflength - (int) share->base.rec_reflength;
|
||||
if (fix_keys)
|
||||
share->rec_reflength=rec_reflength;
|
||||
share->base.min_block_length=share->min_pack_length+share->pack.ref_length;
|
||||
share->base.min_block_length=share->min_pack_length+1;
|
||||
if (share->min_pack_length > 254)
|
||||
share->base.min_block_length+=2;
|
||||
|
||||
if (!(share->decode_trees=(MI_DECODE_TREE*)
|
||||
my_malloc((uint) (trees*sizeof(MI_DECODE_TREE)+
|
||||
|
@ -1218,9 +1218,10 @@ uint _mi_get_binary_pack_key(register MI_KEYDEF *keyinfo, uint nod_flag,
|
||||
register uchar **page_pos, register uchar *key)
|
||||
{
|
||||
reg1 MI_KEYSEG *keyseg;
|
||||
uchar *start_key,*page=*page_pos,*page_end,*from,*from_end;
|
||||
uchar *start_key,*page,*page_end,*from,*from_end;
|
||||
uint length,tmp;
|
||||
|
||||
page= *page_pos;
|
||||
page_end=page+MI_MAX_KEY_BUFF+1;
|
||||
start_key=key;
|
||||
|
||||
@ -1276,7 +1277,9 @@ uint _mi_get_binary_pack_key(register MI_KEYDEF *keyinfo, uint nod_flag,
|
||||
length-=tmp;
|
||||
from=page; from_end=page_end;
|
||||
}
|
||||
memcpy((byte*) key,(byte*) from,(size_t) length);
|
||||
DBUG_PRINT("info",("key: %lx from: %lx length: %u",
|
||||
key, from, length));
|
||||
memcpy_overlap((byte*) key, (byte*) from, (size_t) length);
|
||||
key+=length;
|
||||
from+=length;
|
||||
}
|
||||
@ -1998,6 +2001,9 @@ _mi_calc_bin_pack_key_length(MI_KEYDEF *keyinfo,uint nod_flag,uchar *next_key,
|
||||
uint length,key_length,ref_length;
|
||||
|
||||
s_temp->totlength=key_length=_mi_keylength(keyinfo,key)+nod_flag;
|
||||
#ifdef HAVE_purify
|
||||
s_temp->n_length= s_temp->n_ref_length=0; /* For valgrind */
|
||||
#endif
|
||||
s_temp->key=key;
|
||||
s_temp->prev_key=org_key;
|
||||
if (prev_key) /* If not first key in block */
|
||||
|
@ -887,4 +887,3 @@ void mi_end_bulk_insert(MI_INFO *info)
|
||||
info->bulk_insert=0;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -357,11 +357,15 @@ static void usage(void)
|
||||
-e, --extend-check Check the table VERY throughly. Only use this in\n\
|
||||
extreme cases as myisamchk should normally be able to\n\
|
||||
find out if the table is ok even without this switch\n\
|
||||
-F, --fast Check only tables that haven't been closed properly\n\
|
||||
-C, --check-only-changed\n\
|
||||
Check only tables that have changed since last check\n\
|
||||
-F, --fast Check only tables that haven't been closed properly.\n\
|
||||
It also applies to other requested actions (e.g. --analyze\n\
|
||||
will be ignored if the table is already analyzed).\n\
|
||||
-f, --force Restart with '-r' if there are any errors in the table.\n\
|
||||
States will be updated as with '--update-state'\n\
|
||||
-C, --check-only-changed\n\
|
||||
Check only tables that have changed since last check.\n\
|
||||
It also applies to other requested actions (e.g. --analyze\n\
|
||||
will be ignored if the table is already analyzed).\n\
|
||||
-i, --information Print statistics information about table that is checked\n\
|
||||
-m, --medium-check Faster than extend-check, but only finds 99.99% of\n\
|
||||
all errors. Should be good enough for most cases\n\
|
||||
@ -1396,23 +1400,24 @@ static int mi_sort_records(MI_CHECK *param,
|
||||
|
||||
if (!(((ulonglong) 1 << sort_key) & share->state.key_map))
|
||||
{
|
||||
mi_check_print_error(param,"Can't sort table '%s' on key %d; No such key",
|
||||
mi_check_print_warning(param,
|
||||
"Can't sort table '%s' on key %d; No such key",
|
||||
name,sort_key+1);
|
||||
param->error_printed=0;
|
||||
DBUG_RETURN(-1);
|
||||
DBUG_RETURN(0); /* Nothing to do */
|
||||
}
|
||||
if (keyinfo->flag & HA_FULLTEXT)
|
||||
{
|
||||
mi_check_print_error(param,"Can't sort table '%s' on FULLTEXT key %d",
|
||||
name,sort_key+1);
|
||||
mi_check_print_warning(param,"Can't sort table '%s' on FULLTEXT key %d",
|
||||
name,sort_key+1);
|
||||
param->error_printed=0;
|
||||
DBUG_RETURN(-1);
|
||||
DBUG_RETURN(0); /* Nothing to do */
|
||||
}
|
||||
if (share->data_file_type == COMPRESSED_RECORD)
|
||||
{
|
||||
mi_check_print_error(param,"Can't sort read-only table '%s'", name);
|
||||
mi_check_print_warning(param,"Can't sort read-only table '%s'", name);
|
||||
param->error_printed=0;
|
||||
DBUG_RETURN(-1);
|
||||
DBUG_RETURN(0); /* Nothing to do */
|
||||
}
|
||||
if (!(param->testflag & T_SILENT))
|
||||
{
|
||||
|
@ -29,3 +29,5 @@ extern pthread_mutex_t THR_LOCK_open;
|
||||
#endif
|
||||
|
||||
int _myrg_init_queue(MYRG_INFO *info,int inx,enum ha_rkey_function search_flag);
|
||||
int _myrg_mi_read_record(MI_INFO *info, byte *buf);
|
||||
|
||||
|
@ -14,8 +14,6 @@
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
|
||||
|
||||
/* Read record based on a key */
|
||||
|
||||
#include "myrg_def.h"
|
||||
|
||||
static int queue_key_cmp(void *keyseg, byte *a, byte *b)
|
||||
@ -55,3 +53,13 @@ int _myrg_init_queue(MYRG_INFO *info,int inx,enum ha_rkey_function search_flag)
|
||||
}
|
||||
return error;
|
||||
}
|
||||
|
||||
int _myrg_mi_read_record(MI_INFO *info, byte *buf)
|
||||
{
|
||||
if (!(*info->read_record)(info,info->lastpos,buf))
|
||||
{
|
||||
info->update|= HA_STATE_AKTIV; /* Record is read */
|
||||
return 0;
|
||||
}
|
||||
return my_errno;
|
||||
}
|
||||
|
@ -45,5 +45,5 @@ int myrg_rfirst(MYRG_INFO *info, byte *buf, int inx)
|
||||
return HA_ERR_END_OF_FILE;
|
||||
|
||||
mi=(info->current_table=(MYRG_TABLE *)queue_top(&(info->by_key)))->table;
|
||||
return mi_rrnd(mi,buf,mi->lastpos);
|
||||
return _myrg_mi_read_record(mi,buf);
|
||||
}
|
||||
|
@ -36,7 +36,7 @@
|
||||
SerG
|
||||
*/
|
||||
|
||||
int myrg_rkey(MYRG_INFO *info,byte *record,int inx, const byte *key,
|
||||
int myrg_rkey(MYRG_INFO *info,byte *buf,int inx, const byte *key,
|
||||
uint key_len, enum ha_rkey_function search_flag)
|
||||
{
|
||||
byte *key_buff;
|
||||
@ -83,5 +83,5 @@ int myrg_rkey(MYRG_INFO *info,byte *record,int inx, const byte *key,
|
||||
return HA_ERR_KEY_NOT_FOUND;
|
||||
|
||||
mi=(info->current_table=(MYRG_TABLE *)queue_top(&(info->by_key)))->table;
|
||||
return mi_rrnd(mi,record,mi->lastpos);
|
||||
return _myrg_mi_read_record(mi,buf);
|
||||
}
|
||||
|
@ -45,6 +45,6 @@ int myrg_rlast(MYRG_INFO *info, byte *buf, int inx)
|
||||
return HA_ERR_END_OF_FILE;
|
||||
|
||||
mi=(info->current_table=(MYRG_TABLE *)queue_top(&(info->by_key)))->table;
|
||||
return mi_rrnd(mi,buf,mi->lastpos);
|
||||
return _myrg_mi_read_record(mi,buf);
|
||||
}
|
||||
|
||||
|
@ -49,5 +49,5 @@ int myrg_rnext(MYRG_INFO *info, byte *buf, int inx)
|
||||
|
||||
/* now, mymerge's read_next is as simple as one queue_top */
|
||||
mi=(info->current_table=(MYRG_TABLE *)queue_top(&(info->by_key)))->table;
|
||||
return mi_rrnd(mi,buf,mi->lastpos);
|
||||
return _myrg_mi_read_record(mi,buf);
|
||||
}
|
||||
|
@ -49,5 +49,5 @@ int myrg_rprev(MYRG_INFO *info, byte *buf, int inx)
|
||||
|
||||
/* now, mymerge's read_prev is as simple as one queue_top */
|
||||
mi=(info->current_table=(MYRG_TABLE *)queue_top(&(info->by_key)))->table;
|
||||
return mi_rrnd(mi,buf,mi->lastpos);
|
||||
return _myrg_mi_read_record(mi,buf);
|
||||
}
|
||||
|
9
mysql-test/include/check_var_limit.inc
Normal file
9
mysql-test/include/check_var_limit.inc
Normal file
@ -0,0 +1,9 @@
|
||||
#
|
||||
# Check that second part of $LIMIT is between $MIN_LIMIT and $MAX_LIMIT
|
||||
# This is useful to check that a variable from SHOW_VARIABLES is within
|
||||
# certain limits. Check query_cache_merge.test for an example of using this.
|
||||
#
|
||||
-- require r/check_var_limit.require
|
||||
disable_query_log;
|
||||
eval select SUBSTRING_INDEX($LIMIT, "\t", 2) BETWEEN $MIN_LIMIT AND $MAX_LIMIT as "limit";
|
||||
enable_query_log;
|
@ -16,6 +16,9 @@ USE_MANAGER=0
|
||||
MY_TZ=GMT-3
|
||||
TZ=$MY_TZ; export TZ # for UNIX_TIMESTAMP tests to work
|
||||
|
||||
# For query_cache test
|
||||
ulimit -n 1024
|
||||
|
||||
#++
|
||||
# Program Definitions
|
||||
#--
|
||||
@ -253,12 +256,6 @@ while test $# -gt 0; do
|
||||
--start-and-exit)
|
||||
START_AND_EXIT=1
|
||||
;;
|
||||
--skip-innodb)
|
||||
EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT --skip-innodb"
|
||||
EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT --skip-innodb" ;;
|
||||
--skip-bdb)
|
||||
EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT --skip-bdb"
|
||||
EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT --skip-bdb" ;;
|
||||
--skip-rpl) NO_SLAVE=1 ;;
|
||||
--skip-test=*) SKIP_TEST=`$ECHO "$1" | $SED -e "s;--skip-test=;;"`;;
|
||||
--do-test=*) DO_TEST=`$ECHO "$1" | $SED -e "s;--do-test=;;"`;;
|
||||
@ -835,7 +832,6 @@ start_master()
|
||||
/bin/sh $master_init_script
|
||||
fi
|
||||
cd $BASEDIR # for gcov
|
||||
#start master
|
||||
if [ -z "$DO_BENCH" ]
|
||||
then
|
||||
master_args="--no-defaults --log-bin=$MYSQL_TEST_DIR/var/log/master-bin \
|
||||
@ -854,6 +850,7 @@ start_master()
|
||||
--tmpdir=$MYSQL_TMP_DIR \
|
||||
--language=$LANGUAGE \
|
||||
--innodb_data_file_path=ibdata1:50M \
|
||||
--open-files-limit=1024 \
|
||||
$MASTER_40_ARGS \
|
||||
$SMALL_SERVER \
|
||||
$EXTRA_MASTER_OPT $EXTRA_MASTER_MYSQLD_OPT"
|
||||
@ -1369,6 +1366,9 @@ fi
|
||||
|
||||
$ECHO "Starting Tests"
|
||||
|
||||
#
|
||||
# This can probably be deleted
|
||||
#
|
||||
if [ "$DO_BENCH" = 1 ]
|
||||
then
|
||||
BENCHDIR=$BASEDIR/sql-bench/
|
||||
|
2
mysql-test/r/check_var_limit.require
Normal file
2
mysql-test/r/check_var_limit.require
Normal file
@ -0,0 +1,2 @@
|
||||
limit
|
||||
1
|
@ -256,3 +256,14 @@ select ref_mag from t1 where match ref_mag against ('+test' in boolean mode);
|
||||
ref_mag
|
||||
test
|
||||
drop table t1;
|
||||
create table t1 (t1_id int(11) primary key, name varchar(32));
|
||||
insert into t1 values (1, 'data1');
|
||||
insert into t1 values (2, 'data2');
|
||||
create table t2 (t2_id int(11) primary key, t1_id int(11), name varchar(32));
|
||||
insert into t2 values (1, 1, 'xxfoo');
|
||||
insert into t2 values (2, 1, 'xxbar');
|
||||
insert into t2 values (3, 1, 'xxbuz');
|
||||
select * from t1 join t2 using(`t1_id`) where match (t1.name, t2.name) against('xxfoo' in boolean mode);
|
||||
t1_id name t2_id t1_id name
|
||||
1 data1 1 1 xxfoo
|
||||
drop table t1,t2;
|
||||
|
@ -46,6 +46,11 @@ select 3 ^ 11, 1 ^ 1, 1 ^ 0, 1 ^ NULL, NULL ^ 1;
|
||||
select 1 XOR 1, 1 XOR 0, 0 XOR 1, 0 XOR 0, NULL XOR 1, 1 XOR NULL, 0 XOR NULL;
|
||||
1 XOR 1 1 XOR 0 0 XOR 1 0 XOR 0 NULL XOR 1 1 XOR NULL 0 XOR NULL
|
||||
0 1 1 0 NULL NULL NULL
|
||||
create table t1 (a int);
|
||||
insert t1 values (1);
|
||||
select * from t1 where 1 xor 1;
|
||||
a
|
||||
drop table t1;
|
||||
select 5 between 0 and 10 between 0 and 1,(5 between 0 and 10) between 0 and 1;
|
||||
5 between 0 and 10 between 0 and 1 (5 between 0 and 10) between 0 and 1
|
||||
0 1
|
||||
|
@ -128,3 +128,6 @@ flush privileges;
|
||||
drop table t1;
|
||||
GRANT FILE on mysqltest.* to mysqltest_1@localhost;
|
||||
Wrong usage of DB GRANT and GLOBAL PRIVILEGES
|
||||
select 1;
|
||||
1
|
||||
1
|
||||
|
@ -16,3 +16,13 @@ NULL NULL 0000-00-00 0000-00-00
|
||||
NULL 0000-00-00 0000-00-00 0000-00-00
|
||||
NULL 2003-03-03 2003-03-03 NULL
|
||||
drop table t1;
|
||||
create table t1 (a text, b text);
|
||||
load data infile '../../std_data/loaddata2.dat' into table t1 fields terminated by ',' enclosed by '''';
|
||||
select concat('|',a,'|'), concat('|',b,'|') from t1;
|
||||
concat('|',a,'|') concat('|',b,'|')
|
||||
|Field A| |Field B|
|
||||
|Field 1| |Field 2'
|
||||
Field 3,'Field 4|
|
||||
|Field 5' ,'Field 6| NULL
|
||||
|Field 6| | 'Field 7'|
|
||||
drop table t1;
|
||||
|
180
mysql-test/r/mix_innodb_myisam_binlog.result
Normal file
180
mysql-test/r/mix_innodb_myisam_binlog.result
Normal file
@ -0,0 +1,180 @@
|
||||
drop table if exists ti, tm;
|
||||
create table ti (a int) type=innodb;
|
||||
create table tm (a int) type=myisam;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(1);
|
||||
insert into tm select * from ti;
|
||||
commit;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(1)
|
||||
master-bin.001 178 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 244 Query 1 244 use test; COMMIT
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(2);
|
||||
insert into tm select * from ti;
|
||||
rollback;
|
||||
Warning: Some non-transactional changed tables couldn't be rolled back
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(2)
|
||||
master-bin.001 178 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 244 Query 1 244 use test; ROLLBACK
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(3);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(4);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
Warning: Some non-transactional changed tables couldn't be rolled back
|
||||
commit;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(3)
|
||||
master-bin.001 178 Query 1 79 use test; savepoint my_savepoint
|
||||
master-bin.001 235 Query 1 79 use test; insert into ti values(4)
|
||||
master-bin.001 294 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 360 Query 1 79 use test; rollback to savepoint my_savepoint
|
||||
master-bin.001 429 Query 1 429 use test; COMMIT
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(5);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(6);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
Warning: Some non-transactional changed tables couldn't be rolled back
|
||||
insert into ti values(7);
|
||||
commit;
|
||||
select a from ti order by a;
|
||||
a
|
||||
5
|
||||
7
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(5)
|
||||
master-bin.001 178 Query 1 79 use test; savepoint my_savepoint
|
||||
master-bin.001 235 Query 1 79 use test; insert into ti values(6)
|
||||
master-bin.001 294 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 360 Query 1 79 use test; rollback to savepoint my_savepoint
|
||||
master-bin.001 429 Query 1 79 use test; insert into ti values(7)
|
||||
master-bin.001 488 Query 1 488 use test; COMMIT
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
select get_lock("a",10);
|
||||
get_lock("a",10)
|
||||
1
|
||||
begin;
|
||||
insert into ti values(8);
|
||||
insert into tm select * from ti;
|
||||
select get_lock("a",10);
|
||||
get_lock("a",10)
|
||||
1
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(8)
|
||||
master-bin.001 178 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 244 Query 1 244 use test; ROLLBACK
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
insert into ti values(9);
|
||||
insert into tm select * from ti;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; insert into ti values(9)
|
||||
master-bin.001 138 Query 1 138 use test; insert into tm select * from ti
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
insert into ti values(10);
|
||||
begin;
|
||||
insert into tm select * from ti;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; insert into ti values(10)
|
||||
master-bin.001 139 Query 1 139 use test; insert into tm select * from ti
|
||||
insert into ti values(11);
|
||||
commit;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; insert into ti values(10)
|
||||
master-bin.001 139 Query 1 139 use test; insert into tm select * from ti
|
||||
master-bin.001 205 Query 1 205 use test; BEGIN
|
||||
master-bin.001 245 Query 1 205 use test; insert into ti values(11)
|
||||
master-bin.001 305 Query 1 305 use test; COMMIT
|
||||
alter table tm type=INNODB;
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(12);
|
||||
insert into tm select * from ti;
|
||||
commit;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(12)
|
||||
master-bin.001 179 Query 1 79 use test; insert into tm select * from ti
|
||||
master-bin.001 245 Query 1 245 use test; COMMIT
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(13);
|
||||
insert into tm select * from ti;
|
||||
rollback;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(14);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(15);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
commit;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(14)
|
||||
master-bin.001 179 Query 1 179 use test; COMMIT
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
begin;
|
||||
insert into ti values(16);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(17);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
insert into ti values(18);
|
||||
commit;
|
||||
select a from ti order by a;
|
||||
a
|
||||
16
|
||||
18
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
master-bin.001 79 Query 1 79 use test; BEGIN
|
||||
master-bin.001 119 Query 1 79 use test; insert into ti values(16)
|
||||
master-bin.001 179 Query 1 79 use test; insert into ti values(18)
|
||||
master-bin.001 239 Query 1 239 use test; COMMIT
|
||||
drop table ti,tm;
|
@ -3,8 +3,8 @@ create table t1(f1 int);
|
||||
insert into t1 values (5);
|
||||
grant select on test.* to ssl_user1@localhost require SSL;
|
||||
grant select on test.* to ssl_user2@localhost require cipher "EDH-RSA-DES-CBC3-SHA";
|
||||
grant select on test.* to ssl_user3@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=RU/L=orenburg/O=MySQL AB/OU=client/CN=walrus/Email=walrus@mysql.com";
|
||||
grant select on test.* to ssl_user4@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=RU/L=orenburg/O=MySQL AB/OU=client/CN=walrus/Email=walrus@mysql.com" ISSUER "/C=RU/ST=Some-State/L=Orenburg/O=MySQL AB/CN=Walrus/Email=walrus@mysql.com";
|
||||
grant select on test.* to ssl_user3@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=SE/L=Uppsala/O=MySQL AB/CN=MySQL Client/Email=abstract.mysql.developer@mysql.com";
|
||||
grant select on test.* to ssl_user4@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=SE/L=Uppsala/O=MySQL AB/CN=MySQL Client/Email=abstract.mysql.developer@mysql.com" ISSUER "/C=SE/L=Uppsala/O=MySQL AB/CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com";
|
||||
flush privileges;
|
||||
select * from t1;
|
||||
f1
|
||||
|
@ -5,12 +5,12 @@ set net_buffer_length=100;
|
||||
SELECT length("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") as len;
|
||||
len
|
||||
1024
|
||||
select repeat('a',200);
|
||||
repeat('a',200)
|
||||
select repeat('a',2000);
|
||||
repeat('a',2000)
|
||||
NULL
|
||||
select @@net_buffer_length, @@max_allowed_packet;
|
||||
@@net_buffer_length @@max_allowed_packet
|
||||
1024 80
|
||||
1024 1024
|
||||
SELECT length("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") as len;
|
||||
len
|
||||
100
|
||||
select length(repeat('a',200));
|
||||
length(repeat('a',200))
|
||||
200
|
||||
select length(repeat('a',2000));
|
||||
length(repeat('a',2000))
|
||||
2000
|
||||
|
@ -2,7 +2,7 @@ flush query cache;
|
||||
flush query cache;
|
||||
reset query cache;
|
||||
flush status;
|
||||
drop table if exists t1,t2,t3,t11,t21, mysqltest.t1;
|
||||
drop table if exists t1,t2,t3;
|
||||
drop database if exists mysqltest;
|
||||
create table t1 (a int not null);
|
||||
insert into t1 values (1),(2),(3);
|
||||
|
20
mysql-test/r/query_cache_merge.result
Normal file
20
mysql-test/r/query_cache_merge.result
Normal file
@ -0,0 +1,20 @@
|
||||
SET @@global.query_cache_size=1355776;
|
||||
flush status;
|
||||
select count(*) from t00;
|
||||
count(*)
|
||||
514
|
||||
select count(*) from t00;
|
||||
count(*)
|
||||
514
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 1
|
||||
show status like "Qcache_hits";
|
||||
Variable_name Value
|
||||
Qcache_hits 1
|
||||
delete from t256;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
drop table t1,t2,t3,t4,t5,t6,t7,t8,t9,t10,t11,t12,t13,t14,t15,t16,t17,t18,t19,t20,t21,t22,t23,t24,t25,t26,t27,t28,t29,t30,t31,t32,t33,t34,t35,t36,t37,t38,t39,t40,t41,t42,t43,t44,t45,t46,t47,t48,t49,t50,t51,t52,t53,t54,t55,t56,t57,t58,t59,t60,t61,t62,t63,t64,t65,t66,t67,t68,t69,t70,t71,t72,t73,t74,t75,t76,t77,t78,t79,t80,t81,t82,t83,t84,t85,t86,t87,t88,t89,t90,t91,t92,t93,t94,t95,t96,t97,t98,t99,t100,t101,t102,t103,t104,t105,t106,t107,t108,t109,t110,t111,t112,t113,t114,t115,t116,t117,t118,t119,t120,t121,t122,t123,t124,t125,t126,t127,t128,t129,t130,t131,t132,t133,t134,t135,t136,t137,t138,t139,t140,t141,t142,t143,t144,t145,t146,t147,t148,t149,t150,t151,t152,t153,t154,t155,t156,t157,t158,t159,t160,t161,t162,t163,t164,t165,t166,t167,t168,t169,t170,t171,t172,t173,t174,t175,t176,t177,t178,t179,t180,t181,t182,t183,t184,t185,t186,t187,t188,t189,t190,t191,t192,t193,t194,t195,t196,t197,t198,t199,t200,t201,t202,t203,t204,t205,t206,t207,t208,t209,t210,t211,t212,t213,t214,t215,t216,t217,t218,t219,t220,t221,t222,t223,t224,t225,t226,t227,t228,t229,t230,t231,t232,t233,t234,t235,t236,t237,t238,t239,t240,t241,t242,t243,t244,t245,t246,t247,t248,t249,t250,t251,t252,t253,t254,t255,t256,t257,t00;
|
||||
SET @@global.query_cache_size=0;
|
@ -226,3 +226,31 @@ insert into t1 values (0,1,NULL,"aaa"), (1,1,NULL,"aaa"), (2,1,NULL,"aaa"),
|
||||
select a.id1, b.idnull from t1 as a, t1 as b where a.id2=1 and a.id1=1 and b.id1=a.idnull order by b.id2 desc limit 1;
|
||||
id1 idnull
|
||||
drop table t1;
|
||||
create table t1 (x int, y int, index(x), index(y));
|
||||
insert into t1 (x) values (1),(2),(3),(4),(5),(6),(7),(8),(9);
|
||||
update t1 set y=x;
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between 7 and t1.y+0;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 range x x 5 NULL 4 Using where
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= 7 and t2.x <= t1.y+0;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 range x x 5 NULL 4 Using where
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between t1.y-1 and t1.y+1;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 ALL x NULL NULL NULL 9 Range checked for each record (index map: 1)
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= t1.y-1 and t2.x <= t1.y+1;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 ALL x NULL NULL NULL 9 Range checked for each record (index map: 1)
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between 0 and t1.y;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 ALL x NULL NULL NULL 9 Using where
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= 0 and t2.x <= t1.y;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ref y y 5 const 1 Using where
|
||||
t2 range x x 5 NULL 2 Using where
|
||||
drop table t1;
|
||||
|
26
mysql-test/r/rpl_do_grant.result
Normal file
26
mysql-test/r/rpl_do_grant.result
Normal file
@ -0,0 +1,26 @@
|
||||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
delete from mysql.user where user='rpl_do_grant';
|
||||
delete from mysql.db where user='rpl_do_grant';
|
||||
flush privileges;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
grant select on *.* to rpl_do_grant@localhost;
|
||||
grant drop on test.* to rpl_do_grant@localhost;
|
||||
show grants for rpl_do_grant@localhost;
|
||||
Grants for rpl_do_grant@localhost
|
||||
GRANT SELECT ON *.* TO 'rpl_do_grant'@'localhost'
|
||||
GRANT DROP ON `test`.* TO 'rpl_do_grant'@'localhost'
|
||||
set password for rpl_do_grant@localhost=password("does it work?");
|
||||
select password<>'' from mysql.user where user='rpl_do_grant';
|
||||
password<>''
|
||||
1
|
||||
delete from mysql.user where user='rpl_do_grant';
|
||||
delete from mysql.db where user='rpl_do_grant';
|
||||
flush privileges;
|
||||
flush privileges;
|
37
mysql-test/r/rpl_ignore_grant.result
Normal file
37
mysql-test/r/rpl_ignore_grant.result
Normal file
@ -0,0 +1,37 @@
|
||||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
grant select on *.* to rpl_ignore_grant@localhost;
|
||||
grant drop on test.* to rpl_ignore_grant@localhost;
|
||||
show grants for rpl_ignore_grant@localhost;
|
||||
Grants for rpl_ignore_grant@localhost
|
||||
GRANT SELECT ON *.* TO 'rpl_ignore_grant'@'localhost'
|
||||
GRANT DROP ON `test`.* TO 'rpl_ignore_grant'@'localhost'
|
||||
show grants for rpl_ignore_grant@localhost;
|
||||
There is no such grant defined for user 'rpl_ignore_grant' on host 'localhost'
|
||||
select count(*) from mysql.user where user='rpl_ignore_grant';
|
||||
count(*)
|
||||
0
|
||||
select count(*) from mysql.db where user='rpl_ignore_grant';
|
||||
count(*)
|
||||
0
|
||||
grant select on *.* to rpl_ignore_grant@localhost;
|
||||
set password for rpl_ignore_grant@localhost=password("does it work?");
|
||||
select password<>'' from mysql.user where user='rpl_ignore_grant';
|
||||
password<>''
|
||||
0
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
@ -21,8 +21,8 @@ b c
|
||||
1 4
|
||||
drop table t1;
|
||||
drop table t2;
|
||||
create table t1(a int auto_increment, key(a));
|
||||
create table t2(b int auto_increment, c int, key(b));
|
||||
create table t1(a int auto_increment, key(a)) type=innodb;
|
||||
create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) type=innodb;
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
insert into t1 values (10);
|
||||
insert into t1 values (null),(null),(null);
|
||||
|
@ -4,6 +4,7 @@ reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
reset master;
|
||||
create table t1(a int not null auto_increment, b int, primary key(a) );
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
create temporary table t2 (day date,id int(9),category enum('a','b','c'),name varchar(60));
|
||||
@ -19,9 +20,38 @@ day id category name
|
||||
2003-02-22 2461 b a a a @ % ' " a
|
||||
2003-03-22 2161 c asdf
|
||||
2003-04-22 2416 a bbbbb
|
||||
show master status;
|
||||
File Position Binlog_do_db Binlog_ignore_db
|
||||
slave-bin.001 964
|
||||
drop table t1;
|
||||
drop table t2;
|
||||
drop table t3;
|
||||
create table t1(a int, b int, unique(b));
|
||||
insert into t1 values(1,10);
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
set global sql_slave_skip_counter=1;
|
||||
start slave;
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 master-bin.001 1311 slave-relay-bin.002 1352 master-bin.001 Yes Yes 0 0 1311 1352
|
||||
set sql_log_bin=0;
|
||||
delete from t1;
|
||||
set sql_log_bin=1;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
stop slave;
|
||||
change master to master_user='test';
|
||||
change master to master_user='root';
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 master-bin.001 1442 slave-relay-bin.001 4 master-bin.001 No No 0 0 1442 4
|
||||
set global sql_slave_skip_counter=1;
|
||||
start slave;
|
||||
set sql_log_bin=0;
|
||||
delete from t1;
|
||||
set sql_log_bin=1;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
stop slave;
|
||||
reset slave;
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 4 slave-relay-bin.001 4 No No 0 0 0 4
|
||||
|
14
mysql-test/r/rpl_loaddata_rule_m.result
Normal file
14
mysql-test/r/rpl_loaddata_rule_m.result
Normal file
@ -0,0 +1,14 @@
|
||||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
reset master;
|
||||
create database test2;
|
||||
create table t1(a int, b int, unique(b));
|
||||
use test2;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
drop database test2;
|
14
mysql-test/r/rpl_loaddata_rule_s.result
Normal file
14
mysql-test/r/rpl_loaddata_rule_s.result
Normal file
@ -0,0 +1,14 @@
|
||||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
reset master;
|
||||
create table t1(a int, b int, unique(b));
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
2
|
||||
show binlog events from 79;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
@ -12,7 +12,10 @@ create table t1(n int not null auto_increment primary key);
|
||||
insert into t1 values (NULL);
|
||||
drop table t1;
|
||||
create table t1 (word char(20) not null);
|
||||
load data infile '../../std_data/words.dat' into table t1;
|
||||
load data infile '../../std_data/words.dat' into table t1 ignore 1 lines;
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
69
|
||||
drop table t1;
|
||||
show binlog events;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
@ -81,16 +84,16 @@ slave-bin.001 200 Query 1 200 use test; insert into t1 values (NULL)
|
||||
slave-bin.001 263 Query 1 263 use test; drop table t1
|
||||
slave-bin.001 311 Query 1 311 use test; create table t1 (word char(20) not null)
|
||||
slave-bin.001 386 Create_file 1 386 db=test;table=t1;file_id=1;block_len=581
|
||||
slave-bin.001 1065 Exec_load 1 1056 ;file_id=1
|
||||
slave-bin.001 1088 Query 1 1079 use test; drop table t1
|
||||
slave-bin.001 1136 Query 1 4 use test; create table t5 (a int)
|
||||
slave-bin.001 1194 Query 1 62 use test; drop table t5
|
||||
slave-bin.001 1065 Exec_load 1 1065 ;file_id=1
|
||||
slave-bin.001 1088 Query 1 1088 use test; drop table t1
|
||||
slave-bin.001 1136 Query 1 1136 use test; create table t5 (a int)
|
||||
slave-bin.001 1194 Query 1 1194 use test; drop table t5
|
||||
slave-bin.001 1242 Rotate 2 1242 slave-bin.002;pos=4
|
||||
show binlog events in 'slave-bin.002' from 4;
|
||||
Log_name Pos Event_type Server_id Orig_log_pos Info
|
||||
slave-bin.002 4 Query 1 110 use test; create table t1 (n int)
|
||||
slave-bin.002 62 Query 1 168 use test; insert into t1 values (1)
|
||||
slave-bin.002 122 Query 1 228 use test; drop table t1
|
||||
slave-bin.002 4 Query 1 4 use test; create table t1 (n int)
|
||||
slave-bin.002 62 Query 1 62 use test; insert into t1 values (1)
|
||||
slave-bin.002 122 Query 1 122 use test; drop table t1
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 master-bin.002 276 slave-relay-bin.003 211 master-bin.002 Yes Yes 0 0 276 211
|
||||
|
22
mysql-test/r/rpl_reset_slave.result
Normal file
22
mysql-test/r/rpl_reset_slave.result
Normal file
@ -0,0 +1,22 @@
|
||||
slave stop;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
reset master;
|
||||
reset slave;
|
||||
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
|
||||
slave start;
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 master-bin.001 79 slave-relay-bin.002 120 master-bin.001 Yes Yes 0 0 79 120
|
||||
stop slave;
|
||||
change master to master_user='test';
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 test MASTER_PORT 1 master-bin.001 79 slave-relay-bin.001 4 master-bin.001 No No 0 0 79 4
|
||||
reset slave;
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 4 slave-relay-bin.001 4 No No 0 0 0 4
|
||||
start slave;
|
||||
show slave status;
|
||||
Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space
|
||||
127.0.0.1 root MASTER_PORT 1 master-bin.001 79 slave-relay-bin.002 120 master-bin.001 Yes Yes 0 0 79 120
|
@ -3508,3 +3508,23 @@ aa id t2_id id
|
||||
5 8303 2520 2520
|
||||
6 8304 2521 2521
|
||||
drop table t1,t2;
|
||||
create table t1 (id1 int NOT NULL);
|
||||
create table t2 (id2 int NOT NULL);
|
||||
create table t3 (id3 int NOT NULL);
|
||||
create table t4 (id4 int NOT NULL, id44 int NOT NULL, KEY (id4));
|
||||
insert into t1 values (1);
|
||||
insert into t1 values (2);
|
||||
insert into t2 values (1);
|
||||
insert into t4 values (1,1);
|
||||
explain select * from t1 left join t2 on id1 = id2 left join t3 on id1 = id3
|
||||
left join t4 on id3 = id4 where id2 = 1 or id4 = 1;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t3 system NULL NULL NULL NULL 0 const row not found
|
||||
t1 ALL NULL NULL NULL NULL 2
|
||||
t2 ALL NULL NULL NULL NULL 1
|
||||
t4 ALL id4 NULL NULL NULL 1 Using where
|
||||
select * from t1 left join t2 on id1 = id2 left join t3 on id1 = id3
|
||||
left join t4 on id3 = id4 where id2 = 1 or id4 = 1;
|
||||
id1 id2 id3 id4 id44
|
||||
1 1 NULL NULL NULL
|
||||
drop table t1,t2,t3,t4;
|
||||
|
@ -67,12 +67,12 @@ analyze table t1;
|
||||
Table Op Msg_type Msg_text
|
||||
test.t1 analyze status OK
|
||||
insert into t1 values (null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a"),(null,"a");
|
||||
explain select * from t1,t1 as t2 where t1.b=t2.b;
|
||||
explain select STRAIGHT_JOIN * from t1,t1 as t2 where t1.b=t2.b;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ALL b NULL NULL NULL 21
|
||||
t2 ALL b NULL NULL NULL 16 Using where
|
||||
set MAX_SEEKS_FOR_KEY=1;
|
||||
explain select * from t1,t1 as t2 where t1.b=t2.b;
|
||||
explain select STRAIGHT_JOIN * from t1,t1 as t2 where t1.b=t2.b;
|
||||
table type possible_keys key key_len ref rows Extra
|
||||
t1 ALL b NULL NULL NULL 21
|
||||
t2 ref b b 21 t1.b 6 Using where
|
||||
|
@ -32,6 +32,8 @@ datum
|
||||
2000-01-02
|
||||
2000-01-03
|
||||
2000-01-04
|
||||
SELECT * FROM t1 WHERE datum BETWEEN "2000-1-2" AND datum - INTERVAL 100 DAY;
|
||||
datum
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (
|
||||
user_id char(10),
|
||||
|
@ -295,57 +295,128 @@ a b
|
||||
5 f
|
||||
6 e
|
||||
drop table t1,t2,t3,t4;
|
||||
CREATE TABLE t1 ( `IdUser` int(11) NOT NULL default '0', `IdDirectMessage` int(11) NOT NULL default '0', `Readed` datetime default NULL, PRIMARY KEY (`IdUser`,`IdDirectMessage`), KEY `IdDirectMessage` (`IdDirectMessage`), );
|
||||
CREATE TABLE t2 ( `IdDirectMessage` int(11) NOT NULL default '0', `MessageData` text NOT NULL, `DateOfMessage` datetime default NULL, PRIMARY KEY (`IdDirectMessage`) );
|
||||
INSERT INTO t2 (`IdDirectMessage`, `MessageData`, `DateOfMessage`) VALUES (1,'Texto','2003-08-06 00:00:00'), (2,'Texto','2003-08-06 00:00:00'), (3,'Texto','2003-08-06 00:00:00'), (4,'Texto','2003-08-06 00:00:00'), (5,'Texto','2003-08-06 00:00:00'), (6,'Texto','2003-08-06 00:00:00'), (7,'Texto','2003-08-06 00:00:00'), (8,'Texto','2003-08-06 00:00:00'), (9,'Texto','2003-08-06 00:00:00'), (10,'Texto','2003-08-06 00:00:00'), (11,'Texto','2003-08-06 00:00:00'), (12,'Texto','2003-08-06 00:00:00'), (13,'Texto','2003-08-06 00:00:00'), (14,'Texto','2003-08-06 00:00:00'), (15,'Texto','2003-08-06 00:00:00'), (16,'Texto','2003-08-06 00:00:00'), (17,'Texto','2003-08-06 00:00:00'), (18,'Texto','2003-08-06 00:00:00'), (19,'Texto','2003-08-06 00:00:00'), (20,'Texto','2003-08-06 00:00:00'), (21,'Texto','2003-08-06 00:00:00'), (22,'Texto','2003-08-06 00:00:00');
|
||||
INSERT INTO t1 (`IdUser`, `IdDirectMessage`, `Readed`) VALUES (4,1,'2003-08-07 10:10:13'), (4,2,'2003-08-07 10:10:13'), (4,3,'2003-08-07 10:10:13'), (4,4,'2003-08-07 10:10:13'), (4,5,'2003-08-07 10:10:13'), (4,6,'2003-08-07 10:10:13'), (4,7,'2003-08-07 10:10:13'), (4,8,'2003-08-07 10:10:13'), (4,9,'2003-08-07 10:10:13'), (4,10,'2003-08-07 10:10:13'), (4,11,'2003-08-07 10:10:13'), (4,12,'2003-08-07 10:10:13'), (4,13,'2003-08-07 10:10:13'), (4,14,'2003-08-07 10:10:13'), (4,15,'2003-08-07 10:10:13'), (4,16,'2003-08-07 10:10:13'), (4,17,'2003-08-07 10:10:13'), (4,18,'2003-08-07 10:10:13'), (4,19,'2003-08-07 10:10:13'), (4,20,'2003-08-07 10:10:13'), (4,21,'2003-08-06 16:51:04'), (4,22,'2003-08-06 16:51:19');
|
||||
SELECT SQL_CALC_FOUND_ROWS t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND Readed Is NULL UNION SELECT t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND NOT (t1.Readed is NULL) ORDER BY DateOfMessage Limit 0,2;
|
||||
IdDirectMessage MessageData DateOfMessage
|
||||
1 Texto 2003-08-06 00:00:00
|
||||
2 Texto 2003-08-06 00:00:00
|
||||
SELECT FOUND_ROWS();
|
||||
FOUND_ROWS()
|
||||
22
|
||||
SELECT SQL_CALC_FOUND_ROWS t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND Readed Is NULL UNION ALL SELECT t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND NOT (t1.Readed is NULL) ORDER BY DateOfMessage Limit 0,2;
|
||||
IdDirectMessage MessageData DateOfMessage
|
||||
1 Texto 2003-08-06 00:00:00
|
||||
2 Texto 2003-08-06 00:00:00
|
||||
SELECT FOUND_ROWS();
|
||||
FOUND_ROWS()
|
||||
22
|
||||
SELECT SQL_CALC_FOUND_ROWS t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND Readed Is NULL limit 1 UNION SELECT t2.* FROM t2 INNER JOIN t1 ON t2.IdDirectMessage = t1.IdDirectMessage WHERE IdUser = 4 AND NOT (t1.Readed is NULL) ORDER BY DateOfMessage;
|
||||
IdDirectMessage MessageData DateOfMessage
|
||||
1 Texto 2003-08-06 00:00:00
|
||||
2 Texto 2003-08-06 00:00:00
|
||||
3 Texto 2003-08-06 00:00:00
|
||||
4 Texto 2003-08-06 00:00:00
|
||||
5 Texto 2003-08-06 00:00:00
|
||||
6 Texto 2003-08-06 00:00:00
|
||||
7 Texto 2003-08-06 00:00:00
|
||||
8 Texto 2003-08-06 00:00:00
|
||||
9 Texto 2003-08-06 00:00:00
|
||||
10 Texto 2003-08-06 00:00:00
|
||||
11 Texto 2003-08-06 00:00:00
|
||||
12 Texto 2003-08-06 00:00:00
|
||||
13 Texto 2003-08-06 00:00:00
|
||||
14 Texto 2003-08-06 00:00:00
|
||||
15 Texto 2003-08-06 00:00:00
|
||||
16 Texto 2003-08-06 00:00:00
|
||||
17 Texto 2003-08-06 00:00:00
|
||||
18 Texto 2003-08-06 00:00:00
|
||||
19 Texto 2003-08-06 00:00:00
|
||||
20 Texto 2003-08-06 00:00:00
|
||||
21 Texto 2003-08-06 00:00:00
|
||||
22 Texto 2003-08-06 00:00:00
|
||||
SELECT FOUND_ROWS();
|
||||
FOUND_ROWS()
|
||||
22
|
||||
drop table t2,t1;
|
||||
CREATE TABLE t1 ( sid int(11) NOT NULL default '0', nazwa char(10) NOT NULL default '', PRIMARY KEY (sid) ) TYPE=MyISAM;
|
||||
CREATE TABLE t2 ( id int(11) NOT NULL default '0', link int(11) default NULL, bubu char(10) NOT NULL default '', PRIMARY KEY (id) ) TYPE=MyISAM;
|
||||
INSERT INTO t2 VALUES (1,2,'keke');
|
||||
SELECT bubu, nazwa, bubu FROM t2 LEFT JOIN t1 ON sid = link WHERE id=1 UNION SELECT 'bu', null, 'bu';
|
||||
bubu nazwa bubu
|
||||
keke NULL keke
|
||||
bu NULL bu
|
||||
create table t1 (a int);
|
||||
insert into t1 values (1),(2),(3);
|
||||
create table t2 (a int);
|
||||
insert into t2 values (3),(4),(5);
|
||||
(SELECT SQL_CALC_FOUND_ROWS * FROM t1) UNION all (SELECT * FROM t2) LIMIT 1;
|
||||
a
|
||||
1
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
(SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1) UNION all (SELECT * FROM t2) LIMIT 2;
|
||||
a
|
||||
1
|
||||
3
|
||||
select found_rows();
|
||||
found_rows()
|
||||
4
|
||||
(SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1) UNION all (SELECT * FROM t2);
|
||||
a
|
||||
1
|
||||
3
|
||||
4
|
||||
5
|
||||
select found_rows();
|
||||
found_rows()
|
||||
4
|
||||
(SELECT SQL_CALC_FOUND_ROWS * FROM t1) UNION all (SELECT * FROM t2 LIMIT 1);
|
||||
a
|
||||
1
|
||||
2
|
||||
3
|
||||
3
|
||||
select found_rows();
|
||||
found_rows()
|
||||
4
|
||||
(SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1) UNION SELECT * FROM t2 LIMIT 1;
|
||||
a
|
||||
1
|
||||
select found_rows();
|
||||
found_rows()
|
||||
4
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1 UNION all SELECT * FROM t2 LIMIT 2;
|
||||
a
|
||||
1
|
||||
3
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 UNION all SELECT * FROM t2 LIMIT 2;
|
||||
a
|
||||
1
|
||||
2
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 UNION SELECT * FROM t2 LIMIT 2;
|
||||
a
|
||||
1
|
||||
2
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 UNION SELECT * FROM t2 LIMIT 100;
|
||||
a
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 100 UNION SELECT * FROM t2;
|
||||
a
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
select found_rows();
|
||||
found_rows()
|
||||
5
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1 UNION SELECT * FROM t2;
|
||||
a
|
||||
1
|
||||
3
|
||||
4
|
||||
5
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 LIMIT 1 UNION SELECT * FROM t2 LIMIT 2;
|
||||
a
|
||||
1
|
||||
3
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 UNION SELECT * FROM t2 LIMIT 2,2;
|
||||
a
|
||||
3
|
||||
4
|
||||
select found_rows();
|
||||
found_rows()
|
||||
6
|
||||
SELECT SQL_CALC_FOUND_ROWS * FROM t1 limit 2,2 UNION SELECT * FROM t2;
|
||||
a
|
||||
3
|
||||
4
|
||||
5
|
||||
select found_rows();
|
||||
found_rows()
|
||||
5
|
||||
SELECT * FROM t1 UNION SELECT * FROM t2 ORDER BY a desc LIMIT 1;
|
||||
a
|
||||
5
|
||||
(SELECT * FROM t1 ORDER by a) UNION ALL (SELECT * FROM t2 ORDER BY a) ORDER BY A desc LIMIT 4;
|
||||
a
|
||||
5
|
||||
4
|
||||
3
|
||||
3
|
||||
(SELECT * FROM t1) UNION all (SELECT SQL_CALC_FOUND_ROWS * FROM t2) LIMIT 1;
|
||||
Wrong usage/placement of 'SQL_CALC_FOUND_ROWS'
|
||||
drop table t1,t2;
|
||||
|
5
mysql-test/std_data/loaddata2.dat
Normal file
5
mysql-test/std_data/loaddata2.dat
Normal file
@ -0,0 +1,5 @@
|
||||
Field A,'Field B'
|
||||
Field 1,'Field 2'
|
||||
Field 3,'Field 4'
|
||||
'Field 5' ,'Field 6'
|
||||
Field 6, 'Field 7'
|
@ -189,7 +189,7 @@ select * from t1 where match (a) against ('aaaa');
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# bug 283 by jocelyn fournier <joc@presence-pc.com>
|
||||
# bug #283 by jocelyn fournier <joc@presence-pc.com>
|
||||
# FULLTEXT index on a TEXT filed converted to a CHAR field doesn't work anymore
|
||||
#
|
||||
|
||||
@ -201,3 +201,17 @@ alter table t1 change ref_mag ref_mag char (255) not null;
|
||||
select ref_mag from t1 where match ref_mag against ('+test' in boolean mode);
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# bug #942: JOIN
|
||||
#
|
||||
|
||||
create table t1 (t1_id int(11) primary key, name varchar(32));
|
||||
insert into t1 values (1, 'data1');
|
||||
insert into t1 values (2, 'data2');
|
||||
create table t2 (t2_id int(11) primary key, t1_id int(11), name varchar(32));
|
||||
insert into t2 values (1, 1, 'xxfoo');
|
||||
insert into t2 values (2, 1, 'xxbar');
|
||||
insert into t2 values (3, 1, 'xxbuz');
|
||||
select * from t1 join t2 using(`t1_id`) where match (t1.name, t2.name) against('xxfoo' in boolean mode);
|
||||
drop table t1,t2;
|
||||
|
||||
|
@ -18,6 +18,11 @@ select -1.49 or -1.49,0.6 or 0.6;
|
||||
select 3 ^ 11, 1 ^ 1, 1 ^ 0, 1 ^ NULL, NULL ^ 1;
|
||||
select 1 XOR 1, 1 XOR 0, 0 XOR 1, 0 XOR 0, NULL XOR 1, 1 XOR NULL, 0 XOR NULL;
|
||||
|
||||
create table t1 (a int);
|
||||
insert t1 values (1);
|
||||
select * from t1 where 1 xor 1;
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# Wrong usage of functions
|
||||
#
|
||||
|
@ -82,5 +82,10 @@ delete from mysql.tables_priv where user='mysqltest_1';
|
||||
delete from mysql.columns_priv where user='mysqltest_1';
|
||||
flush privileges;
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# Test some error conditions
|
||||
#
|
||||
--error 1221
|
||||
GRANT FILE on mysqltest.* to mysqltest_1@localhost;
|
||||
select 1; -- To test that the previous command didn't cause problems
|
||||
|
@ -14,6 +14,7 @@ load data infile '../../std_data/loaddata1.dat' into table t1 fields terminated
|
||||
SELECT * from t1;
|
||||
drop table t1;
|
||||
|
||||
|
||||
|
||||
|
||||
create table t1 (a text, b text);
|
||||
load data infile '../../std_data/loaddata2.dat' into table t1 fields terminated by ',' enclosed by '''';
|
||||
select concat('|',a,'|'), concat('|',b,'|') from t1;
|
||||
drop table t1;
|
||||
|
@ -1 +1 @@
|
||||
--binlog-ignore-db=test innodb
|
||||
--binlog-ignore-db=test
|
||||
|
175
mysql-test/t/mix_innodb_myisam_binlog.test
Normal file
175
mysql-test/t/mix_innodb_myisam_binlog.test
Normal file
@ -0,0 +1,175 @@
|
||||
# Check that binlog is ok when a transaction mixes updates to InnoDB and
|
||||
# MyISAM. It would be nice to make this a replication test, but in 4.0 the slave
|
||||
# is always with --skip-innodb in the testsuite. I (Guilhem) however did some
|
||||
# tests manually on a slave; tables are replicated fine and Exec_master_log_pos
|
||||
# advances as expected.
|
||||
|
||||
-- source include/have_innodb.inc
|
||||
|
||||
connect (con1,localhost,root,,);
|
||||
connect (con2,localhost,root,,);
|
||||
|
||||
connection con1;
|
||||
|
||||
drop table if exists ti, tm;
|
||||
create table ti (a int) type=innodb;
|
||||
create table tm (a int) type=myisam;
|
||||
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(1);
|
||||
insert into tm select * from ti;
|
||||
commit;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(2);
|
||||
insert into tm select * from ti;
|
||||
# should say some changes to non-transactional tables couldn't be rolled back
|
||||
--error 1196
|
||||
rollback;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(3);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(4);
|
||||
insert into tm select * from ti;
|
||||
--error 1196
|
||||
rollback to savepoint my_savepoint;
|
||||
commit;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(5);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(6);
|
||||
insert into tm select * from ti;
|
||||
--error 1196
|
||||
rollback to savepoint my_savepoint;
|
||||
insert into ti values(7);
|
||||
commit;
|
||||
select a from ti order by a; # check that savepoints work :)
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
# and when ROLLBACK is not explicit?
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
select get_lock("a",10);
|
||||
begin;
|
||||
insert into ti values(8);
|
||||
insert into tm select * from ti;
|
||||
disconnect con1;
|
||||
|
||||
connection con2;
|
||||
# We want to SHOW BINLOG EVENTS, to know what was logged. But there is no
|
||||
# guarantee that logging of the terminated con1 has been done yet (it may not
|
||||
# even be started, so con1 may have not even attempted to lock the binlog yet;
|
||||
# so SHOW BINLOG EVENTS may come before con1 does the loggin. To be sure that
|
||||
# logging has been done, we use a user lock.
|
||||
select get_lock("a",10);
|
||||
show binlog events from 79;
|
||||
|
||||
# and when not in a transaction?
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
insert into ti values(9);
|
||||
insert into tm select * from ti;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
# Check that when the query updating the MyISAM table is the first in the
|
||||
# transaction, we log it immediately.
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
insert into ti values(10); # first make ti non-empty
|
||||
begin;
|
||||
insert into tm select * from ti;
|
||||
show binlog events from 79;
|
||||
insert into ti values(11);
|
||||
commit;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
|
||||
# Check that things work like before this BEGIN/ROLLBACK code was added, when tm
|
||||
# is INNODB
|
||||
|
||||
alter table tm type=INNODB;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(12);
|
||||
insert into tm select * from ti;
|
||||
commit;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(13);
|
||||
insert into tm select * from ti;
|
||||
rollback;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(14);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(15);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
commit;
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
delete from ti;
|
||||
delete from tm;
|
||||
reset master;
|
||||
|
||||
begin;
|
||||
insert into ti values(16);
|
||||
savepoint my_savepoint;
|
||||
insert into ti values(17);
|
||||
insert into tm select * from ti;
|
||||
rollback to savepoint my_savepoint;
|
||||
insert into ti values(18);
|
||||
commit;
|
||||
select a from ti order by a; # check that savepoints work :)
|
||||
|
||||
show binlog events from 79;
|
||||
|
||||
drop table ti,tm;
|
@ -8,8 +8,8 @@ insert into t1 values (5);
|
||||
|
||||
grant select on test.* to ssl_user1@localhost require SSL;
|
||||
grant select on test.* to ssl_user2@localhost require cipher "EDH-RSA-DES-CBC3-SHA";
|
||||
grant select on test.* to ssl_user3@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=RU/L=orenburg/O=MySQL AB/OU=client/CN=walrus/Email=walrus@mysql.com";
|
||||
grant select on test.* to ssl_user4@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=RU/L=orenburg/O=MySQL AB/OU=client/CN=walrus/Email=walrus@mysql.com" ISSUER "/C=RU/ST=Some-State/L=Orenburg/O=MySQL AB/CN=Walrus/Email=walrus@mysql.com";
|
||||
grant select on test.* to ssl_user3@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=SE/L=Uppsala/O=MySQL AB/CN=MySQL Client/Email=abstract.mysql.developer@mysql.com";
|
||||
grant select on test.* to ssl_user4@localhost require cipher "EDH-RSA-DES-CBC3-SHA" AND SUBJECT "/C=SE/L=Uppsala/O=MySQL AB/CN=MySQL Client/Email=abstract.mysql.developer@mysql.com" ISSUER "/C=SE/L=Uppsala/O=MySQL AB/CN=Abstract MySQL Developer/Email=abstract.mysql.developer@mysql.com";
|
||||
flush privileges;
|
||||
connect (con1,localhost,ssl_user1,,);
|
||||
connect (con2,localhost,ssl_user2,,);
|
||||
|
@ -12,8 +12,8 @@ set global net_buffer_length=100;
|
||||
set net_buffer_length=100;
|
||||
# Have to be > 1024 as min value of net_buffer_length is 1024
|
||||
SELECT length("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") as len;
|
||||
# Should return NULL as 200 is bigger than max_allowed_packet
|
||||
select repeat('a',200);
|
||||
# Should return NULL as 2000 is bigger than max_allowed_packet
|
||||
select repeat('a',2000);
|
||||
|
||||
#
|
||||
# Connection 2 should get error for too big packets
|
||||
@ -28,4 +28,4 @@ set max_allowed_packet=default;
|
||||
set global net_buffer_length=default;
|
||||
set net_buffer_length=default;
|
||||
SELECT length("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") as len;
|
||||
select length(repeat('a',200));
|
||||
select length(repeat('a',2000));
|
||||
|
@ -10,7 +10,7 @@ flush query cache; # This crashed in some versions
|
||||
flush query cache; # This crashed in some versions
|
||||
reset query cache;
|
||||
flush status;
|
||||
drop table if exists t1,t2,t3,t11,t21, mysqltest.t1;
|
||||
drop table if exists t1,t2,t3;
|
||||
drop database if exists mysqltest;
|
||||
|
||||
#
|
||||
|
38
mysql-test/t/query_cache_merge.test
Normal file
38
mysql-test/t/query_cache_merge.test
Normal file
@ -0,0 +1,38 @@
|
||||
# Test query cache with many tables
|
||||
|
||||
--source include/have_query_cache.inc
|
||||
let $LIMIT=`SHOW VARIABLES LIKE 'open_files_limit'`;
|
||||
let $MIN_LIMIT=100
|
||||
let $MAX_LIMIT=65536
|
||||
--source include/check_var_limit.inc
|
||||
|
||||
SET @@global.query_cache_size=1355776;
|
||||
|
||||
#
|
||||
# more then 255 (257) merged tables test
|
||||
#
|
||||
|
||||
flush status;
|
||||
disable_query_log;
|
||||
--disable_warnings
|
||||
let $1 = 257;
|
||||
while ($1)
|
||||
{
|
||||
eval drop table if exists t$1;
|
||||
eval create table t$1(a int);
|
||||
eval insert into t$1 values (1),(2);
|
||||
dec $1;
|
||||
}
|
||||
--enable_warnings
|
||||
|
||||
create table t00 (a int) type=MERGE UNION=(t1,t2,t3,t4,t5,t6,t7,t8,t9,t10,t11,t12,t13,t14,t15,t16,t17,t18,t19,t20,t21,t22,t23,t24,t25,t26,t27,t28,t29,t30,t31,t32,t33,t34,t35,t36,t37,t38,t39,t40,t41,t42,t43,t44,t45,t46,t47,t48,t49,t50,t51,t52,t53,t54,t55,t56,t57,t58,t59,t60,t61,t62,t63,t64,t65,t66,t67,t68,t69,t70,t71,t72,t73,t74,t75,t76,t77,t78,t79,t80,t81,t82,t83,t84,t85,t86,t87,t88,t89,t90,t91,t92,t93,t94,t95,t96,t97,t98,t99,t100,t101,t102,t103,t104,t105,t106,t107,t108,t109,t110,t111,t112,t113,t114,t115,t116,t117,t118,t119,t120,t121,t122,t123,t124,t125,t126,t127,t128,t129,t130,t131,t132,t133,t134,t135,t136,t137,t138,t139,t140,t141,t142,t143,t144,t145,t146,t147,t148,t149,t150,t151,t152,t153,t154,t155,t156,t157,t158,t159,t160,t161,t162,t163,t164,t165,t166,t167,t168,t169,t170,t171,t172,t173,t174,t175,t176,t177,t178,t179,t180,t181,t182,t183,t184,t185,t186,t187,t188,t189,t190,t191,t192,t193,t194,t195,t196,t197,t198,t199,t200,t201,t202,t203,t204,t205,t206,t207,t208,t209,t210,t211,t212,t213,t214,t215,t216,t217,t218,t219,t220,t221,t222,t223,t224,t225,t226,t227,t228,t229,t230,t231,t232,t233,t234,t235,t236,t237,t238,t239,t240,t241,t242,t243,t244,t245,t246,t247,t248,t249,t250,t251,t252,t253,t254,t255,t256,t257) INSERT_METHOD=FIRST;
|
||||
enable_query_log;
|
||||
select count(*) from t00;
|
||||
select count(*) from t00;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
show status like "Qcache_hits";
|
||||
delete from t256;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
drop table t1,t2,t3,t4,t5,t6,t7,t8,t9,t10,t11,t12,t13,t14,t15,t16,t17,t18,t19,t20,t21,t22,t23,t24,t25,t26,t27,t28,t29,t30,t31,t32,t33,t34,t35,t36,t37,t38,t39,t40,t41,t42,t43,t44,t45,t46,t47,t48,t49,t50,t51,t52,t53,t54,t55,t56,t57,t58,t59,t60,t61,t62,t63,t64,t65,t66,t67,t68,t69,t70,t71,t72,t73,t74,t75,t76,t77,t78,t79,t80,t81,t82,t83,t84,t85,t86,t87,t88,t89,t90,t91,t92,t93,t94,t95,t96,t97,t98,t99,t100,t101,t102,t103,t104,t105,t106,t107,t108,t109,t110,t111,t112,t113,t114,t115,t116,t117,t118,t119,t120,t121,t122,t123,t124,t125,t126,t127,t128,t129,t130,t131,t132,t133,t134,t135,t136,t137,t138,t139,t140,t141,t142,t143,t144,t145,t146,t147,t148,t149,t150,t151,t152,t153,t154,t155,t156,t157,t158,t159,t160,t161,t162,t163,t164,t165,t166,t167,t168,t169,t170,t171,t172,t173,t174,t175,t176,t177,t178,t179,t180,t181,t182,t183,t184,t185,t186,t187,t188,t189,t190,t191,t192,t193,t194,t195,t196,t197,t198,t199,t200,t201,t202,t203,t204,t205,t206,t207,t208,t209,t210,t211,t212,t213,t214,t215,t216,t217,t218,t219,t220,t221,t222,t223,t224,t225,t226,t227,t228,t229,t230,t231,t232,t233,t234,t235,t236,t237,t238,t239,t240,t241,t242,t243,t244,t245,t246,t247,t248,t249,t250,t251,t252,t253,t254,t255,t256,t257,t00;
|
||||
|
||||
SET @@global.query_cache_size=0;
|
@ -183,3 +183,20 @@ insert into t1 values (0,1,NULL,"aaa"), (1,1,NULL,"aaa"), (2,1,NULL,"aaa"),
|
||||
select a.id1, b.idnull from t1 as a, t1 as b where a.id2=1 and a.id1=1 and b.id1=a.idnull order by b.id2 desc limit 1;
|
||||
drop table t1;
|
||||
|
||||
#
|
||||
# BETWEEN problems
|
||||
#
|
||||
create table t1 (x int, y int, index(x), index(y));
|
||||
insert into t1 (x) values (1),(2),(3),(4),(5),(6),(7),(8),(9);
|
||||
update t1 set y=x;
|
||||
# between with only one end fixed
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between 7 and t1.y+0;
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= 7 and t2.x <= t1.y+0;
|
||||
# between with both expressions on both ends
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between t1.y-1 and t1.y+1;
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= t1.y-1 and t2.x <= t1.y+1;
|
||||
# equation propagation
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x between 0 and t1.y;
|
||||
explain select * from t1, t1 t2 where t1.y = 2 and t2.x >= 0 and t2.x <= t1.y;
|
||||
drop table t1;
|
||||
|
||||
|
46
mysql-test/t/rpl_do_grant.test
Normal file
46
mysql-test/t/rpl_do_grant.test
Normal file
@ -0,0 +1,46 @@
|
||||
# Test that GRANT and SET PASSWORD are replicated to the slave
|
||||
|
||||
source include/master-slave.inc;
|
||||
|
||||
# do not be influenced by other tests.
|
||||
connection master;
|
||||
delete from mysql.user where user='rpl_do_grant';
|
||||
delete from mysql.db where user='rpl_do_grant';
|
||||
flush privileges;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
# if these DELETE did nothing on the master, we need to do them manually on the
|
||||
# slave.
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
|
||||
# test replication of GRANT
|
||||
connection master;
|
||||
grant select on *.* to rpl_do_grant@localhost;
|
||||
grant drop on test.* to rpl_do_grant@localhost;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
show grants for rpl_do_grant@localhost;
|
||||
|
||||
# test replication of SET PASSWORD
|
||||
connection master;
|
||||
set password for rpl_do_grant@localhost=password("does it work?");
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
select password<>'' from mysql.user where user='rpl_do_grant';
|
||||
|
||||
# clear what we have done, to not influence other tests.
|
||||
connection master;
|
||||
delete from mysql.user where user='rpl_do_grant';
|
||||
delete from mysql.db where user='rpl_do_grant';
|
||||
flush privileges;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
# no need to delete manually, as the DELETEs must have done some real job on
|
||||
# master (updated binlog)
|
||||
flush privileges;
|
1
mysql-test/t/rpl_ignore_grant-slave.opt
Normal file
1
mysql-test/t/rpl_ignore_grant-slave.opt
Normal file
@ -0,0 +1 @@
|
||||
--replicate-wild-ignore-table=mysql.%
|
57
mysql-test/t/rpl_ignore_grant.test
Normal file
57
mysql-test/t/rpl_ignore_grant.test
Normal file
@ -0,0 +1,57 @@
|
||||
# Test that GRANT is not replicated to the slave
|
||||
# when --replicate-wild-ignore-table=mysql.%
|
||||
# In BUG#980, this test would _randomly_ fail.
|
||||
|
||||
source include/master-slave.inc;
|
||||
|
||||
# do not be influenced by other tests.
|
||||
connection master;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
# as these DELETE were not replicated, we need to do them manually on the
|
||||
# slave.
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
|
||||
# test non-replication of GRANT
|
||||
connection master;
|
||||
grant select on *.* to rpl_ignore_grant@localhost;
|
||||
grant drop on test.* to rpl_ignore_grant@localhost;
|
||||
show grants for rpl_ignore_grant@localhost;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
--error 1141 #("no such grant for user")
|
||||
show grants for rpl_ignore_grant@localhost;
|
||||
# check it another way
|
||||
select count(*) from mysql.user where user='rpl_ignore_grant';
|
||||
select count(*) from mysql.db where user='rpl_ignore_grant';
|
||||
|
||||
# test non-replication of SET PASSWORD
|
||||
# first force creation of the user on slave (because as the user does not exist
|
||||
# on slave, the SET PASSWORD may be replicated but silently do nothing; this is
|
||||
# not what we want; we want it to be not-replicated).
|
||||
grant select on *.* to rpl_ignore_grant@localhost;
|
||||
connection master;
|
||||
set password for rpl_ignore_grant@localhost=password("does it work?");
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
select password<>'' from mysql.user where user='rpl_ignore_grant';
|
||||
|
||||
# clear what we have done, to not influence other tests.
|
||||
connection master;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
delete from mysql.user where user='rpl_ignore_grant';
|
||||
delete from mysql.db where user='rpl_ignore_grant';
|
||||
flush privileges;
|
@ -4,6 +4,7 @@
|
||||
# We also check how the foreign_key_check variable is replicated
|
||||
|
||||
source include/master-slave.inc;
|
||||
source include/have_innodb.inc
|
||||
connection master;
|
||||
drop table if exists t1;
|
||||
create table t1(a int auto_increment, key(a));
|
||||
@ -22,8 +23,10 @@ connection master;
|
||||
#are replicated the same way
|
||||
drop table t1;
|
||||
drop table t2;
|
||||
create table t1(a int auto_increment, key(a));
|
||||
create table t2(b int auto_increment, c int, key(b));
|
||||
--disable_warnings
|
||||
create table t1(a int auto_increment, key(a)) type=innodb;
|
||||
create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) type=innodb;
|
||||
--enable_warnings
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
insert into t1 values (10);
|
||||
insert into t1 values (null),(null),(null);
|
||||
|
@ -6,9 +6,16 @@
|
||||
#
|
||||
# check if duplicate entries trigger an error (they should unless IGNORE or
|
||||
# REPLACE was used on the master) (bug 571).
|
||||
#
|
||||
# check if START SLAVE, RESET SLAVE, CHANGE MASTER reset Last_slave_error and
|
||||
# Last_slave_errno in SHOW SLAVE STATUS (1st and 3rd commands did not: bug 986).
|
||||
|
||||
source include/master-slave.inc;
|
||||
|
||||
connection slave;
|
||||
reset master;
|
||||
connection master;
|
||||
|
||||
create table t1(a int not null auto_increment, b int, primary key(a) );
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
|
||||
@ -24,6 +31,14 @@ sync_with_master;
|
||||
|
||||
select * from t1;
|
||||
select * from t3;
|
||||
# We want to be sure that LOAD DATA is in the slave's binlog.
|
||||
# But we can't simply read this binlog, because as the slave has not been
|
||||
# restarted for this test, the file_id is uncertain (would cause test
|
||||
# failures). So instead, we test if the binlog looks long enough to
|
||||
# contain LOAD DATA. That is, I (Guilhem) have done SHOW BINLOG EVENTS on my
|
||||
# machine, saw that the binlog is of size 964 when things go fine.
|
||||
# If LOAD DATA was not logged, the binlog would be shorter.
|
||||
show master status;
|
||||
|
||||
connection master;
|
||||
|
||||
@ -35,6 +50,9 @@ create table t1(a int, b int, unique(b));
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
|
||||
# See if slave stops when there's a duplicate entry for key error in LOAD DATA
|
||||
|
||||
insert into t1 values(1,10);
|
||||
|
||||
connection master;
|
||||
@ -44,3 +62,53 @@ save_master_pos;
|
||||
connection slave;
|
||||
# The SQL slave thread should be stopped now.
|
||||
wait_for_slave_to_stop;
|
||||
|
||||
# Skip the bad event and see if error is cleared in SHOW SLAVE STATUS by START
|
||||
# SLAVE, even though we are not executing any event (as sql_slave_skip_counter
|
||||
# takes us directly to the end of the relay log).
|
||||
|
||||
set global sql_slave_skip_counter=1;
|
||||
start slave;
|
||||
sync_with_master;
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
show slave status;
|
||||
|
||||
# Trigger error again to test CHANGE MASTER
|
||||
|
||||
connection master;
|
||||
set sql_log_bin=0;
|
||||
delete from t1;
|
||||
set sql_log_bin=1;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
# The SQL slave thread should be stopped now.
|
||||
wait_for_slave_to_stop;
|
||||
|
||||
# CHANGE MASTER and see if error is cleared in SHOW SLAVE STATUS.
|
||||
stop slave;
|
||||
change master to master_user='test';
|
||||
change master to master_user='root';
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
show slave status;
|
||||
|
||||
# Trigger error again to test RESET SLAVE
|
||||
|
||||
set global sql_slave_skip_counter=1;
|
||||
start slave;
|
||||
sync_with_master;
|
||||
connection master;
|
||||
set sql_log_bin=0;
|
||||
delete from t1;
|
||||
set sql_log_bin=1;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table t1;
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
# The SQL slave thread should be stopped now.
|
||||
wait_for_slave_to_stop;
|
||||
|
||||
# RESET SLAVE and see if error is cleared in SHOW SLAVE STATUS.
|
||||
stop slave;
|
||||
reset slave;
|
||||
--replace_result $MASTER_MYPORT MASTER_PORT
|
||||
show slave status;
|
||||
|
1
mysql-test/t/rpl_loaddata_rule_m-master.opt
Normal file
1
mysql-test/t/rpl_loaddata_rule_m-master.opt
Normal file
@ -0,0 +1 @@
|
||||
--binlog_ignore_db=test
|
18
mysql-test/t/rpl_loaddata_rule_m.test
Normal file
18
mysql-test/t/rpl_loaddata_rule_m.test
Normal file
@ -0,0 +1,18 @@
|
||||
# See if the master logs LOAD DATA INFILE correctly when binlog_*_db rules
|
||||
# exist.
|
||||
# This is for BUG#1100 (LOAD DATA INFILE was half-logged).
|
||||
|
||||
source include/master-slave.inc;
|
||||
connection slave;
|
||||
reset master;
|
||||
|
||||
# Test logging on master
|
||||
|
||||
connection master;
|
||||
# 'test' is the current database
|
||||
create database test2;
|
||||
create table t1(a int, b int, unique(b));
|
||||
use test2;
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
|
||||
show binlog events from 79; # should be nothing
|
||||
drop database test2;
|
1
mysql-test/t/rpl_loaddata_rule_s-slave.opt
Normal file
1
mysql-test/t/rpl_loaddata_rule_s-slave.opt
Normal file
@ -0,0 +1 @@
|
||||
--binlog_ignore_db=test
|
20
mysql-test/t/rpl_loaddata_rule_s.test
Normal file
20
mysql-test/t/rpl_loaddata_rule_s.test
Normal file
@ -0,0 +1,20 @@
|
||||
# See if the slave logs (in its own binlog, with --log-slave-updates) a
|
||||
# replicated LOAD DATA INFILE correctly when it has binlog_*_db rules.
|
||||
# This is for BUG#1100 (LOAD DATA INFILE was half-logged).
|
||||
|
||||
source include/master-slave.inc;
|
||||
connection slave;
|
||||
reset master;
|
||||
|
||||
connection master;
|
||||
# 'test' is the current database
|
||||
create table t1(a int, b int, unique(b));
|
||||
load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
|
||||
|
||||
# Test logging on slave;
|
||||
|
||||
save_master_pos;
|
||||
connection slave;
|
||||
sync_with_master;
|
||||
select count(*) from t1; # check that LOAD was replicated
|
||||
show binlog events from 79; # should be nothing
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user