Commit graph

9506 commits

Author SHA1 Message Date
Jan Lindström
628bc576b3 MDEV-9918: [ERROR] mysqld got signal 11 during ALTER TABLE name COLUMN ADD
Problem was that in-place online alter table was used on a table
that had mismatch between MySQL frm file and InnoDB data dictionary.
Fixed so that traditional "Copy" method is used if the MySQL frm
and InnoDB data dictionary is not consistent.
2016-04-22 08:57:07 +03:00
Sergei Golubchik
b069d19284 Merge branch 'mysql/5.5' into 5.5 2016-04-20 15:25:55 +02:00
Kristian Nielsen
1cf852d874 MDEV-9383: Server fails to read master.info after upgrade 10.0 -> 10.1
In some cases, MariaDB 10.0 could write a master.info file that was read
incorrectly by 10.1 and could cause server to fail to start after an upgrade.

(If writing a new master.info file that is shorter than the old, extra
junk may remain at the end of the file. This is handled properly in
10.1 with an END_MARKER line, but this line is not written by
10.0. The fix here is to make 10.1 robust at reading the master.info
files written by 10.0).

Fix several things around reading master.info and read_mi_key_from_file():

 - read_mi_key_from_file() did not distinguish between a line with and
   without an eqals '=' sign.

 - If a line was empty, read_mi_key_from_file() would incorrectly return
   the key from the previous call.

 - An extra using_gtid=X line left-over by MariaDB 10.0 might incorrectly
   be read and overwrite the correct value.

 - Fix incorrect usage of strncmp() which should be strcmp().

 - Add test cases.
2016-04-08 10:31:03 +02:00
Elena Stepanova
f8adeccd78 MDEV-9713 Sporadic test failure: sys_vars.innodb_buffer_pool_load_now_basic
Previous fix using wait condition did not work because of MDEV-9867, so
we have to use conditional sleep instead. Sleep will only happen if the test
is executed after another one which also ran buffer pool dump without
server restart between two tests
2016-04-04 17:04:14 +03:00
Oleksandr Byelkin
9f5b285662 Followup for 2783fc7: return an error to the caller if mysql.proc cannot be opened 2016-03-24 09:45:28 +01:00
Alexey Botchkov
4374501806 Ugly test removed for now. 2016-03-24 11:00:40 +04:00
Alexey Botchkov
2783fc7d14 MDEV-717 LP:1003679 - Wrong binlog order on concurrent DROP schema and CREATE function.
The cause of the issue is when DROP DATABASE takes
        metadata lock and is in progress through it's
        execution, a concurrently running CREATE FUNCTION checks
        for the existence of database which it succeeds and then it
        waits on the metadata lock.  Once DROP DATABASE writes to
        BINLOG and finally releases the metadata lock on schema
        object, the CREATE FUNCTION waiting on metadata lock
        gets in it's code path and succeeds and writes to binlog.
2016-03-23 12:16:39 +04:00
Elena Stepanova
f66303dcf9 Fix sysvar tests - embedded and 32-bit 2016-03-23 02:22:09 +02:00
Vicențiu Ciorbaru
29753fb9f2 MDEV-9443: Add reexecution test cases. 2016-03-22 22:21:04 +02:00
Vicențiu Ciorbaru
287f2d2947 MDEV-9443: Add REVOKE <role> as a command to PREPARE 2016-03-22 22:21:04 +02:00
Vicențiu Ciorbaru
c4bef7ad3c MDEV-9443: Roles aren't supported in prepared statements
Make role statements work with the PREPARE keyword.
2016-03-22 22:21:04 +02:00
Vicențiu Ciorbaru
16ddd1824c MDEV-9613: keyfile without any keys crashes mysqld on loading file_key_management plugin
Code was assuming that the keys file would contain at least one valid
key. This caused a Dynamic_array::at(0) call that lead to the crash.
2016-03-22 22:20:33 +02:00
Alexey Botchkov
0a4a78ae8c MDEV-6058 MySQL Bug #11766693: LOG-SLOW-ADMIN-STATEMENTS AND
LOG-SLOW-SLAVE-STATEMENTS NOT DISPLAYED.

        These parameters were moved from the command line options to
        the system variables section. Treatment of the
        opt_log_slow_slave_statements changed to let the
        dynamic change of the variable.
