Commit graph

70132 commits

Author SHA1 Message Date
Mattias Jonsson
72e4804988 Bug#13500478 63623: TEST CASE PARTITION_BINLOG_STMT
CREATES A FILE IN AN IMPROPER LOCATION.

Fixed by using $MYSQLTEST_VARDIR, as proposed by
Davi Arnaut.

Thank you Davi!
2012-01-20 14:19:39 +01:00
Georgi Kodinov
93d123d789 Addendum to the fix for bug #11754014
- Fixed the checks to properly check for plugin_dir containing a trailing slash or backslash.
- Fixed a under-configuration in udf_skip_grants that was preventing the test 
  from running even when there was a udf plugin.
2012-01-20 13:35:48 +02:00
Dmitry Shulga
716dca03b6 Patch for bug#13070308 - VALGRIND failure in XA test.
The issue is that xa.test failed sporadically on some platforms.
The reason for the test failure is a race condition in xa.test.
The race condition occures between connection that executes statement
INSERT INTO t2 SELECT FROM t1 and other connection that tries to run
statements DELETE FROM t1 and COMMIT. If COMMIT statement had been executed
before the statement INSERT INTO t2 SELECT FROM t1 was locked by lock
on table t1 (as a result of query from table t1) then the INSERT statement
is executed successfully and a following test for deadlock would failed.

This patch fixes this race condition by moving COMMIT statement after commit
of distributed transaction from concurrent session.
2012-01-20 16:03:39 +06:00
Nuno Carvalho
9f41c0e5ca BUG#13050593 - BACKSLASH SWALLOWED BY INCLUDE/SHOW_SLAVE_STATUS.INC
If an error message contains '\' backslash it is displayed correctly
through show-slave-status or
query_get_value(SHOW SLAVE STATUS, Last_IO_Error, 1);. But when
SELECT REPLACE(...) is applied backslash is escaped resulting in a
different test output.

Disabled backslash escape on show_slave_status.inc and replaced '\' for
'/' using replace_regex function in order to achieve the same test
output when different path separators are used.
2012-01-19 16:56:43 +00:00
Inaam Rana
0da310b69d Bug#11765450 58421: INNODB TEMPORARY TABLE CRASH WHEN TMPDIR ON LINUX TMPFS
rb://898
approved by: Marko Makela

On some kernel versions native aio operations are not supported on
tmpfs. Check this during start up and fall back to simulated aio.
2012-01-19 09:10:30 -05:00
Andrei Elkin
4cef3cee00 merging from the 5.5 repo to local branch. 2012-01-18 00:35:53 +02:00
Andrei Elkin
1552531616 BUG#13593869 - 64035: SEVERAL ERRORS IN COM_BINLOG_DUMP/MYSQL_BINLOG_SEND CRASH THE SERVER
The server crashes when receiving a COM_BINLOG_DUMP command with a position of 0 or
larger than the file size.
The execution proceeds to an error block having the last read replication coordinates 
pointer be NULL and its dereferencing crashed the server.

Fixed with making "public" previously used only for heartbeat coordinates.
2012-01-18 00:16:19 +02:00
Georgi Kodinov
61df5de4fd merged bug #11754014 2012-01-17 11:38:34 +02:00
Marko Mäkelä
f4277c9dd6 Merge mysql-5.1 to mysql-5.5. 2012-01-16 14:26:42 +02:00
Marko Mäkelä
d985ac1f38 Bug#13496818 ASSERTION: REC_PAGE_NO > 4 IN IBUF CONTRACTION
Relax a bogus debug assertion.
Approved by Jimmy Yang on IM.
2012-01-16 14:22:03 +02:00
Tor Didriksen
9288d23ae0 Bug#13551687 CMAKE GENERATED PROJECT FILES ALWAYS HAVE THE SAME NAME IN VISUAL STUDIO
Add option to set project name for Mac/Windows.
2012-01-16 12:39:12 +01:00
Georgi Kodinov
0e48b69cba Bug #11754014: 45549: udf plugin_dir path separator inconsistency
and cryptic error 1126 message

