Commit graph

1205 commits

Author SHA1 Message Date
Patrick Crews
eecf716a83 automerge 2009-02-20 08:40:28 -05:00
Patrick Crews
8c0befa291 auto merge 2009-02-20 08:37:07 -05:00
Georgi Kodinov
429e565f82 merged 5.0-bugteam -> 5.1-bugteam 2009-02-20 11:50:50 +02:00
Georgi Kodinov
39dc3623b3 Bug #42419: test suite fix
Moved the test case for the bug into a separate file (and restored the 
original innodb_mysql test setup).
Used the new wait_show_condition test macro to avoid the usage of sleep
2009-02-20 11:12:06 +02:00
Patrick Crews
783cae1831 merge 5.0 -> 5.1
These are only 5.0's fixes being merged.
5.1 and 6.0 Unix-removals will occur in different patches.
2009-02-19 18:24:25 -05:00
Patrick Crews
cc628c61fb Bug#38831: 11 test cases fail on Windows due to missing commands
Replaced Unix calls with mysql-test-run's built-in functions / SQL manipulation where possible.
Replaced error codes with error names as well.
Disabled two tests on Windows due to more complex Unix command usage
See Bug#41307, Bug#41308
2009-02-19 15:37:40 -05:00
Mikael Ronstrom
2548599cf7 Changed defaults when running mysql-test-run to ensure that
Pushbuild servers are not overloaded and test cases crash
due to overload of memory and disk.
2009-02-19 11:36:04 +01:00
Andrei Elkin
7497edf967 merging from the main to a local branch 2009-02-13 18:20:36 +02:00
Matthias Leich
1677de6ddd Merge actual tree -> local GCA tree, no conflicts 2009-02-13 13:06:50 +01:00
Horst Hunger
ac90fff18f Reviewed fix for bug#40882: Replaced "sleep 1" by wait_condition, added save/restore start values and closed open sessions. When trying to use "wait_for_query_to_succeed" a type has been fixed, also in "rename.test": Added session count and check and replaced error numbers. 2009-02-11 10:27:52 +01:00
Matthias Leich
c72c5495a3 Merge 5.0 -> 5.1 2009-02-10 11:23:47 +01:00
Matthias Leich
33445d8fb9 This belongs to the fix for
Bug#42003 tests missing the disconnect of connections <> default
second slice
Content:
1. wait_until_count_sessions.inc
   - One PB run of a test using this routine failed because
     5 seconds timeout were exceeded. Although I have some doubts
     if the assigned timeout was really too small, I increase the
     value to 10. We waste the additional 5 seconds only if the
     tests fails anyway.
   - Print the content of the PROCESSLIST if the poll routine fails
2. minor improvements of formatting
3. query_cache_notembedded:
   Activate the wait_until_count_sessions.inc routine which was
   unfortunately forgotten in the changeset before.
2009-02-09 21:52:40 +01:00
Andrei Elkin
98733e857e Bug #42451 setup_fake_relay_log makes an incorrect path on windows
Path composition for the relay log file that is stored into the relay index
file was not correct for windows.
mysql-test language does not provide primitives for portable path composition.
      