2016-03-22 23:26:39 +04:00
Sergei Golubchik
fd6c588659 Merge branch 'bb-10.1-serg' into 10.1 2016-03-22 19:18:48 +01:00
Sergei Golubchik
e0c136b4f0 MDEV-9737 Duplicate error in replication with slave triggers and auto increment
delete deferred events after they're executed
(otherwise they can be executed again for a sub-statement)

See also
commit 0e78d1d
Author: Venkatesh Duggirala <venkatesh.duggirala@oracle.com>
Date:   Wed Mar 20 11:20:47 2013 +0530

    BUG#15850951-DUPLICATE ERROR IN REPLICATION WITH SLAVE
    TRIGGERS AND AUTO INCREMENT
2016-03-22 10:53:28 +01:00
Nirbhay Choubey
37f915c191 Merge branch '10.0-galera' into 10.1 2016-03-22 01:35:56 -04:00
Nirbhay Choubey
d31d6d31bb MDEV-9696: CREATE SERVER statement does not replicate in Galera Cluster
Enable replication of CREATE/ALTER/DROP SERVER statements
in Galera cluster.
2016-03-22 00:38:21 -04:00
Nirbhay Choubey
000f76d886 Fix galera_sync_wait_show test. 2016-03-22 00:38:20 -04:00
Nirbhay Choubey
7c42b47e67 Merge branch '5.5-galera' into 10.0-galera 2016-03-22 00:35:14 -04:00
Alexander Barkov
537fc572d4 MDEV-9516 type error when setting session variable
Allowing assigning of DECIMAL(N,0) values to INT-alike system variables.
2016-03-22 00:09:04 +04:00
Sergei Golubchik
3b0c7ac1f9 Merge branch '10.0' into 10.1 2016-03-21 13:02:53 +01:00
Sergei Golubchik
98ea806207 Merge branch '5.5' into 10.0 2016-03-21 11:54:45 +01:00
Oleksandr Byelkin
e8af217e16 MDEV-9590: Always print "Engine-independent statistic" warnings and might be filtering columns unintentionally from engines
Do not issue the warning in case we are not going to collect the statistics.
2016-03-21 11:48:04 +01:00
Sergei Golubchik
7baff9f687 fix extension_based_table_discovery for partitioned tables
typo. the code was not matching the comment
2016-03-21 11:43:19 +01:00
Sergei Golubchik
3fdc6140a3 update plugins' maturity levels 2016-03-18 22:05:23 +01:00
Nirbhay Choubey
9c89b84d46 MDEV-9401: wsrep_forced_binlog_format with binlog causes crash
Some statements are always replicated in STATEMENT binlog format.
So upon their execution, the current binlog format is temporarily
switched to STATEMENT even though the session's format is different.
This state, stored in THD's current_stmt_binlog_format, was getting
incorrectly masked by wsrep_forced_binlog_format, causing assertions
and unintended generation of row events.

Backported galera.galera_forced_binlog_format and added a test
specific to this case.
2016-03-18 11:27:32 -04:00
Sergey Vojtovich
546e9139ab Fixed plugins.cracklib_password_check failure
In RHEL7/RHEL7.1 libcrack behavior seem to have been modified so that
"foobar" password is considered bad (due to descending "ba") earlier than
expected. For details google for cracklib-2.9.0-simplistic.patch.

Adjusted affected passwords not to have descending and ascending sequences.
2016-03-18 14:39:17 +04:00
Jan Lindström
ee768d8e0e MDEV-9640: Add used key_id to INFORMATION_SCHEMA.INNODB_TABLESPACES_ENCRYPTION 2016-03-18 11:48:49 +02:00
Jan Lindström
f448a800e1 MDEV-9422: Checksum errors on restart when killing busy instance that uses encrypted XtraDB tables
Analysis:

-- InnoDB has n (>0) redo-log files.
-- In the first page of redo-log there is 2 checkpoint records on fixed location (checkpoint is not encrypted)
-- On every checkpoint record there is up to 5 crypt_keys containing the keys used for encryption/decryption
-- On crash recovery we read all checkpoints on every file
-- Recovery starts by reading from the latest checkpoint forward
-- Problem is that latest checkpoint might not always contain the key we need to decrypt all the
   redo-log blocks (see MDEV-9422 for one example)
-- Furthermore, there is no way to identify is the log block corrupted or encrypted

For example checkpoint can contain following keys :