The problem was that dlopen() related code was using just a subset 
of the path normalization routines used in other places.
Fixed the expansion of the pre-dlopen() behavior for plugins and UDFs
to use a platform-dependent consistent encoding of the paths.
Fixed the error dlopen() error handling to take the correct error message
and strip off the trailing newline character(s).
Fixed tests to do a platform independent replace of directories and to 
account for the traling slash.
2012-01-16 12:04:28 +02:00
Nuno Carvalho
790150d62f Automerge from mysql-5.1 to mysql-5.5. 2012-01-16 10:02:29 +00:00
Nuno Carvalho
bffc7ec82e BUG#11893288 60542: RPL.RPL_EXTRA_COL_MASTER_* DOESN'T TEST WHAT WAS INTENDED
Test extra/rpl_tests/rpl_extra_col_master.test (used by
rpl_extra_col_master_*) ends with the active connection pointing to the
slave. Thus, the two last tests never succeed in changing the binlog
format of the master away from 'row'. With correct active connection
(master) tests fail for binlog 'statement' and 'mixed' formats.

Tests rpl_extra_col_master_* only run when binary log format is
row.  Statement and mix replication do not make sense in this
tests since it will try to execute statements on columns that do
not exist.  This fix is basically a backport from mysql-5.5, see
changes done as part of BUG 39934.
2012-01-16 09:17:40 +00:00
Marko Mäkelä
c6664c446c Merge mysql-5.1 to mysql-5.5. 2012-01-16 09:58:02 +02:00
Marko Mäkelä
97e0eeb364 buf_page_get_known_nowait(): Relax a bogus debug assertion.
When mode==BUF_KEEP_OLD, buffered inserts are being merged to the page.
It is possible that a read request for a page was pending while the page
was freed in DROP INDEX or DROP TABLE. In these cases, it is OK (although
useless) to merge the buffered changes to the freed page.
2012-01-16 09:55:12 +02:00
Annamalai Gurusami
0b24b8fbaa Merging from mysql-5.1 to mysql-5.5. 2012-01-16 10:30:51 +05:30
Annamalai Gurusami
fd6f9a1ecc Bug #11765438 58406:
ISSUES WITH COPYING PARTITIONED INNODB TABLES FROM LINUX TO WINDOWS

This problem was already fixed in mysql-trunk as part of bug #11755924.  I am 
backporting the fix to mysql-5.1.
2012-01-16 09:58:31 +05:30
Tor Didriksen
8338d21a90 fix compile warning: may be used uninitialized 2012-01-12 16:27:53 +01:00
Georgi Kodinov
d0a58c1e7a weave merge of mysql-5.1->mysql-5.5
merge of Nirbhay's AIX compilation fix for 5.1.61
2012-01-12 15:03:44 +02:00
Georgi Kodinov
faaa1b3b41 empty weave merge 2012-01-12 14:57:14 +02:00
Alexander Barkov
cbee6f82b9 BUG#13354387 - CRASH IN IN MY_DECIMAL::OPERATOR FOR VIEW AND FUNCTION UNIX_TIME
Fixing the 5.5 part (the 5.6 part will go in a separate commit soon).

Problem:
  Item_direct_ref::get_date() incorrectly calculated its "null_value",
  which made UNIX_TIMESTAMP(view_column) incorrectly return NULL
  for a NOT NULL view_column.

Fix:
  Make Item_direct_ref::get_date() calculate null_value
  in the similar way with the other methods 
  (val_real,val_str,val_int,val_decimal):
  copy null_value from the referenced Item.

modified:
  mysql-test/r/func_time.result
  mysql-test/t/func_time.test
  sql/item.cc
2012-01-12 13:02:51 +04:00
Karen Langford
1af8783b07 Merge from mysql-5.1.61-release 2012-01-11 18:51:42 +01:00
hery.ramilison@oracle.com
87f6756fdb Merge from mysql-5.5.20-release 2012-01-11 18:50:47 +01:00
Karen Langford
b2766703a8 Fixes required to build on AIX 2012-01-11 18:40:29 +01:00
Bjorn Munch
ee2d09199a Merge from mysql-5.0.95-release 2012-01-11 10:10:34 +01:00
Nirbhay Choubey
e2e91b7b7c Merge of fix for bug#11760384 from mysql-5.1. 2012-01-10 16:10:48 +05:30
Nirbhay Choubey
7faf69dd82 BUG#11760384 - 52792: mysqldump in XML mode does not dump
routines.