Fixed with storing only the basename part of the external "fake" relay log into
the relay index file.
Safety of removal of the dirname part of the relaylog is provided by logics of
`setup_fake_relay_log' that places the fake file into @@datadir directory.
2009-02-09 15:17:04 +02:00
Gleb Shchepa
3d543dd16d Bug #39265: fix for the bug 33699 should be reverted
Documented behaviour was broken by the patch for bug 33699
that actually is not a bug.

This fix reverts patch for bug 33699 and reverts the
UPDATE of NOT NULL field with NULL query to old
behavior.
2009-02-05 13:49:32 +04:00
Matthias Leich
2e36bc3d72 Merge of latest changesets into GCA tree 2009-02-04 12:07:52 +01:00
Matthias Leich
449bfbd7fa Merge 5.0 -> 5.1
+ fix wrong resultfile have_outfile.require
2009-02-03 14:45:17 +01:00
Matthias Leich
7da691c9f8 1. Slice of fix for Bug#42003 tests missing the disconnect of connections <> default
- If missing: add "disconnect <session>"
   - If physical disconnect of non "default" sessions is not finished
     at test end: add routine which waits till this happened
+ additional improvements like
  - remove superfluous files created by the test
  - replace error numbers by error names
  - remove trailing spaces, replace tabs by spaces
  - unify writing of bugs within comments
  - correct comments
  - minor changes of formatting
Modifications according to the code review are included.
Fixed tests:
grant2
grant3
lock_tables_lost_commit
mysqldump
openssl_1
outfile
2009-02-02 22:20:25 +01:00
Georgi Kodinov
aea9bcaa40 Fixed internal test check warnings in 5.1-bugteam. 2009-02-01 11:18:09 +02:00
Davi Arnaut
4157d0ca3b Fix test cases to preserve the state that existed before the
test case was executed.
2009-01-31 16:09:41 -02:00
Georgi Kodinov
3aec7ca415 merged 5.1-main -> 5.1-bugteam 2009-01-30 15:44:49 +02:00
Luis Soares
16a6158c47 merge: 5.1 -> 5.1-rpl-merge
conflicts:
  Text conflict in mysql-test/suite/sys_vars/r/rpl_max_binlog_size_func.result
  Text conflict in mysql-test/suite/sys_vars/t/rpl_max_binlog_size_func.test
2009-01-29 17:59:46 +01:00
Magnus Svensson
570efe1274 Bug#39849 ndb tests fail sporadically on pushbuild: "out of connection objects"
- Increase number of transaction objects available in ndbd
 - Most likely this is a timing related issue.
2009-01-29 15:22:02 +01:00
Magnus Svensson
3d1c85da1f WL#4189 mtr.pl v2
- First try LOAD DATA INFILE and fall back to LOAD DATA LOCAL INFILE if
   that fails.
2009-01-27 21:14:23 +01:00
Magnus Svensson
9a530951e0 WL#4198 mtr.pl v2
- Use empty escape char as not to convert "\test" to a tab + "est"
   when loading the servers .err file
2009-01-27 17:00:38 +01:00
Magnus Svensson
c1376aeae0 WL#4189 mtr.pl v2
- Bypass --secure-file-priv by loading the file from the client
   using LOAD DATA LOCAL INFILE
2009-01-27 16:35:52 +01:00
Magnus Svensson
d4c402db64 Merge 2009-01-27 15:10:15 +01:00
Magnus Svensson
5a1e073fc7 WL#4189 mtr.pl v2
- Make a rough filtering of the servers error log and write
   all suspicious warnings to $error_log.warnings
   The .warnings file is then examined more carefully by check_warnings.test
 - This will speed things up, doing all of this in a server running
   under valgrind takes far too long time.
2009-01-27 14:53:58 +01:00
Andrei Elkin
8afe7c2fe6 Bug #31240 load data infile replication between (4.0 or 4.1) and 5.1 fails
Fixing pb failures caused by mtr invokes the test with --tmpdir to which
there are  sensitive operations in the test
and setup_fake_relay_log.inc also needed --secure-file-priv for its own separate
directory.

Fixed with removing SELECT INTO OUTFILE and deploying --exec echo instead in the marco.
The test's opt file should contain --secure-file-priv=$MYSQL_TEST_DIR as the test
operations deal with files located in $MYSQL_TEST_DIR.
2009-01-27 13:33:30 +02:00
Luis Soares
5a7314099d merge: 5.1-rpl (with merge from main) -> 5.1-rpl 2009-01-26 17:06:39 +01:00
Magnus Svensson
2cc7e72aaa WL#4189 mtr.pl v2
- Suppress intentional safemalloc dump warnings
 - add fflush(stdout) to make sure that the "End safemalloc memory dump." marker is flushed.
2009-01-26 16:39:00 +01:00
Magnus Svensson
ee156bf0c5 WL#4189 mtr.pl v2
- rewrite "check warnings" to be faster by not creating a full join
   between error_log and suspicious_patterns while running REGEXP.
   Instead add a column to error_log that will be set to 1 to indicate
   a warning and run the 6 REGEXP's we have for suspicious lines as
   6 separate full table scans.
 - Remove the "suspicious_patterns" table from mtr db
 - Use 'xykls37' as separator when loading the error log, that line should
   hopefully never exist in a line that should be a warning
2009-01-26 15:20:33 +01:00
Magnus Svensson
e090e7fb3d Bug#42320 Read also "mysql.err-old" when checking the server for warnings
- disable check of .err-old until bug has been fixed
2009-01-24 18:31:41 +01:00
Magnus Svensson
097508292d WL#4198 mtr.pl v2
- fix typo, use "$old_log_error" as name when loading from .err-old file
2009-01-24 15:55:48 +01:00
Magnus Svensson
3ae3a5eb73 mtr.pl v2
- Add name of error log file to the erro log table to get better
   erorr message when warning is found
2009-01-24 12:09:36 +01:00
Magnus Svensson
3f15c920ae WL#4189 mtr.pl v2
- Rewrite "check testcase" to use LOAD DATA INFILE instead of 'load_file'
   in order to speed up the reading of the servers error log.
2009-01-24 10:37:40 +01:00
Luis Soares
14d4576bfe merge: 5.1 -> 5.1-rpl
conflicts:
  Text conflict in client/mysqltest.cc
  Text conflict in mysql-test/include/wait_until_connected_again.inc
  Text conflict in mysql-test/lib/mtr_report.pm
  Text conflict in mysql-test/mysql-test-run.pl
  Text conflict in mysql-test/r/events_bugs.result
  Text conflict in mysql-test/r/log_state.result
  Text conflict in mysql-test/r/myisam_data_pointer_size_func.result
  Text conflict in mysql-test/r/mysqlcheck.result
  Text conflict in mysql-test/r/query_cache.result
  Text conflict in mysql-test/r/status.result
  Text conflict in mysql-test/suite/binlog/r/binlog_index.result
  Text conflict in mysql-test/suite/binlog/r/binlog_innodb.result
  Text conflict in mysql-test/suite/rpl/r/rpl_packet.result
  Text conflict in mysql-test/suite/rpl/t/rpl_packet.test
  Text conflict in mysql-test/t/disabled.def
  Text conflict in mysql-test/t/events_bugs.test
  Text conflict in mysql-test/t/log_state.test
  Text conflict in mysql-test/t/myisam_data_pointer_size_func.test
  Text conflict in mysql-test/t/mysqlcheck.test
  Text conflict in mysql-test/t/query_cache.test
  Text conflict in mysql-test/t/rpl_init_slave_func.test
  Text conflict in mysql-test/t/status.test
2009-01-23 13:22:05 +01:00
Horst Hunger
37f9da15ac Changes to WL#4681 to merge to 5.1-main tree. 2009-01-22 11:14:16 +01:00
Serge Kozlov
abbc922b65 Bug#30128: The reason that sometimes events were executed because without STARTS
clause server fires immediately after creating event and time between create and delete
event sometimes is enough for firing. So adding STARTS clause moves first execution in
future after drop of event
1. Added STARTS clause for CREATE EVENT.
2. Updated result file.
2009-01-21 18:48:12 +03:00
He Zhenxing
63256ef955 BUG#41653 rpl_innodb_bug30888 fails sporadically on pushbuild: warning in log
In mtr.check_warnings, `text` was declares as type text, which is
64K, and when the server log grows larger than this, it would be
truncated, and then check_warnings was actually checking the 
error messages of a previous test and complain warnings.

This patch fixed the problem by change the type of `text` to
mediumtext, which is 16M.
2009-01-21 17:59:31 +08:00
Matthias Leich
33d2ae1512 Merge into actual tree 2009-01-13 16:42:37 +01:00
Matthias Leich
f557d37762 Merge of fix for bug
41111 events_bugs fails sporadically on pushbuild
into GCA tree
2009-01-13 14:39:04 +01:00
Davi Arnaut
a13eda38ae Post-merge fix for bug 37016: Update test case for row-based logging. 2009-01-12 10:48:33 -02:00
Sven Sandberg
3889dffcc0 BUG#37718: rpl.rpl_stm_mystery22 fails sporadically on pushbuild
Problem 1: The test waits for an error in the slave sql thread,
then resolves the error and issues 'start slave'. However, there
is a gap between when the error is reported and the slave sql
thread stops. If this gap was long, the slave would still be
running when 'start slave' happened, so 'start slave' would fail
and cause a test failure.
Fix 1: Made wait_for_slave_sql_error wait for the slave to stop
instead of wait for error in the IO thread. After stopping, the
error code is verified. If the error code is wrong, debug info
is printed. To print debug info, the debug printing code in
wait_for_slave_param.inc was moved out to a new file,
show_rpl_debug_info.inc.
Problem 2: rpl_stm_mystery22 is a horrible name, the comments in
the file didn't explain anything useful, the test was generally
hard to follow, and the test was essentially duplicated between
rpl_stm_mystery22 and rpl_row_mystery22.
Fix 2: The test is about conflicts in the slave SQL thread,
hence I renamed the tests to rpl_{stm,row}_conflicts. Refactored
the test so that the work is done in
extra/rpl_tests/rpl_conflicts.inc, and
rpl.rpl_{row,stm}_conflicts merely sets some variables and then
sourced extra/rpl_tests/rpl_conflicts.inc.
The tests have been rewritten and comments added.
Problem 3: When calling wait_for_slave_sql_error.inc, you always
want to verify that the sql thread stops because of the expected
error and not because of some other error. Currently,
wait_for_slave_sql_error.inc allows the caller to omit the error
code, in which case all error codes are accepted.
Fix 3: Made wait_for_slave_sql_error.inc fail if no error code
is given. Updated rpl_filter_tables_not_exist accordingly.
Problem 4: rpl_filter_tables_not_exist had a typo, the dollar
sign was missing in a 'let' statement.
Fix 4: Added dollar sign.
Problem 5: When replicating from other servers than the one named
'master', the wait_for_slave_* macros were unable to print debug
info on the master.
Fix 5: Replace parameter $slave_keep_connection by
$master_connection.
2009-01-09 15:12:31 +01:00
Matthias Leich
c6d81f8467 1. Fix for Bug#41111 events_bugs fails sporadically on pushbuild
2. Avoid bad effects of bug 41925 Warning 1366 Incorrect string value:
                                  ...  for column processlist.info
3. Add poll routines which ensure that subtests meet stable scenarios.
   This does not change the sense of the subtests.
2009-01-09 15:10:03 +01:00
Davi Arnaut
577e390ece Bug#37016: TRUNCATE TABLE removes some rows but not all
The special TRUNCATE TABLE (DDL) transaction wasn't being properly
rolled back if a error occurred during row by row deletion. The
error can be caused by a foreign key restriction imposed by InnoDB
SE and would cause the server to erroneously issue a implicit
commit.

The solution is to rollback the transaction if a truncation via row
by row deletion fails, otherwise commit. All effects of a TRUNCATE 
ABLE operation are rolled back if a row by row deletion fails.
2009-01-09 08:20:32 -02:00
Horst Hunger
8c29445872 Patch for bug#36875: Inserted review results. 2009-01-08 19:13:57 +01:00
He Zhenxing
ede652dbf4 Auto merge 2009-01-07 22:25:38 +08:00
Sven Sandberg
05d7673340 BUG#40482: server/mysqlbinlog crashes when reading invalid Incident_log_event
Problem: When an Incident_log_event contains a bad incident number on disk,
the server crashes with an assertion.
Fix: Don't validate input with assertions. Use errors.
2008-12-29 17:04:10 +01:00
He Zhenxing
c9c258959b BUG#41708 rpl.rpl_flushlog_loop fails in pushbuild producing non-deterministic result file
If server has not been initialized as a slave (by CHANGE MASTER), then
SHOW SLAVE STATUS will return an empty set, and caused the waiting for
Slave_IO_running or Slave_SQL_running to 'No' fail.

This patch fixed the problem by return immediately if slave is not
initialized in include/wait_for_slave_*_to_stop.inc.
2008-12-26 16:20:29 +08:00
He Zhenxing
e58f77bbf0 BUG#40704 main.events_restart fails sporadically in pushbuild: "server has gone away"
mysqltest command 'shutdown_server' is supposed to shutdown the server
and wait for it to be gone, and kill it when timeout. But because the
arguments passed to my_kill were in the wrong order, 'shutdown_server'
does not wait nor kill the server at all. So after 'shutdown_server',
the server is still running, and the server may still accepting
connections.
2008-12-25 17:53:24 +08:00
Sergey Petrunia
adf8aaca5b Merge: mysql-5.0-bugteam -> mysql-5.1-bugteam 2008-12-23 16:28:13 +03:00
Sergey Vojtovich
6291fa6f4f Merge. 2008-12-23 15:06:30 +04:00
Magnus Svensson
a03f5906f4 Bug #40704 main.events_restart fails sporadically in pushbuild: "server has gone away" 2008-12-19 16:48:31 +01:00
Horst Hunger
82c4b6e679 WL#4681: Took the system variable tests out of the main test suite, put them into "sys_vars", updated some reult files and tests. 2008-12-19 16:03:32 +01:00
Horst Hunger
0737be6a5a Final fix for bug#36773: Moved patch in 5.1 from rpl to bug team tree. 2008-12-17 14:38:02 +01:00
Sergey Vojtovich
7df22ce11e BUG#39746 - Debug flag breaks struct definition
(server crash)

Altering a table with fulltext index[es] which use
pluggable fulltext parser may cause server crash
in debug builds.

The problem was that ALTER TABLE code wrongly assigned
fulltext parser name.

Also fixed that altering a table with fulltext index[es]
leave stale fulltext parser locks, which prevent
fulltext parsers from being uninstalled after
ALTER TABLE.
2008-12-17 17:24:34 +04:00
Alfranio Correia
1fe215a7e5 auto merge 2008-12-13 19:48:19 +00:00
Alfranio Correia
3175a06a13 merge 5.1 --> 5.1-rpl 2008-12-13 19:42:12 +00:00
Andrei Elkin
2b761ffde9 Bug #41383 Test commit1_innodb fails with binlog-format=row
The test explicitly warned on existence of a bug in its 27th part.
The expected values of prepare and commit counters changed, corrected, by
fixes to bug#40221.
Notice, that binlog does not have to register for a statement with
the statement binlog-format because the statement rollback does not need
to do anything in that mode. It's not so with the ROW format which was
bug#40221 concern.

Fixed with correcting the expected values of the mentioned counters and
explained that with comments in the test.
2008-12-12 14:52:20 +02:00
Serge Kozlov
de7be3a4ed Bug#41186: Possible reason of bug is waiting any sql error on slave instead
exact number of error. The patch does following:
1) Add new parameter $slave_sql_errno for wait_for_slave_sql_error.inc
2) Add waiting error 1062 (Duplicate PK) for slave SQL thread in test case.
2008-12-12 14:40:22 +03:00
Magnus Svensson
7434596b84 Bug#40636 falcon_bug_28095 test fails with "Server failed to restart" 2008-12-10 19:40:27 +01:00
Luis Soares
c5d7c038a3 push to 5.1-buteam tree. 2008-12-10 10:51:43 +00:00
Magnus Svensson
2790aceb35 Merge 2008-12-05 22:15:52 +01:00
Magnus Svensson
89f28a77c4 Bug#41061 analyze-warnings times out sporadically in pushbuild 2008-12-05 19:24:10 +01:00
Luis Soares
0c9aaecc7f BUG#38826 Race in MYSQL_LOG::purge_logs is impossible to debug in production
BUG#39325 Server crash inside MYSQL_LOG::purge_first_log halts replicaiton

The patch reverses the order of the purging and updating events for log and
relay-log.info/index files respectively.

This solves the problem of having holes caused by crashes happening between updating
info/index files and purging logs.

This patch also contains an aditional test case for testing the crashing before purge logs.
      
NOTE1: This is a combined patch for BUG#38826 and BUG#39325. This patch is based on
bugteam tree and takes into account reviewers suggestions.

NOTE2: Merge from 5.0-bugteam
2008-12-04 14:07:56 +00:00
Horst Hunger
7cb0aa4ccf Fix for Bug#37810:
The "show status" may be received by the server in a startup state, where it only can reject the statement, so that the client then react with 2013.
So, adding 2013 to the list of errors may help, as the "show status" will be repeated then.
2008-12-02 12:34:52 +01:00
Horst Hunger
1feb81bf33 Fix for Bug#36876:
The minimum value differs depending on the OS and mysqld build, so that the test fail spradically.
The check of this value has been changed from check of concrete values to the check of a range that is near by the expected value.
2008-12-02 11:05:56 +01:00
Patrick Crews
09e1f238e4 Merge 5.0->5.1 2008-11-24 16:56:48 -05:00
Patrick Crews
6d31576682 Bug#40866: mysql-test-run's check of tests provides false failures due to timestamp
Altering how MTR checks global variable status to exclude timestamp
Changed SQL statements to update style.
2008-11-24 16:53:32 -05:00
He Zhenxing
560a9d15a1 BUG#40707 rpl_multi_engine fails sporadically in pushbuild
If before running test rpl_mulit_engin, the mysqltest1 database exists
on master but not exists on slave, then the following statement:

  create database if not exists mysqltest1;

would not be logged to binary log, and so the database would not be
created on slave. This would cause the test to fail and reporting 
mysqltest1 database not existed on slave.

This patch fixed this problem by not using a different database for
the whole test, just use the default test database, there is no reason
why a seperate database is used for this test.
2008-11-24 14:57:23 +08:00
Sven Sandberg
78a3abeced BUG#38350: Many tests don't clean up after themselves on exit.
Problem: Many test cases don't clean up after themselves (fail
to drop tables or fail to reset variables). This implies that:
(1) check-testcase in the new mtr that currently lives in
5.1-rpl failed. (2) it may cause unexpected results in
subsequent tests.
Fix: make all tests clean up.
Also: cleaned away unnecessary output in rpl_packet.result
Also: fixed bug where rpl_log called RESET MASTER with a running
slave. This is not supposed to work.
Also: removed unnecessary code from rpl_stm_EE_err2 and made it
verify that an error occurred.
Also: removed unnecessary code from rpl_ndb_ctype_ucs2_def.
2008-11-13 20:19:00 +01:00
Andrei Elkin
2618337eb6 merging 5.1 -> 5.1 rpl. 3 of 4 conflicts are resolved similarly to 6.0->6.0-rpl merging.
mysql_upgrade results changed due to the error messesge of mysqlcheck has changed.
2008-11-12 19:51:47 +02:00
Matthias Leich
ddf21d6f9d Remove files which were created during an upmerge
where it was forgotten to remove them.
2008-11-06 18:51:00 +01:00
Mats Kindahl
1f29c52581 Merging 5.1 main into 5.1-rpl 2008-10-23 21:27:09 +02:00
Sven Sandberg
90de05d0e6 BUG#39853: lowercase_table3 fails on powermacg5 in rpl tree
Problem: during a refactoring of mtr, a pattern for suppressing a warning from lowercase_table3 was lost.
Fix: re-introduce the suppression.
Problem 2: suppression was misspelt as supression. Fixed by adding a p.
2008-10-13 20:33:08 +02:00
Georgi Kodinov
b437a0863b merged 5.1-5.1.29-rc -> 5.1-bugteam 2008-10-07 18:19:32 +03:00
Mats Kindahl
2974607a4b Merging 5.1 main into 5.1-rpl. 2008-10-06 10:27:36 +02:00
Georgi Kodinov
7a05a4f5dc Bug #39812: Make statement replication default for 5.1 (to match 5.0)
Make STMT replication default for 5.1.
Add a default of MIXED into the config files
Fix the tests that needed MIXED replication mode.
2008-10-03 15:24:19 +03:00
Georgi Kodinov
f80fbfa282 merge of bug #37943 5.0-bugteam -> 5.1-bugteam 2008-10-01 19:49:59 +03:00
Patrick Crews
99abc81c5f Merge 5.0 -> 5.1 2008-09-30 15:32:35 -04:00
Magnus Svensson
bffebb9cbc Change typo . -> , 2008-09-20 17:00:05 +03:00
Patrick Crews
2a419a5627 Bug#38311 Some tests use 'rm' which is not portable
Substituted use of MTR's remove_file function in the tests
Started with 5.0 tree and will clean up any offenders discovered during upmerge.
2008-09-20 02:21:28 -04:00
Georgi Kodinov
7f1734eb22 merged 5.1.29-rc into 5.1-bugteam 2008-09-10 12:44:21 +03:00
Magnus Svensson
b76b046daa WL#4350 Add missing 'exit' 2008-09-09 09:49:58 +02:00
He Zhenxing
4299844ad5 Postfix of tests after merge 2008-09-06 12:49:43 +08:00
He Zhenxing
6e86e05823 Merge 5.1 main -> 5.1-rpl 2008-09-06 08:51:17 +08:00
He Zhenxing
e132e26b97 Use MyISAM for all tables created in mtr_warnings.sql 2008-09-04 11:26:12 +08:00
Martin Hansson
a43242ea6d Bug#36086: SELECT * from views don't check column grants
This patch also fixes bugs 36963 and 35600.
                      
- In many places a view was confused with an anonymous derived
  table, i.e. access checking was skipped. Fixed by introducing a
  predicate to tell the difference between named and anonymous
  derived tables.
                      
- When inserting fields for "SELECT * ", there was no 
  distinction between base tables and views, where one should be
  made. View privileges are checked elsewhere.
2008-09-03 16:45:40 +02:00
Georgi Kodinov
cac06c5ea7 On behalf of Jasonh: fix for a failing test case of bug 37051 2008-08-28 18:15:54 +03:00
Mats Kindahl
42339e0fc9 Merging 5.1 into 5.1-rpl-merge 2008-08-27 20:52:44 +02:00
He Zhenxing
90b072cbde Fix cherry picking patch of BUG#37051 2008-08-26 20:11:56 +08:00
He Zhenxing
78e1f5d523 Cherry picking patch for BUG#37051 2008-08-26 18:01:49 +08:00
Alexander Barkov
7e63f13834 Merging 5.1-rpl-testfixes to 5.1 main. 2008-08-26 11:55:30 +05:00
Andrei Elkin
3a1c50bc53 Bug #36968 rpl_temporary_errors.test produces warning in pushbuild
Backporting fixes to 5.1 from 6.0.
2008-08-25 15:40:44 +03:00
Alexander Barkov
949a87afbe Additional fix for bug#31455
Fixing non-deterministic test results:
the number of spaces in FLOAT/DOUBLE output could 
vary between different platforms.
2008-08-25 15:29:59 +05:00
Alexander Barkov
88e7b1381e Additional ffix for bug#31455
- fixing double problem on big endian machines
- modifying regex_replace to replace negative numbers
  Previously only positive numbers where replaced.
2008-08-25 12:58:29 +05:00
Alexander Barkov
e3adf28d08 Additional fix for bug#31455
Getting rid of non-deterministic results of sprintf("%-20g").
Displaying only 3 digits after decimal dot.
2008-08-22 15:14:30 +05:00
Alexander Barkov
056a64e808 Additional fix for bug#31455
Removing server version with regex_replace
to avoid non-determenistic test results.
2008-08-22 09:22:16 +05:00
Alexander Barkov
b25b2b2411 Additional fix for bug#31455 (rpl decoder)
- Implementing --base64-format=decode-rows, to display
  SQL-alike decoded row events without their BINLOG statements.
- Adding --base64-format=decode-rows into tests when
  calling mysqlbinlog to avoid non-deterministic results
- Removing resetting of last_table_id in "RESET MASTER",
  which appeared to be dangerous.
2008-08-21 16:47:23 +05:00
Alexander Barkov
a57aa6bb75 Bug#31455 mysqlbinlog don't print user readable info about RBR events
Implementing -v command line parameter to mysqlbinlog
to decode and print row events.

mysql-test/include/mysqlbinlog_row_engine.inc
mysql-test/r/mysqlbinlog_row.result
mysql-test/r/mysqlbinlog_row_big.result
mysql-test/r/mysqlbinlog_row_innodb.result
mysql-test/r/mysqlbinlog_row_myisam.result
mysql-test/r/mysqlbinlog_row_trans.result
mysql-test/t/mysqlbinlog_row.test
mysql-test/t/mysqlbinlog_row_big.test
mysql-test/t/mysqlbinlog_row_innodb.test
mysql-test/t/mysqlbinlog_row_myisam.test
mysql-test/t/mysqlbinlog_row_trans.test
  Adding tests 

client/Makefile.am
  Adding new files to symlink
  
client/mysqlbinlog.cc
  Adding -v option

sql/log_event.cc
  Impelentations of the new methods

sql/log_event.h
  Declaration of the new methods and member

sql/mysql_priv.h
  Adding new function prototype

sql/rpl_tblmap.cc
  Adding pre-processor conditions 

sql/rpl_tblmap.h
  Adding pre-processor conditions 

sql/rpl_utility.h
  Adding pre-processor conditions 

sql/sql_base.cc
  Adding reset_table_id_sequence() function.

sql/sql_repl.cc
  Resetting table_id on "RESET MASTER"
  
.bzrignore
  Ignoring new symlinked files
2008-08-20 19:06:31 +05:00
Chad MILLER
6d6b9ffec8 Bug#21579 - innodb_concurrent random failures with varying differences
Due to unknown changes the test failed in some ways.

Fixed by checking the test case in detail, commenting the expected behavior,
and fixing error directives.

In the course of the analyze unneeded get_lock()/release_lock() use,
unneeded send/reap use, and unneeded sleeps were removed. The lock wait
timeout was reduced to 1 second, so that this is no big-test any more.

The test was split into two parts, one running the tests with
--innodb_locks_unsafe_for_binlog, the other part without.
The main part (include/concurrent.inc) conditionally expects
lock wait timeouts based on the value of the system variable
innodb_locks_unsafe_for_binlog.

The major part of the patch comes from Kristofer Pettersson.

(Chad queues this patch on demand by Trudy/Davi.)
2008-08-15 14:48:14 -04:00
Davi Arnaut
fd793526b4 Merge from mysql-5.1 main. 2008-08-15 12:58:19 -03:00
He Zhenxing
c6c2e66c67 Merge 5.1-rpl-testfixes -> 5.1-rpl 2008-08-14 17:38:22 +08:00
He Zhenxing
646c509b18 Auto merge from mysql-5.1 main 2008-08-14 14:27:18 +08:00
Matthias Leich
b14c8930c0 Improve the testcases for Bug 12093 in ps_ddl.test
Details:
- add subtest with drop unrelated view
- rearrange existing tests so that a distinction
  between drop procedure and drop function effects
  is possible
2008-08-13 21:42:21 +02:00
Mattias Jonsson
f84bf0077d manual merge of bug#37402 2008-08-12 12:26:23 +02:00
Magnus Svensson
00560ac3d4 Add analyze-timeout.test 2008-08-09 11:33:59 +02:00
Magnus Svensson
aceba783f8 Improve printout for 'found warnings' and add an exit to please mysqltest 2008-08-09 11:29:35 +02:00
Magnus Svensson
66b42a13f2 Make events_restart more stable by waiting for the server to be stopped before starting it again 2008-08-09 11:16:12 +02:00
Magnus Svensson
69f9ec281d Merge 2008-08-08 20:10:43 +02:00
He Zhenxing
2441ec8770 Wait for slave to stop before set skip counter 2008-08-06 18:52:15 +08:00
He Zhenxing
337029cae2 Auto merge 2008-08-06 18:41:27 +08:00
Magnus Svensson
ed8bc526ae Merge 2008-08-04 22:25:45 +02:00
Magnus Svensson
39ad2dc05a Bug #38181 Please print more debug info when tests fail 2008-08-04 21:54:44 +02:00
Magnus Svensson
798590b798 Bug #32307 mysqltest - does not detect illegal if syntax 2008-08-04 12:38:50 +02:00
Sven Sandberg
73e253370b merged 5.1 main to 5.1-rpl
manually resolved conflicts:
Text conflict in client/mysqltest.c
Contents conflict in mysql-test/include/have_bug25714.inc
Text conflict in mysql-test/include/have_ndbapi_examples.inc
Text conflict in mysql-test/mysql-test-run.pl
Text conflict in mysql-test/suite/parts/inc/partition_check_drop.inc
Text conflict in mysql-test/suite/parts/inc/partition_layout.inc
Text conflict in mysql-test/suite/parts/inc/partition_layout_check1.inc
Text conflict in mysql-test/suite/parts/inc/partition_layout_check2.inc
Text conflict in mysql-test/suite/parts/r/partition_alter1_1_2_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_alter1_1_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_alter1_2_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_alter2_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_alter3_innodb.result
Text conflict in mysql-test/suite/parts/r/partition_alter3_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_basic_innodb.result
Text conflict in mysql-test/suite/parts/r/partition_basic_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_basic_symlink_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_engine_myisam.result
Text conflict in mysql-test/suite/parts/r/partition_syntax_myisam.result
Text conflict in mysql-test/suite/rpl_ndb/t/disabled.def
Text conflict in mysql-test/t/disabled.def
2008-08-04 07:04:47 +02:00
He Zhenxing
e6ac8830a4 BUG#37051 Replication rules not evaluated correctly
The problem of this bug is that we need to get the list of tables
to be updated for a multi-table update statement, which requires to
open all the tables referenced by the statement and resolve all
the fields involved in update in order to figure out the list of
tables for update. However if there are replicate filter rules,
some tables might not exist on slave and result in a failure
before we could examine the filter rules.

I think the whole problem can not be solved on slave alone,
the master must record and send the information of tables
involved for update to slave, so that the slave do not need to
open all the tables referenced by the multi-table update statement to
figure out which tables are involved for update.

So a status variable is added to Query_log event to store the
value of table map for update on master. And on slave, it will
try to get the value of this variable and use it to examine
filter rules without opening any tables on slave, if this values
is not available, the old approach is used and thus the bug will
still occur for when replicating from old masters.
2008-07-31 14:24:27 +08:00
Sven Sandberg
1562db45f1 merge 5.1 main -> 5.1-rpl-testfixes
all changes automerged without conflicts
2008-07-29 19:55:46 +02:00
He Zhenxing
b1252a7ccf Rmove RESET MASTER from have_log_bin.inc because it can cause some
test to stall for slave_net_timeout and cause some test case fail
2008-07-28 15:15:20 +08:00
Sven Sandberg
b6545b30fa BUG#37717: rpl.rpl_stm_until 'stmt' fails sporadically on pushbuild
Problem: After START SLAVE, the Slave_IO_Status column of
SHOW SLAVE STATUS goes from No to Yes asynchronously. That
caused sporadic failures on pushbuild in rpl_stm_until since
the test contains SHOW SLAVE STATUS right after START SLAVE.
Fix: Wait until Slave_IO_Status becomes Yes after each
START SLAVE.
2008-07-23 13:23:52 +02:00
Horst Hunger
62b41dddd9 fix of bug#37708: removed a forgotten include file. 2008-07-23 08:51:04 +02:00
Horst Hunger
497c97905e 2008-07-22 18:56:50 +02:00
Sven Sandberg
e5d1324d80 BUG#38178: rpl_loaddata_map fails sporadically in pushbuild
Problem: master binlog has 'create table t1'. Master binlog
was removed before slave could replicate it. In test's cleanup
code, master did 'drop table t1', which caused slave sql
thread to stop with an error since slave sql thread did not
know about t1.
Fix: t1 is just an auxiliary construction, only needed on
master. Hence, we turn off binlogging before t1 is created,
drop t1 as soon as we don't need it anymore, and then turn
on binlogging again.
2008-07-18 13:34:19 +02:00
Georgi Kodinov
7f16afccfb merge of bug #37830 to 5.1 2008-07-17 18:51:24 +03:00
Horst Hunger
c3c4c6b54c Fix for bug#38164. Removed test of values larger than max int for 32 bits. 2008-07-17 11:03:17 +02:00
Sven Sandberg
e14d0f10c2 BUG#38127: main.mysqlbinlog_base64 fails sporadically on pushbuild
Problem: mysqlbinlog_base64 fails because the binlog contains
traces from previous test cases.
Fix: Make have_log_bin reset the master's binlog.
2008-07-16 11:50:11 +02:00
Sven Sandberg
679c7aca59 BUG#37733: rpl.rpl_flushlog_loop 'row' fails sporadically on pushbuild
Post-push fix. The previous patch did 'reset master' at the wrong place.
2008-07-15 12:01:54 +02:00
Sven Sandberg
af598eccdc BUG#37975: wait_for_slave_* should increase the timeout
Post-push fixes: I forgot to include the new files
start_slave.inc and stop_slave.inc in the previuos push.
2008-07-14 11:41:23 +02:00
Mattias Jonsson
295fc5834a Bug#37402: Mysql cant read partitioned table with capital letter in the name
Problem was that ha_partition had HA_FILE_BASED flag set
(since it uses a .par file), but after open it uses the first partitions
flags, which results in different case handling for create and for
open.

Solution was to change the underlying partition name so it was consistent.
(Only happens when lower_case_table_names = 2, i.e. Mac OS X and storage
engines without HA_FILE_BASED, like InnoDB and Memory.)

(Recommit after adding rename of check_lowercase_names to
get_canonical_filename, and moved it from handler.h to mysql_priv.h)

NOTE: if a mixed case name for a partitioned table was created when
lower_case_table_name = 2 it should be renamed or dropped before using
the updated version (See bug#37402 for more info)
2008-07-11 01:14:13 +02:00
Sven Sandberg
78c8bfdddf BUG#37975: wait_for_slave_* should increase the timeout
Problem 1: tests often fail in pushbuild with a timeout when waiting
for the slave to start/stop/receive error.
Fix 1: Updated the wait_for_slave_* macros in the following way:
- The timeout is increased by a factor ten
- Refactored the macros so that wait_for_slave_param does the work for
the other macros.
Problem 2: Tests are often incorrectly written, lacking a
source include/wait_for_slave_to_[start|stop].inc.
Fix 2: Improved the chance to get it right by adding
include/start_slave.inc and include/stop_slave.inc, and updated tests
to use these.
Problem 3: The the built-in test language command
wait_for_slave_to_stop is a misnomer (does not wait for the slave io
thread) and does not give as much debug info in case of failure as
the otherwise equivalent macro
source include/wait_for_slave_sql_to_stop.inc
Fix 3: Replaced all calls to the built-in command by a call to the
macro.
Problem 4: Some, but not all, of the wait_for_slave_* macros had an
implicit connection slave. This made some tests confusing to read,
and made it more difficult to use the macro in circular replication
scenarios, where the connection named master needs to wait.
Fix 4: Removed the implicit connection slave from all
wait_for_slave_* macros, and updated tests to use an explicit
connection slave where necessary.
Problem 5: The macros wait_slave_status.inc and wait_show_pattern.inc
were unused. Moreover, using them is difficult and error-prone.
Fix 5: remove these macros.
Problem 6: log_bin_trust_function_creators_basic failed when running
tests because it assumed @@global.log_bin_trust_function_creators=1,
and some tests modified this variable without resetting it to its
original value.
Fix 6: All tests that use this variable have been updated so that
they reset the value at end of test.
2008-07-10 18:09:39 +02:00
Mats Kindahl
87d1603700 Ensuring that master and slave both issue a RESET MASTER and RESET SLAVE
when resetting replication tests.  If not, circular replication setups
will leave cruft in the slaves binary log.
2008-07-09 14:34:00 +02:00
Mats Kindahl
c416c0e14c Patch to remove extreneous printout. 2008-07-08 19:59:50 +02:00
Mats Kindahl
f7c41e2f1d Bug #37939 rpl_row_stop_middle_update fails sporadically on pushbuild
Bug #37940    rpl_dual_pos_advance fails sporadically on pushbuild,fail wait_for_slave_to_stop
Bug #37941    rpl_flushlog_loop fails sporadically on pushbuild
  
Several tests fail when waiting for the slave to stop in what
appears to be timeouts caused by a timeout value set to low. 
This causes false failures when the servers are loaded.
  
In order to try to avoid false negatives, we increase the
timeout 10 times and also print some more information in the
event that the slave fails to stop when expected to.
  
We add a printout of the current processes running to be able
to see if any process have been executing for an unexpectedly
long time, and also print the binlog events at the position
indicated by SHOW SLAVE STATUS.
2008-07-08 18:21:02 +02:00
Sven Sandberg
56dd330e05 merged fix for bug#37373 into 5.1-rpl 2008-07-07 18:24:04 +02:00
Sven Sandberg
500aa80db3 Merge 5.1 -> 5.1-rpl 2008-07-06 19:07:30 +02:00
Sven Sandberg
bb63582ed9 BUG#37373: rpl_ndb_transaction fails sporadically in pb on sol10-amd64-a and sol10-sparc-a
Problem: rpl_ndb_transaction fails because it assumes nothing
is written to the binlog at a certain point. However, ndb may
binlog updates in ndb system tables at a nondeterministic
time point after an ndb table update has been committed.
Fix: break the test into two. rpl_ndb_transaction still does
the ndb updates needed by the first half of the test. The new
test case rpl_bug26395 includes the part that assumes nothing
more will be written to the binlog.
2008-07-06 12:53:25 +02:00
Chad MILLER
124dea7f24 Merge from 5.0. Add new 5.1 files. Drop bdb. 2008-07-04 14:48:25 -04:00
Chad MILLER
43ba41548e Bug#30563: Is not possible to create rpl_ or innodb test if needed \
to use ANSI_QUOTES

Make all have_* tests universally safe by using ANSI quotes.
2008-07-04 12:41:27 -04:00
Matthias Leich
81e7bd8679 Upmerge 5.0 -> 5.1 2008-06-25 19:01:17 +02:00
Matthias Leich
69a1c78eba Fix for
Bug#37492 timing bug in subselect.test
+ similar weaknesses found during testing
+ replace error numbers by error names
2008-06-25 16:59:38 +02:00
Davi Arnaut
c20188e011 Bug#33873: Fast ALTER TABLE doesn't work with multibyte character sets
The problem was that when comparing tables for a possible
fast alter table, the comparison was being performed using
the parsed information and not the final definition.
      
The solution is to use the possible final table layout to
compare if a fast alter is possible or not.
2008-06-17 11:12:21 -03:00
Magnus Svensson
3d34d34c88 Merge 5.1->5.1-rpl
Fix paths and name of a few files to make it work with new mtr.pl
2008-05-30 11:12:07 +02:00
gkodinov/kgeorge@magare.gmz
b98922b7cc Merge magare.gmz:/home/kgeorge/mysql/work/B36011-take2-5.0-bugteam
into  magare.gmz:/home/kgeorge/mysql/work/B36011-5.1-bugteam
2008-05-16 19:03:50 +03:00
hhunger@hh-nb.hungers
3b19417649 Merge hh-nb.hungers:/work/merge/mysql-5.1-bugteam
into  hh-nb.hungers:/work/merge/mysql-5.1-36522
2008-05-09 13:06:02 +02:00
thek@adventure.(none)
92724ecb3d Bug#35997 Event scheduler seems to let the server crash, if it is embedded.
Missing file: include/is_embedded.inc

This file was left out of the initial changeset by misstake.
2008-05-09 10:26:06 +02:00
hhunger@hh-nb.hungers
313e6c7757 Fixes for bug#36522. 2008-05-08 20:13:39 +02:00
aelkin/andrei@mysql1000.dsl.inet.fi
e1d1248d60 Merge aelkin@bk-internal.mysql.com:/home/bk/mysql-5.1-bugteam
into  mysql1000.dsl.inet.fi:/home/andrei/MySQL/BARE/mysql-5.1-bugteam
2008-05-05 13:28:07 +03:00
gkodinov/kgeorge@magare.gmz
3c469aaaa7 Merge bk-internal:/home/bk/mysql-5.1
into  magare.gmz:/home/kgeorge/mysql/work/merge-5.1-bugteam
2008-05-01 13:25:38 +03:00
aelkin/andrei@mysql1000.dsl.inet.fi
9afdba04d6 Bug #36435 rpl_events uses non-deterministic check
Select of the test could not perform deterministically, because the table remains to be 
updatable by the running event handler.

Fixed with changing verification to use a logical values instead of comparison 
with a pre-recorded results.
2008-04-30 21:41:50 +03:00
davi@endora.local
9045798dea Merge bk-internal.mysql.com:/home/bk/mysql-5.1-bugteam
into  mysql.com:/Users/davi/mysql/mysql-5.1-bugteam
2008-04-30 10:15:32 -03:00
davi@mysql.com/endora.local
a454190f0d Backport kostja's fix for Bug#32724 "innodb_mysql.test fails randomly".
Enable back the disabled test case.
2008-04-29 00:03:19 -03:00
skozlov/ksm@mysql.com/virtop.(none)
9ac996e16e WL#3754, circular replication tests 2008-04-25 20:54:42 +04:00
skozlov/ksm@virtop.(none)
b3a5ca2649 Merge skozlov@bk-internal.mysql.com:/home/bk/mysql-5.1-new-rpl
into  mysql.com:/home/ksm/mysql/WL3754/commit-mysql-5.1-new-rpl
2008-04-25 00:47:36 +04:00
skozlov/ksm@mysql.com/virtop.(none)
001d68a2e0 WL#3754, testing circular replication 2008-04-25 00:41:04 +04:00
msvensson@pilot.mysql.com
c6aca99321 Allow 2002 as a valid error for connect fails. It's common on windows where
we don't use Unix domin sockets for connection to server
2008-04-24 14:16:32 +02:00
msvensson@pilot.mysql.com
0c3165feb3 Add warning supressions for bug#31590 and bug#26402 that gort lost when
moving the supressions from perl to SQL
2008-04-24 13:26:28 +02:00
msvensson@pilot.mysql.com
206e1dc63e Rename "shutdown" -> "send_shutdown" and "kill_server" to "shutdown_server"
Fix warnings
2008-04-21 17:39:13 +02:00
msvensson@pilot.mysql.com
2ba565cde7 Add "kill_server", call shutdown on current conneciton and then make sure
the server dissapears
Check return code of 'mysql_ping'
Add "shutdown", call 'mysql_shutdown' on the current connection
2008-04-21 14:16:54 +02:00
skozlov/ksm@mysql.com/virtop.(none)
9198608e8a Fix for main.events_restart 2008-04-20 22:24:00 +04:00
hhunger@hh-nb.hungers
f6aa788f26 Merge hh-nb.hungers:/work/trees/mysql-5.1-build-src-clean
into  hh-nb.hungers:/work/merge/mysql-5.1-build
2008-04-15 15:56:11 +02:00
hhunger@hh-nb.hungers
679b907964 Third set of fixes for bug#35988. 2008-04-15 15:44:11 +02:00
msvensson@pilot.mysql.com
596aca33f5 Set mysqladmin shutdown timeout to 60 seconds 2008-04-14 14:25:57 +02:00
hhunger@hh-nb.hungers
88451eacfd Merge hh-nb.hungers:/work/trees/mysql-5.1-build-src-clean
into  hh-nb.hungers:/work/merge/mysql-5.1-build
2008-04-10 18:32:37 +02:00
hhunger@hh-nb.hungers
afd90d6166 System variable tests delivered by Folio3 (see WL4288). 2008-04-10 15:14:28 +02:00
msvensson@pilot.mysql.com
0ceb3244e5 Improve readability of check testcase data and add order by 2008-04-09 22:06:02 +02:00
msvensson@shellback.(none)
f4661f34a6 Fix return code from check-warnings to indicate if test failed or not.
No more string matching
2008-04-09 14:38:42 +02:00
msvensson@shellback.(none)
d348362d24 Turn on --check-testcase by default
Don't log check_warnings to binlog
2008-04-09 12:27:39 +02:00
msvensson@shellback.(none)
98ab99f9ec Merge pilot:mysql/mysql-5.1-rpl
into  shellback.(none):/home/msvensson/mysql/mysql-5.1-new-rpl
2008-04-09 09:55:30 +02:00
msvensson@shellback.(none)
3253a936da Update comment to reflect reality 2008-04-09 09:44:08 +02:00
msvensson@shellback.(none)
7fcbf9f21e Mereg events_restart_phase* to events_restart 2008-04-09 09:43:20 +02:00
msvensson@pilot.mysql.com
456b16d834 Merge pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-mtr-warnings2
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-rpl
2008-04-08 16:52:15 +02:00
msvensson@pilot.mysql.com
433c1c3d7b Check warnings in servers error log as part of test case 2008-04-08 16:51:26 +02:00
msvensson@pilot.mysql.com
17a5ef3984 Merge bk-internal:/home/bk/mysql-5.1-rpl
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-rpl
2008-04-03 21:51:26 +02:00
msvensson@pilot.mysql.com
a011d27cf9 Merge pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-rpl
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-mtr
2008-04-03 11:50:43 +02:00
skozlov/ksm@virtop.(none)
8f95b8d230 Merge skozlov@bk-internal.mysql.com:/home/bk/mysql-5.1-new-rpl
into  mysql.com:/home/ksm/mysql/bugs/commit-mysql-5.1-new-rpl-bug30128
2008-04-03 13:08:03 +04:00
skozlov/ksm@mysql.com/virtop.(none)
fd8d82aed7 Bug#30128, The reason that sometimes events were executed because without STARTS clause server fires immediately after creating event and
time between create and delete event sometimes is enough for firing. So adding STARTS clause moves first execution in future after drop of event.
2008-04-02 19:41:49 +04:00
mats@mats-laptop.(none)
984ea1a3cb Fixes to eliminate some race conditions in tests. 2008-04-01 14:40:23 +02:00
gkodinov/kgeorge@magare.gmz
69b7c5fee9 Merge bk-internal:/home/bk/mysql-5.1-bugteam
into  magare.gmz:/home/kgeorge/mysql/work/merge-build-5.1-bugteam
2008-03-31 12:38:01 +03:00
mats@mats-laptop.(none)
540247f3e9 Updating commit.inc since the number of commits done for non-transactional
tables is not zero any more. For row-based logging, there is an extra commit
for sending rows changed by the statement to the binary log.
2008-03-31 11:29:03 +02:00
mkindahl@dl145h.mysql.com
a7fe4abc55 Merge mkindahl@bk-internal.mysql.com:/home/bk/mysql-5.0
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2008-03-31 09:57:29 +02:00
aelkin/andrei@mysql1000.(none)
22536fc53e Merge mysql1000.(none):/home/andrei/MySQL/BARE/mysql-5.1
into  mysql1000.(none):/home/andrei/MySQL/MERGE/5.1-main2rpl
2008-03-29 14:19:53 +02:00
istruewing@stella.local
1ce57e889d Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-03-26 17:36:12 +01:00
hezx@mail.hezx.com
905659a2a0 Merge mail.hezx.com:/media/sda3/work/mysql/bkroot/mysql-5.1-new-rpl
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/b33029_5.0_to_5.1_fails_on_dup_key/5.1
2008-03-26 21:40:44 +08:00
hezx@mail.hezx.com
d0ebb657ee Merge mail.hezx.com:/media/sda3/work/mysql/bkroot/mysql-5.0-rpl
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/b33029_5.0_to_5.1_fails_on_dup_key/5.0
2008-03-26 21:37:34 +08:00
istruewing@stella.local
44fbe74e1e Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2008-03-26 10:27:00 +01:00
istruewing@stella.local
fde9b55d61 Merge stella.local:/home2/mydev/mysql-5.0-amain
into  stella.local:/home2/mydev/mysql-5.0-axmrg
2008-03-26 09:33:55 +01:00
msvensson@pilot.mysql.com
201ce48d5d After merge fixes 2008-03-26 07:22:42 +01:00
msvensson@pilot.mysql.com
bc4874b79c Merge pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-rpl
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-mtr
2008-03-25 18:40:49 +01:00
anozdrin/alik@quad.opbmk
1298b1f3c0 Merge quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1
into  quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-03-25 14:54:08 +03:00
anozdrin/alik@quad.opbmk
fa6ed3cf36 Merge quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1
into  quad.opbmk:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-03-18 13:51:17 +03:00
aelkin/andrei@mysql1000.(none)
18dab9d7d8 Bug #18199 PURGE BINARY LOGS fails silently with missing logs;
Bug #18453  Warning/error message if there is a mismatch between ...
 
There were three problems:
 
 1. the reported lack of warnings for the BEFORE syntax of PURGE;
 2. the similar lack of warnings for the TO syntax;
 3. incompatible behaviour between the two in that the latter blanked out
    regardlessly of presence or lack the actual file corresponding to
    an index record; the former version gave up at the first mismatch.

fixed with deploying the warning's generation and synronizing logics of 
purge_logs() and purge_logs_before_date().
my_stat() is called in either of two branches of purge_logs() (responsible
for the TO syntax of PURGE) similarly to how it has behaved in the BEFORE syntax.
If there is no actual binlog file, my_stat returns NULL and my_delete is
not invoked.
A critical error is reported to the user if a file from the index
could not be retrieved info about or deleted with a system error code
different than ENOENT.
2008-03-17 20:19:04 +02:00
anozdrin/alik@quad.
393c54db50 Avoid races in connect.test.
The problem was in a test case for Bug33507:
  - when the number of active connections reaches the limit,
    the server accepts only root connections. That's achieved by
    accepting a connection, negotiating with the client and
    checking user credentials. If it is not SUPER, the connection
    is dropped.
  - when the server accepts connection, it increases the counter;
  - when the server drops connection, it decreases the counter;
  - the race was in between of decreasing the counter and accepting
    new connection:
    - max_user_connections = 2;
    - 2 oridinary user connections accepted;
    - extra user connection is establishing;
    - server checked user credentials, and sent 'Too many connections'
      error;
    - the client receives the error and establishes extra SUPER user
      connection;
    - the server however didn't decrease the counter (the extra
      user connection still is "alive" in the server) -- so, the new
      SUPER-user connection, will be dropped, because it exceeds
      (max_user_connections + 1).

The fix is to implement "safe connect", which makes several attempts
to connect and use it in the test script.
2008-03-17 14:26:00 +03:00
mkindahl@dl145h.mysql.com
9baeb72ee6 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-03-14 18:32:01 +01:00
istruewing@stella.local
eabe082d6f Manual merge 2008-03-14 12:02:11 +01:00
hezx@mail.hezx.com
a3d02647e6 BUG#33029 5.0 to 5.1 replication fails on dup key when inserting
using a trig in SP

For all 5.0 and up to 5.1.12 exclusive, when a stored routine or
trigger caused an INSERT into an AUTO_INCREMENT column, the
generated AUTO_INCREMENT value should not be written into the
binary log, which means if a statement does not generate
AUTO_INCREMENT value itself, there will be no Intvar event (SET
INSERT_ID) associated with it even if one of the stored routine
or trigger caused generation of such a value. And meanwhile, when
executing a stored routine or trigger, it would ignore the
INSERT_ID value even if there is a INSERT_ID value available set
by a SET INSERT_ID statement.

Starting from MySQL 5.1.12, the generated AUTO_INCREMENT value is
written into the binary log, and the value will be used if
available when executing the stored routine or trigger.

Prior fix of this bug in MySQL 5.0 and prior MySQL 5.1.12
(referenced as the buggy versions in the text below), when a
statement that generates AUTO_INCREMENT value by the top
statement was executed in the body of a SP, all statements in the
SP after this statement would be treated as if they had generated
AUTO_INCREMENT by the top statement.  When a statement that did
not generate AUTO_INCREMENT value by the top statement but by a
function/trigger called by it, an erroneous Intvar event would be
associated with the statement, this erroneous INSERT_ID value
wouldn't cause problem when replicating between masters and
slaves of 5.0.x or prior 5.1.12, because the erroneous INSERT_ID
value was not used when executing functions/triggers. But when
replicating from buggy versions to 5.1.12 or newer, which will
use the INSERT_ID value in functions/triggers, the erroneous
value will be used, which would cause duplicate entry error and
cause the slave to stop.

The patch for 5.1 fixed it to ignore the SET INSERT_ID value when
executing functions/triggers if it is replicating from a master
of buggy versions, another patch for 5.0 fixed it not to generate
the erroneous Intvar event.
2008-03-14 11:35:41 +08:00
hezx@mail.hezx.com
97ae23f473 BUG#33029 5.0 to 5.1 replication fails on dup key when inserting
using a trig in SP

For all 5.0 and up to 5.1.12 exclusive, when a stored routine or
trigger caused an INSERT into an AUTO_INCREMENT column, the
generated AUTO_INCREMENT value should not be written into the
binary log, which means if a statement does not generate
AUTO_INCREMENT value itself, there will be no Intvar event (SET
INSERT_ID) associated with it even if one of the stored routine
or trigger caused generation of such a value. And meanwhile, when
executing a stored routine or trigger, it would ignore the
INSERT_ID value even if there is a INSERT_ID value available set
by a SET INSERT_ID statement.

Starting from MySQL 5.1.12, the generated AUTO_INCREMENT value is
written into the binary log, and the value will be used if
available when executing the stored routine or trigger.

Prior fix of this bug in MySQL 5.0 and prior MySQL 5.1.12
(referenced as the buggy versions in the text below), when a
statement that generates AUTO_INCREMENT value by the top
statement was executed in the body of a SP, all statements in the
SP after this statement would be treated as if they had generated
AUTO_INCREMENT by the top statement.  When a statement that did
not generate AUTO_INCREMENT value by the top statement but by a
function/trigger called by it, an erroneous Intvar event would be
associated with the statement, this erroneous INSERT_ID value
wouldn't cause problem when replicating between masters and
slaves of 5.0.x or prior 5.1.12, because the erroneous INSERT_ID
value was not used when executing functions/triggers. But when
replicating from buggy versions to 5.1.12 or newer, which will
use the INSERT_ID value in functions/triggers, the erroneous
value will be used, which would cause duplicate entry error and
cause the slave to stop.

The patch for 5.0 fixed it not to generate the erroneous Intvar
event, another patch for 5.1 fixed it to ignore the SET INSERT_ID
value when executing functions/triggers if it is replicating from
a master of buggy versions.
2008-03-14 10:03:01 +08:00
kaa@kaamos.(none)
06bf29cf0f Fixed test failures caused by insufficient cleanups in the tests for
bug12713.
2008-03-12 16:52:29 +03:00
msvensson@pilot.mysql.com
af585cf4d8 Also copy [mysqld] section to [embedded] 2008-03-12 12:35:30 +01:00
kaa@kaamos.(none)
0a7052e4d3 Merge kaamos.(none):/data/src/mysql-5.1
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-03-12 11:19:46 +03:00
antony@pcg5ppc.xiphis.org
820068f1b7 Merge pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/mysql-5.1-engines
into  pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/merge.20080307/mysql-5.1
2008-03-07 13:46:29 -08:00
antony@pcg5ppc.xiphis.org
9c4e4640ad Merge pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/mysql-5.0-engines
into  pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/merge.20080307/mysql-5.0
2008-03-07 13:41:11 -08:00
svoj@june.mysql.com
99ca77afc9 Merge mysql.com:/home/svoj/devel/bk/mysql-5.1-engines
into  mysql.com:/home/svoj/devel/mysql/BUG13861/mysql-5.1-engines
2008-03-07 21:20:49 +04:00
sven@riska.(none)
81b1d712bf BUG#31168: @@hostname does not replicate
Problem: in mixed and statement mode, a query that refers to a
system variable will use the slave's value when replayed on
slave. So if the value of a system variable is inserted into a
table, the slave will differ from the master.
Fix: mark statements that refer to a system variable as "unsafe",
meaning they will be replicated by row in mixed mode and produce a warning
in statement mode. There are some exceptions: some variables are actually
replicated. Those should *not* be marked as unsafe.
BUG#34732: mysqlbinlog does not print default values for auto_increment variables
Problem: mysqlbinlog does not print default values for some variables,
including auto_increment_increment and others. So if a client executing
the output of mysqlbinlog has different default values, replication will
be wrong.
Fix: Always print default values for all variables that are replicated.
I need to fix the two bugs at the same time, because the test cases would
fail if I only fixed one of them.
2008-03-07 13:59:36 +01:00
bar@bar.myoffice.izhnet.ru
c49eccfe71 Merge mysql.com:/home/bar/mysql-work/mysql-5.0.b27580v2
into  mysql.com:/home/bar/mysql-work/mysql-5.1.b27580
Additonal after merge fix
2008-03-07 15:28:51 +04:00
bar@bar.myoffice.izhnet.ru
34da9303ef Merge mysql.com:/home/bar/mysql-work/mysql-5.0.b27580
into  mysql.com:/home/bar/mysql-work/mysql-5.0.b27580v2
2008-03-06 08:41:05 +04:00
mkindahl@dl145h.mysql.com
15e7050499 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-03-05 10:16:20 +01:00
skozlov/ksm@mysql.com/virtop.(none)
3c108889fb WL#4091, replace sleeps 2008-02-28 14:36:14 +03:00
msvensson@pilot.mysql.com
56a354794c Merge pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-rpl
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-mtr
2008-02-28 12:21:44 +01:00
svoj@mysql.com/june.mysql.com
cf50a67cca BUG#13861 - START SLAVE UNTIL may stop 1 evnt too late if
log-slave-updates and circul repl

After merge fixes.
2008-02-27 21:46:06 +04:00
kostja@dipika.(none)
24d27e3b7c Update Bug#12713 test results to take into account fixed bugs (29157, 33846) 2008-02-27 18:38:17 +03:00
mkindahl@dl145h.mysql.com
0b6471da9c Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-27 11:00:43 +01:00
mkindahl@dl145h.mysql.com
3f85bbe53d Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
2008-02-27 10:57:48 +01:00
anozdrin/alik@quad.
bdc83bf2cb Merge quad.:/mnt/raid/alik/MySQL/devel/5.1
into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
2008-02-26 19:34:02 +03:00
anozdrin/alik@quad.
340906f46d Fix for Bug#30217: Views: changes in metadata behaviour
between 5.0 and 5.1.
  
The problem was that in the patch for Bug#11986 it was decided
to store original query in UTF8 encoding for the INFORMATION_SCHEMA.
This approach however turned out to be quite difficult to implement
properly. The main problem is to preserve the same IS-output after
dump/restore.
  
So, the fix is to rollback to the previous functionality, but also
to fix it to support multi-character-set-queries properly. The idea
is to generate INFORMATION_SCHEMA-query from the item-tree after
parsing view declaration. The IS-query should:
  - be completely in UTF8;
  - not contain character set introducers.
  
For more information, see WL4052.
2008-02-22 13:30:33 +03:00
msvensson@pilot.mysql.com
d80b1ae384 Merge pilot.mysql.com:/data/msvensson/mysql/mysql-5.0-build
into  pilot.mysql.com:/data/msvensson/mysql/mysql-5.1-build
2008-02-21 14:11:01 +01:00
msvensson@pilot.mysql.com
c317562df4 Bug#32025 ndb_waiter does too many roundtrips to ndb_mgmd
- fix test failures that was already there but now are
   more consistent when the 1 second sleep has been removed from
   ndb_waiter
2008-02-21 13:23:58 +01:00
mkindahl@dl145h.mysql.com
759d2f6658 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-02-20 19:49:26 +01:00
bar@bar.myoffice.izhnet.ru
d5011e8561 Merge mysql.com:/home/bar/mysql-work/mysql-5.0.b32510
into  mysql.com:/home/bar/mysql-work/mysql-5.0.b32510v2
2008-02-20 14:38:52 +04:00
kostja@dipika.(none)
d8e6308c42 Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into  dipika.(none):/opt/local/work/mysql-5.1-2pc-opt-merge-push
2008-02-19 14:53:22 +03:00
kostja@dipika.(none)
acf9b1f346 A fix and a test case for Bug#12713 "Error in a stored function called from
a SELECT doesn't cause ROLLBACK of statem".

The idea of the fix is to ensure that we always commit the current
statement at the end of dispatch_command(). In order to not issue
redundant disc syncs, an optimization of the two-phase commit
protocol is implemented to bypass the two phase commit if
the transaction is read-only.
2008-02-19 14:43:01 +03:00
kaa@kaamos.(none)
5647dee192 Merge kaamos.(none):/data/src/mysql-5.1
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-17 14:57:01 +03:00
anozdrin/alik@quad.
b25de63309 Add a test case for Bug#21704: Renaming column does not update
FK definition.
2008-02-15 14:14:09 +03:00
kaa@kaamos.(none)
9f194149b8 Merge kaamos.(none):/data/src/opt/mysql-5.0-opt
into  kaamos.(none):/data/src/opt/mysql-5.1-opt
2008-02-13 12:12:00 +03:00
bar@mysql.com/bar.myoffice.izhnet.ru
efa7ee3573 Bug#27877 incorrect german order in utf8_general_ci
Problem: incorrect sort order for "U+00DF SHARP S".
Fix: changing sort order for U+00DF to be equal to 's',
like the manual says.
2008-02-11 16:28:33 +04:00
bar@mysql.com/bar.myoffice.izhnet.ru
3a438cf57a Bug#32510 LIKE search fails with indexed 'eucjpms' and 'ujis' char column
Problem: some collation handlers called incorrect version
of my_like_range_xxx(), which led to wrong min_str and max_str,
so like range optimizer threw away good records.
Fix: changing the wrong handlers to call proper version of
my_like_range_xxx().
2008-02-04 11:10:40 +04:00
mkindahl@dl145h.mysql.com
ff40ccb8d7 Masking out some more errors and warnings that are benign. 2008-02-04 07:15:14 +01:00
mkindahl@dl145h.mysql.com
221ef88c6a Bug #34244 Test ndb_binlog_log_bin fails for 'drop table if
exists t1,t2,t3'
Bug #34245 Test ndb_binlog_multi fails for 'CREATE TABLE'
Bug #34246 Test rpl_ndb_transaction fails with 'Failed to create
           'mysql/ndb_apply_status'

Tests cases didn't wait for cluster to come up due to a typo
in have_multi_ndb.inc.
2008-02-03 11:48:45 +01:00
mkindahl@dl145h.mysql.com
4c95b29614 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-31 17:46:50 +01:00
mkindahl@dl145h.mysql.com
2d9c3b715d Fixes to make tests pass on pushbuild. 2008-01-31 15:53:47 +01:00
mkindahl@dl145h.mysql.com
6aacc6415a Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-31 12:32:48 +01:00
mkindahl@dl145h.mysql.com
10b194d272 Changes to fix tests in pushbuild. 2008-01-31 12:17:40 +01:00
mkindahl@dl145h.mysql.com
018cb16b3a Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-30 12:53:33 +01:00
mkindahl@dl145h.mysql.com
3bcab5899d Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
2008-01-30 12:14:14 +01:00
mkindahl@dl145h.mysql.com
716c63ebaa Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
2008-01-30 11:25:54 +01:00
mkindahl@dl145h.mysql.com
9294edeb43 Test changes to fix failures in pushbuild. 2008-01-29 14:43:41 +01:00
tsmith@ramayana.hindu.god
3906cc27d7 Merge ramayana.hindu.god:/home/tsmith/m/bk/51
into  ramayana.hindu.god:/home/tsmith/m/bk/maint/51
2008-01-25 10:37:29 -07:00
hezx@mail.hezx.com
41bb6f988c Merge mail.hezx.com:/media/sda3/work/mysql/bkwork/versional/mysql-5.1-new-rpl
into  mail.hezx.com:/media/sda3/work/mysql/bkwork/versional/merge-51
2008-01-14 15:41:28 +08:00
hezx@mail.hezx.com
2720b76c4a Fix for versional test
Mask binlog positions, error, warning and other information that are not significant for the test
2008-01-14 15:38:02 +08:00
igor@olga.mysql.com
947715c228 Merge olga.mysql.com:/home/igor/mysql-5.1-opt
into  olga.mysql.com:/home/igor/dev-opt/mysql-5.1-opt-bug33697
2008-01-11 10:12:29 -08:00
igor@olga.mysql.com
b85ffdb5d5 Fixed bug #33697.
When the function test_if_skip_sort_order prefers index backward scan 
to ref access the corresponding access functions must be set accordingly.
2008-01-11 10:05:34 -08:00
gshchepa/uchum@host.loc
17c5117872 Merge host.loc:/home/uchum/work/5.1-opt-33699
into  host.loc:/home/uchum/work/5.1-opt
2008-01-11 21:39:45 +04:00
mkindahl@dl145h.mysql.com
940ecc23c6 Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl
into  dl145h.mysql.com:/data0/mkindahl/mysql-5.1-rpl-merge
2008-01-11 14:20:06 +01:00
gshchepa/uchum@host.loc
32d13ab23d Bug#33699: The UPDATE statement allows NULL as new value on a NOT NULL
columns (default datatype value is assigned).

The mysql_update function has been modified to generate
an error when trying to set a NOT NULL field to NULL rather than a warning
in the set_field_to_null_with_conversions function.
2008-01-11 05:06:08 +04:00
msvensson@pilot.mysql.com
da6073b4bc Revert removal of ER_GET_ERRMSG 2008-01-10 10:25:45 +01:00
msvensson@pilot.mysql.com
1fa7072bfa Bug#33763 Mysqld leaves readonly mode for cluster tables too early - part2
- Open tables readonly while not properly initialized
 - Close cached tables when coming out of readonly mode
 - Apply basically same patch as for 32275
2008-01-09 12:59:20 +01:00
hezx@mail.hezx.com
287b981c87 Add missing include test file for rpl_server_id test 2008-01-06 15:17:47 +08:00
skozlov/ksm@mysql.com/virtop.localdomain
5c55bb7283 WL#4077 added support old versions of mysqld binaries 2007-12-31 17:30:17 +03:00
serg@janus.mylan
d9ca7b670e Merge bk-internal.mysql.com:/home/bk/mysql-5.1-maint
into  janus.mylan:/usr/home/serg/Abk/mysql-5.1
2007-12-20 22:11:37 +01:00
skozlov/ksm@mysql.com/virtop.localdomain
c9225c9e62 WL#4077 fix for innodb test that were skipped 2007-12-20 23:57:06 +03:00
msvensson@pilot.mysql.com
d930e9bb22 Update path to the load_file 2007-12-20 18:38:23 +01:00