write chk: 4 [ chk key ]: [ 5 1 ] [ 4 1 ] [ 3 1 ] [ 2 1 ] [ 1 1 ]

so over time we could have a checkpoint

write chk: 13 [ chk key ]: [ 14 1 ] [ 13 1 ] [ 12 1 ] [ 11 1 ] [ 10 1 ]

killall -9 mysqld causes crash recovery and on crash recovery we read as
many checkpoints as there is log files, e.g.

read [ chk key ]: [ 13 1 ] [ 12 1 ] [ 11 1 ] [ 10 1 ] [ 9 1 ]
read [ chk key ]: [ 14 1 ] [ 13 1 ] [ 12 1 ] [ 11 1 ] [ 10 1 ] [ 9 1 ]

This is problematic, as we could still scan log blocks e.g. from checkpoint 4 and we do
not know anymore the correct key.

CRYPT INFO: for checkpoint 14 search 4
CRYPT INFO: for checkpoint 13 search 4
CRYPT INFO: for checkpoint 12 search 4
CRYPT INFO: for checkpoint 11 search 4
CRYPT INFO: for checkpoint 10 search 4
CRYPT INFO: for checkpoint 9 search 4 (NOTE: NOT FOUND)

For every checkpoint, code generated a new encrypted key based on key
from encryption plugin and random numbers. Only random numbers are
stored on checkpoint.

Fix: Generate only one key for every log file. If checkpoint contains only
one key, use that key to encrypt/decrypt all log blocks. If checkpoint
contains more than one key (this is case for databases created
using MariaDB server version 10.1.0 - 10.1.12 if log encryption was
used). If looked checkpoint_no is found from keys on checkpoint we use
that key to decrypt the log block. For encryption we use always the
first key. If the looked checkpoint_no is not found from keys on checkpoint
we use the first key.

Modified code also so that if log is not encrypted, we do not generate
any empty keys. If we have a log block and no keys is found from
checkpoint we assume that log block is unencrypted. Log corruption or
missing keys is found by comparing log block checksums. If we have
a keys but current log block checksum is correct we again assume
log block to be unencrypted. This is because current implementation
stores checksum only before encryption and new checksum after
encryption but before disk write is not stored anywhere.
2016-03-18 07:58:04 +02:00
Elena Stepanova
0125e588f3 MDEV-9713 Sporadic test failure: sys_vars.innodb_buffer_pool_load_now_basic
It could have happened that one of previous tests already executed
buffer pool dump and set the status variable value, so when it's been
checked, the check passes too early, before the dump starts and
the dump file is created. See more detailed explanation in MDEV-9713.

Fixed by waiting for the current time to change in case it equals
to the timestamp in the status variable, and then checking that
the status variable not only matches the expected pattern, but also
differs from the previous value, whatever it was.
2016-03-12 17:50:57 +02:00
Jan Lindström
8103526b38 MDEV-9667: Server hangs after select count(distinct name) from t2 where a=8366 and b>=5 and b<=5;
In row_search_for_mysql function on XtraDB there was a old logic
where null bytes were inited. This caused server to think that
key value is null and continue on incorrect path.
2016-03-11 13:36:29 +02:00
Sergei Golubchik
c689e93500 update sysvar_innodb,32bit,xtradb.rdiff 2016-03-05 16:25:23 +01:00
Otto Kekäläinen
1777fd5f55 Fix spelling: occurred, execute, which etc 2016-03-04 02:09:37 +02:00
Venkatesh Duggirala
29cc2c2883 BUG#20574550 MAIN.MERGE TEST CASE FAILS IF BINLOG_FORMAT=ROW
The main.merge test case was failing when tested using row based
binlog format.

While analyzing the issue it was found the following issues:

a) The server is calling binlog related code even when a statement will
   not be binlogged;
b) The child table list was not present into table structure by the time
   to generate the create table statement;
c) The tables in the child table list will not be opened yet when
   generating table create info using row based replication;
d) CREATE TABLE LIKE TEMP_TABLE does not preserve original table storage
   engine when using row based replication;

This patch addressed all above issues.

@ sql/sql_class.h

Added a function to determine if the binary log is disabled to
  the current session. This is related with issue (a) above.

@ sql/sql_table.cc

Added code to skip binary logging related code if the statement
  will not be binlogged. This is related with issue (a) above.

Added code to add the children to the query list of the table that
  will have its CREATE TABLE generated. This is related with issue (b)
  above.