mysqldump in xml mode did not dump routines, events or
triggers.

This patch fixes this issue by fixing the if conditions
that disallowed the dump of above mentioned objects in
xml mode, and added the required code to enable dump
in xml format.
2012-01-10 13:33:45 +05:30
Sneha Modi
43721f354a Bug#11748572: ALLOCATING A LARGE QUERY CACHE IS NOT DETERMINISTIC
Moving query_cache_size_basic_32.test and query_cache_size_basic_64.test from experimental
to disabled as a solution has still not been found.
2012-01-10 11:41:50 +05:30
Yasufumi Kinoshita
6938d8fd00 Bug#12400341 INNODB CAN LEAVE ORPHAN IBD FILES AROUND
If we meet DB_TOO_MANY_CONCURRENT_TRXS during the execution tab_create_graph from row_create_table_for_mysql(), .ibd file for the table should be created already but was not deleted for the error handling.

rb:875 approved by Jimmy Yang
2012-01-10 14:23:20 +09:00
Yasufumi Kinoshita
40203bd584 Bug#12400341 INNODB CAN LEAVE ORPHAN IBD FILES AROUND
If we meet DB_TOO_MANY_CONCURRENT_TRXS during the execution tab_create_graph from row_create_table_for_mysql(), .ibd file for the table should be created already but was not deleted for the error handling.

rb:875 approved by Jimmy Yang
2012-01-10 14:18:58 +09:00
Hemant Kumar
a08d111761 Null merge from 5.1 for Bug 12872803 - 62154: FEDERATED.FEDERATED_SERVER TEST FAILS WITH RUN --REPEAT=2 2012-01-06 16:37:02 +05:30
Hemant Kumar
5b576596a2 Bug#12872803 - 62154: FEDERATED.FEDERATED_SERVER TEST FAILS WITH RUN --REPEAT=2
Fixed it to work with "--repeat" option.
2012-01-06 16:28:24 +05:30
Hemant Kumar
577289d5da Bug#12872804 - 62155: BINLOG.BINLOG_STM_UNSAFE_WARNING FAILS WHEN RUN WITH --REPEAT=2
Fixed the testcase using timestamp logic while doing grep from the error file.
2012-01-06 15:52:56 +05:30
Hemant Kumar
595f116df0 Bug#12872804 - 62155: BINLOG.BINLOG_STM_UNSAFE_WARNING FAILS WHEN RUN WITH --REPEAT=2
Fixed the testcase using timestamp logic while doing grep from the error file.
2012-01-06 15:46:03 +05:30
Bjorn Munch
446b75d031 merge 5.5-mtr => 5.5 2012-01-06 00:23:09 +01:00
Bjorn Munch
558d069e76 Followup after 13055685:
Use new syntax to mask different error output in affected tests
2012-01-04 16:16:17 +01:00
Bjorn Munch
488396525f merge 5.5 => 5.5-mtr 2012-01-03 10:59:33 +01:00
Tatjana Azundris Nuernberg
8248f5f71a manual up-merge of Bug#11755281 2012-01-02 06:50:05 +00:00
Tatjana Azundris Nuernberg
1666da4b23 BUG#11755281/47032: ERROR 2006 / ERROR 2013 INSTEAD OF PROPER ERROR MESSAGE
If init_command was incorrect, we couldn't let users execute
queries, but we couldn't report the issue to the client either
as it does not expect error messages before even sending a
command. Thus, we simply disconnected them without throwing
a clear error.

We now go through the proper sequence once (without executing
any user statements) so we can report back what the problem
is. Only then do we disconnect the user.