Added code to force the storage engine to be generated into the
  CREATE TABLE. This is related with issue (d) above.

@ storage/myisammrg/ha_myisammrg.cc

Added a test to skip a table getting info about a child table if the
  child table is not opened. This is related to issue (c) above.
2016-02-26 09:01:49 +05:30
Elena Stepanova
c29e450e37 MDEV-4070 sys_vars.secure_file_priv fails sporadically if it's executed with --mem
The test created a file in location relative to the datadir
(a few levels above datadir).
The file was created by MariaDB server (via INTO OUTFILE), and
later removed by mysqltest (via remove_file). The problem is that
when the vardir is a symlink, MariaDB server and mysqltest can
resolve such paths differently. MariaDB server would return back
to where the symlink is located, while mysqltest would go above
the real directory. For example, if the test is run with --mem,
and /bld/5.5/mysql-test/var points at /dev/shm/var_auto_X, then
SELECT INTO OUTFILE created a file in /bld/5.5/mysql-test , but
remove_file would look for it in /dev/shm/.

The test is re-written so that all paths are resolved in perl,
the logic itself hasn't changed.
2016-02-26 03:02:07 +02:00
Nirbhay Choubey
01897db102 Skip galera_sync_wait_show.test on non-debug builds.
The test uses a debug feature SHOW PROCEDURE|FUNCTION CODE.
2016-02-24 17:40:12 -05:00
Sergei Golubchik
d044507dc5 Merge branch 'bb-10.1-serg' into 10.1
10.0 merge
10.0-galera merge
connect/10.1 merge
2016-02-24 10:27:23 +01:00
Sergei Golubchik
5a4ec8e60b fix test results after the merge 2016-02-24 10:26:52 +01:00
Nirbhay Choubey
cceec7858f Merge branch '10.0-galera' into bb-10.1-serg 2016-02-24 01:21:40 -05:00
Nirbhay Choubey
0d58323e26 Merge tag 'mariadb-10.0.24' into 10.0-galera 2016-02-23 20:53:29 -05:00
Nirbhay Choubey
276d65b324 Fix for test failures. 2016-02-23 20:33:21 -05:00
Sergei Golubchik
a5679af1b1 Merge branch '10.0' into 10.1 2016-02-23 21:35:05 +01:00
Vicențiu Ciorbaru
de1fa45276 [MDEV-8411] Assertion failed in !table->write_set
The reason for the assertion failure is that the update statement for
the minimal row image sets only the PK column in the write_set of the
table to true. On the other hand, the trigger aims to update a different
column.

Make sure that triggers update the used columns accordingly, when being
processed.
2016-02-23 16:56:37 +02:00
Sergei Golubchik
a38b705fe0 MDEV-9560 Mariadb 10.1 Crashes when replicating from 10.0
when replicating old temporal type fields (that don't store
metadata in the binlog), take the precision from
destination fields.

(this fixes the replication failure, crashes were
fixed in a different commit)
2016-02-23 10:46:16 +01:00
Sergei Golubchik
bb54df6ec9 update test results after MDEV-9307 2016-02-23 10:46:15 +01:00
sjaakola
b633dbdac9 refs codership/mysql-wsrep#237
- test for FLUSH TABLES hang in slave node
2016-02-23 00:28:16 -05:00
sjaakola
90e5e2f91c refs codership/mysql-wsrep#233
- added mtr test case for this issue
- not a perfect one, depends on some sleeps instead of checking
  if sync points are met
2016-02-23 00:20:36 -05:00
Philip Stoev
bf9572ba59 refs codership/mysql-wsrep#228 - a test for wsrep_sync_wait and SHOW 2016-02-23 00:11:09 -05:00
Philip Stoev
2b7a5d9edb Galera MTR Tests: adjust the galera.galera_defaults test for the new MTR default value for repl.causal_read_timeout 2016-02-22 23:55:38 -05:00
Philip Stoev
8504330d1d Galera MTR Tests: misc test stability fixes 2016-02-22 23:52:30 -05:00
Nirbhay Choubey
c05d85f45d Refs codership/mysql-wsrep#198 : Fix test case 2016-02-22 22:35:48 -05:00
Philip Stoev
e9d805b845 Refs codership/mysql-wsrep#198 . MTR test case 2016-02-22 22:31:21 -05:00
Nirbhay Choubey
d45f0c117f refs codership/mysql-wsrep#198: Revert test changes from previous commit
Restore tests for FLUSH commands supported by MariaDB.
2016-02-22 22:30:14 -05:00
Teemu Ollakka
ea0b1837ed refs codership/mysql-wsrep#198 Removed code duplication, PXC specifics
* Total order isolation was started twice for FLUSH TABLES, from
  reload_acl_and_cache() and from mysql_execute_command(). Removed
  the reload_acl_and_cache() part.
* Removed PXC specific stuff from MTR tests
2016-02-22 22:21:29 -05:00
Daniele Sciascia
235bebe02e refs codership/mysql-wsrep#201
- Eliminates code duplication in query cache patch
- Reduces the number of iterations in mysql-wsrep#201.test
  to shorten the execution time
- Adds a new test case that exercises more scenarios
2016-02-22 22:10:51 -05:00
Nirbhay Choubey
17ac959716 Bug#1421360: Add Percona Server specific FLUSH statements.
- Restore FLUSH commands supported by MariaDB (removed in
the previous commit)
- Adjust test case
2016-02-22 22:07:59 -05:00
Teemu Ollakka
7d89deb0a3 refs codership/mysql-wsrep#198 fixed merge issues 2016-02-22 18:45:53 -05:00
Raghavendra D Prabhu
0ecc4fe2ac Bug#1421360: Add Percona Server specific FLUSH statements.
Added following:

        FLUSH CLIENT_STATISTICS
        FLUSH INDEX_STATISTICS
        FLUSH TABLE_STATISTICS
        FLUSH THREAD_STATISTICS
        FLUSH USER_STATISTICS

pertaining to USER STATISTICS
https://www.percona.com/doc/percona-server/5.6/diagnostics/user_stats.html

        FLUSH CHANGED_PAGE_BITMAPS

pertaining to changed page tracking.
https://www.percona.com/doc/percona-server/5.6/management/changed_page_tracking.html

Also, added tests for them.

(cherry picked from commit 7efe49010c7f217663f364657090812b4723f426)

Conflicts:
	mysql-test/suite/galera/r/galera_flush.result
	mysql-test/suite/galera/r/galera_flush_gtid.result
	mysql-test/suite/galera/t/galera_flush.test
	sql/sql_parse.cc
2016-02-22 18:00:28 -05:00
Raghavendra D Prabhu
1077eef942 PXC-391: Avoid Total Order Isolation (TOI) for LOCAL sql admin commands.
The admin commands in question are:
    > OPTIMIZE
    > REPAIR
    > ANALYZE

For LOCAL or NO_WRITE_TO_BINLOG invocations of these commands, ie

    OPTIMIZE LOCAL TABLE <t1>

they are not binlogged as expected.

Also, in addition, they are not executed under TOI.

Hence, they are not propagated to other nodes.

The effect is same as that of wsrep_on=0.

Also added tests for this.

A WSREP_DEBUG for wsrep_register_hton has also been added.

The galera_flush_local test has also been updated for verifying that effects
of  NO_WRITE_TO_BINLOG / LOCAL are equivalent to wsrep_on=0 from wsrep
perspective.

(cherry picked from commit 5065122f94a8002d4da231528a46f8d9ddbffdc2)

Conflicts:
	sql/sql_admin.cc
	sql/sql_reload.cc
	sql/wsrep_hton.cc
2016-02-22 17:59:06 -05:00
Philip Stoev
5be449d014 Galera MTR Tests: attempt to work around codership/QA#179 in galera_as_slave_nonprim.test 2016-02-22 17:53:58 -05:00
Philip Stoev
d794f05910 Galera MTR Tests: stability fix for galera_gcs_fragment.test (TCP port was output to the .result file) 2016-02-22 17:48:13 -05:00
Daniele Sciascia
ace86a2375 refs codership/mysql-wsrep#201
- Fixes query cache so that it is aware of wsrep_sync_wait.
  Query cache would return (possibly stale) results to the
  client, regardless of the value of wsrep_sync_wait.
- Includes the test case that reproduced the issue.
2016-02-22 17:46:22 -05:00
Teemu Ollakka
5ad30e8ad1 MTR test for checking correctness of fragmentation over CCs 2016-02-22 16:46:29 -05:00
Daniele Sciascia
c0dac420e5 refs codership/mysql-wsrep#31
- Removes useless call to wsrep_xid_init() in wsrep_apply_events().
  Transaction's xid is already initialized at that point.