As always, root remains unaffected by this as init_command is
(still) not executed for them.
2012-01-02 06:25:48 +00:00
Vasil Dimov
b817cae5b2 Partial fix for Bug#11764622 57480: MEMORY LEAK WHEN HAVING 256+ TABLES
Port vasil.dimov@oracle.com-20111205083046-jtgi1emlvtfnjatt from mysql-trunk
2011-12-29 16:19:33 +02:00
Vasil Dimov
371ebdbb03 Partial fix for Bug#11764622 57480: MEMORY LEAK WHEN HAVING 256+ TABLES
Port vasil.dimov@oracle.com-20111205082900-lx9om1joscejr25e from mysql-trunk
2011-12-29 16:14:45 +02:00
Vasil Dimov
40848aa1c4 Partial fix for Bug#11764622 57480: MEMORY LEAK WHEN HAVING 256+ TABLES
Port vasil.dimov@oracle.com-20111205082831-7v1qu50hvd9hjr3g from mysql-trunk
2011-12-29 16:12:55 +02:00
Vasil Dimov
8341a440b0 Partial fix for Bug#11764622 57480: MEMORY LEAK WHEN HAVING 256+ TABLES
Port vasil.dimov@oracle.com-20111205082756-wtlg8isyn4yohyny from mysql-trunk
2011-12-29 16:11:07 +02:00
Vasil Dimov
3696b3502e Partial fix for Bug#11764622 57480: MEMORY LEAK WHEN HAVING 256+ TABLES
Port vasil.dimov@oracle.com-20111205082626-87j5f48dq1ouk86r from mysql-trunk
2011-12-29 16:05:08 +02:00
Marko Mäkelä
c1f5243eb1 Merge mysql-5.1 to mysql-5.5. 2011-12-28 12:31:18 +02:00
Marko Mäkelä
a290a84403 Bug#13418934 REMOVE HAVE_PURIFY DEPENDENCES FROM INNODB
InnoDB: Remove HAVE_purify, UNIV_INIT_MEM_TO_ZERO, UNIV_SET_MEM_TO_ZERO.

The compile-time setting HAVE_purify can mask potential bugs.
It is being set in PB2 Valgrind runs. We should simply get rid of it,
and replace it with UNIV_MEM_INVALID() to declare uninitialized memory
as such in Valgrind-instrumented binaries.

os_mem_alloc_large(), ut_malloc_low(): Remove the parameter set_to_zero.

ut_malloc(): Define as a macro that invokes ut_malloc_low().

buf_pool_init(): Never initialize the buffer pool frames. All pages
must be initialized before flushing them to disk.

mem_heap_alloc(): Never initialize the allocated memory block.

os_mem_alloc_nocache(), ut_test_malloc(): Unused function, remove.

rb:813 approved by Jimmy Yang
2011-12-28 12:19:30 +02:00
Rohit Kalhans
891f6368f2 rpl.rpl_known_bugs_detection fails on PB2 daily mysql-5.5.
The rpl.rpl_known_bugs_detection fails on pb2 as warnings were found in the
mysqld log file. We fix this problem by suppressing the warning.
2011-12-26 22:40:56 +05:30
Nirbhay Choubey
0a8824e9c3 Bug#12809202 61854: MYSQLDUMP --SINGLE-TRANSACTION
--FLUSH-LOG BREAKS CONSISTENCY

Post-fix for some failing tests.
2011-12-24 15:08:59 +05:30
Nirbhay Choubey
a4343d56ed Bug#12809202 61854: MYSQLDUMP --SINGLE-TRANSACTION
--FLUSH-LOG BREAKS CONSISTENCY

The transaction started by mysqldump gets committed
implicitly when flush-log is specified along with
single-transaction option, and hence can break
consistency.

This is because, COM_REFRESH is executed in order
to flush logs and starting from 5.5 this command
performs an implicit commit.

Fixed by making sure that COM_REFRESH is executed
before the transaction has started and not after it.

Note : This patch triggers following behavioral
       changes in mysqldump :

1) After this patch we no longer flush logs before
   dumping each database if --single-transaction
   option is given like it was done before (in the
   absence of --lock-all-tables and --master-data
   options).

2) Also, after this patch, we start acquiring
   FTWRL before flushing logs in cases when only
   --single-transaction and --flush-logs are given.
   It becomes safe to use mysqldump with these two
   options and without --master-data parameter for
   backups.
2011-12-23 23:05:00 +05:30