- Adds call to wsrep_set_SE_checkpoint() for committing TOI events
  in the applier side.
- Includes test case that reproduced the issue.
2016-02-22 16:21:04 -05:00
Philip Stoev
7ce84cf764 Galera MTR Tests: stability fixes
Conflicts:
	mysql-test/include/mtr_check.sql
	mysql-test/suite/galera/r/galera_log_bin.result
	mysql-test/suite/galera/t/galera_log_bin.test
2016-02-22 14:43:35 -05:00
Teemu Ollakka
d01328d73b Helpers to deal with galera dbug sync points. 2016-02-22 12:58:02 -05:00
Vladislav Vaintroub
3a24f1cf84 MDEV-9307 - provide info about DATA/INDEX directory in INFORMATION_SCHEMA.TA
BLES (in CREATE_OPTIONS column)
2016-02-22 12:48:03 +01:00
Nirbhay Choubey
17b5cb6172 codership/mysql-wsrep#247: Fix test case 2016-02-17 22:56:38 -05:00
Philip Stoev
a6d93b20d7 Galera MTR Tests: MW-246 codership/mysql-wsrep#247 Stability fix for galera.mysql-wsrep#247.test 2016-02-17 16:05:11 -05:00
Philip Stoev
2438afbfde Galera MTR tests: MW-246 codership/mysql-wsrep#247 Additional tests around RSU and wsrep_desync 2016-02-17 16:04:06 -05:00
sjaakola
13627d49a9 refs MW-246
- created mtr test for testing explicit desyncing with RSU mode DDL
2016-02-17 16:03:40 -05:00
Sergei Golubchik
a4b2714968 Merge branch 'bb-10.0-serg' into 10.0 2016-02-17 21:42:57 +01:00
Jan Lindström
36ca65b73b MDEV-9559: Server without encryption configs crashes if selecting from an implicitly encrypted table
There was two problems. Firstly, if page in ibuf is encrypted but
decrypt failed we should not allow InnoDB to start because
this means that system tablespace is encrypted and not usable.
Secondly, if page decrypt is detected we should return false
from buf_page_decrypt_after_read.
2016-02-17 12:32:07 +02:00
Nirbhay Choubey
02259623b9 Update global_suppressions for galera suite to include new warning. 2016-02-16 17:14:11 -05:00
Sergei Golubchik
7e22a1d843 5.6.29 2016-02-16 18:56:39 +01:00
Sergei Golubchik
17a792a441 Merge branch 'merge-xtradb-5.6' into 10.0 2016-02-16 18:55:00 +01:00
Sergei Golubchik
c8fcaf8aec Merge branch 'merge-innodb-5.6' into 10.0 2016-02-16 18:32:59 +01:00
Sergey Vojtovich
e8085d1b41 MDEV-9346 - The federatedx and spider engine make mysqld crash when they are
configured withtout username

Federated/spider/connect engines or replication threads connecting to other host
with empty user name may crash mysqld.

This is addition to original patch, which adds a test case and amends a macro.
2016-02-16 18:40:04 +04:00
Sergei Golubchik
d520d35380 Revert "MDEV-8696: Adding indexes on empty table is slow with large innodb_sort_buffer_size."
This reverts commit 13884cf206.

Fixed in 5.6 (merged in the next commit)
2016-02-16 12:53:24 +01:00
Jan Lindström
ab9b6650c3 MDEV-9355: parts.partition_debug_innodb fails in buildbot on p8-rhel6-bintar-debug
At least on Linux test fails because too small buffer pool.
2016-02-16 10:49:13 +02:00
Sergei Golubchik
271fed4106 Merge branch '5.5' into 10.0 2016-02-15 22:50:59 +01:00
Jan Lindström
c0b6c27dbe MDEV-9548: Alter table (renaming and adding index) fails with "Incorrect key file for table"
MDEV-9469: 'Incorrect key file' on ALTER TABLE

InnoDB needs to rebuild table if column name is changed and
added index (or foreign key) is created based on this new
name in same alter table.
2016-02-15 14:48:15 +02:00
Sergei Golubchik
3c6b771753 MDEV-9045 Inconsistent handling of "ALGORITHM=INPLACE" with PERSISTENT generated columns
Only set Alter_inplace_info::ALTER_COLUMN_VCOL flag if
a vcol might be affected by the ALTER TABLE statement
2016-02-15 13:02:21 +01:00
Sergei Golubchik
1fc6e297f2 XtraDB/InnoDB crash with autoinc, vcol and online alter
Fix the doubly questional fix for MySQL Bug#17250787:
* it detected autoinc index by looking for the first index
  that starts from autoinc column. never mind one column
  can be part of many indexes.
* it used autoinc_field->field_index to look up into internal
  innodb dictionary. But field_index accounts for virtual
  columns too, while innodb dictionary ignores them.

Find the index by its name, like elsewhere in ha_innobase.
2016-02-15 13:02:21 +01:00
Nirbhay Choubey
d23bd26bec Merge tag 'mariadb-5.5.48' into 5.5-galera 2016-02-13 18:28:36 -05:00
Elena Stepanova
2c79f57530 MDEV-9464 perfschema.global_read_lock fails when executed after perfschema.dml_setup_instruments
dml_setup_instruments did not restore settings in setup_instruments table
after updating it as a part of the test flow
2016-02-12 03:47:25 +02:00
Daniele Sciascia
bd1d2b90a7 refs codership/mysql-wsrep#201
Removes MTR tests.
2016-02-10 17:42:42 -05:00
Daniele Sciascia
0c7dffe9e1 refs codership/mysql-wsrep#201
- Eliminates code duplication in query cache patch
- Reduces the number of iterations in mysql-wsrep#201.test
  to shorten the execution time
- Adds a new test case that exercises more scenarios
2016-02-09 21:52:42 -05:00
Daniele Sciascia
8a71fde01f refs codership/mysql-wsrep#201
- Fixes query cache so that it is aware of wsrep_sync_wait.
  Query cache would return (possibly stale) results to the
  client, regardless of the value of wsrep_sync_wait.
- Includes the test case that reproduced the issue.
2016-02-09 21:28:54 -05:00
Sergei Golubchik
01628ce35a Merge branch 'bb-5.5-serg' into 5.5 2016-02-09 14:08:36 +01:00
Sergei Golubchik
f3444df415 Merge branch 'mysql/5.5' into 5.5
reverted about half of commits as either not applicable or
outright wrong
2016-02-09 11:27:40 +01:00
Alexey Botchkov
ea0c3fc87b MDEV-9438 backport feedback-http-proxy to 5.5 and 10.0.
The http-proxy option to the FEEDBACK plugin backported.
2016-02-09 05:19:56 +04:00
Oleksandr Byelkin
9f3b53fb4a MDEV-9093 Persistent computed column is not updated when update query contains join
added lost virtual fields update call
2016-02-05 16:32:12 +01:00
Monty
11c2d3c3e2 Merge branch '10.0' into 10.1
Conflicts:
	configure.cmake
2016-02-02 13:07:53 +02:00
Elena Stepanova
0bee1504a3 MDEV-9502 maria.encrypt-wrong-key fails with embedded server
The test restarts the server, it should not be executed for embedded
2016-02-01 01:01:29 +02:00
Monty
7b14ba63f2 MDEV-8724 Assertion `rc == 0' failed in ma_decrypt on reading an Aria table
Don't assert if decrypt or encrypt fails if my_assert_on_error is not set.
Added failed file name if encryption/decryption fails.
2016-01-28 14:06:05 +02:00
Alexey Botchkov
a4ff37e912 MDEV-6421 SQL_ERROR_LOG doesn't log comments in Events.
Change parser so it saves all the query line to the ';' in the
    sp_instr::m_query.
2016-01-26 22:33:25 +04:00
Sergei Golubchik
f4faac4d6a Merge branch '10.0' into 10.1 2016-01-25 22:58:57 +01:00
Sergei Golubchik
68910e7092 MDEV-9273 ERROR 1819 on grant statment for existing user
Cannot do password validation in fix_lex_user(), we don't know
there what "GRANT ... TO user" means - creating a new user with
an empty password (need validation) or granting privileges
to an existing user (no validation needed).

Move validation down into replace_user_table(). And copy into
check_change_password().
2016-01-25 22:57:53 +01:00
Sergei Golubchik
d5b1b1ac60 stack too small on labrador (again!)
increase the thread stack a bit for main.signal_demo3
and sys_vars.max_sp_recursion_depth_func to stop failing
2016-01-25 22:57:47 +01:00