summaryrefslogtreecommitdiff
path: root/storage/innobase/dict/dict0dict.c
Commit message (Collapse)AuthorAgeFilesLines
* Temporary commit of merge of MariaDB 10.0-base and MySQL 5.6Michael Widenius2012-08-011-5258/+0
|
* merge mysql-5.5->mysql-5.5-securityGeorgi Kodinov2012-03-081-5/+17
|\
| * Merge mysql-5.1 to mysql-5.5.Marko Mäkelä2012-02-281-5/+17
| |\
* | | Bug#13635833: MULTIPLE CRASHES IN FOREIGN KEY CODE WITH CONCURRENT DDL/DMLAnnamalai Gurusami2012-02-271-3/+7
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are two threads. In one thread, dml operation is going on involving cascaded update operation. In another thread, alter table add foreign key constraint is happening. Under these circumstances, it is possible for the dml thread to access a dict_foreign_t object that has been freed by the ddl thread. The debug sync test case provides the sequence of operations. Without fix, the test case will crash the server (because of newly added assert). With fix, the alter table stmt will return an error message. rb:947 approved by Jimmy Yang
* | Bug #13116225 LIVE DOWNGRADE CRASHES WITH INNODB_PAGE_SIZE=4Kunknown2011-12-081-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This bug ensures that a live downgrade from an InnoDB 5.6 with WL5756 and a database created with innodb-page-size=8k or 4k will make a version 5.5 installation politely refuse to start. Instead of crashing or giving some indication about a corrupted database, it will indicate the page size difference. This patch takes only that part of the Wl5756 patch that is needed to protect against opening a tablespace that is stamped with a different page size. It also contains the change in dict_index_find_on_id_low() just in case a database with another page size is created by recompiling a pre-WL5756 InnoDB.
* | Fix Bug #13083023 - 60229: BROKEN COMPATIBILITY: ERROR WHILE CREATE TABLEJimmy Yang2011-12-071-0/+5
| | | | | | | | | | | | | | WITH FOREIGN KEY CONSTRAI rb://844 approved by marko
* | Fix Bug 12922077 - SEGV IN DICT_SET_CORRUPTED_INDEX_CACHE_ONLY(), DROP TABLEJimmy Yang2011-08-291-2/+10
| | | | | | | | | | rb://752 approved by Sunny Bains
* | Fix bug #11830883, SUPPORT "CORRUPTED" BIT FOR INNODB TABLES AND INDEXES.Jimmy Yang2011-08-161-2/+177
| | | | | | | | | | | | | | Also addressed issues in bug #11745133, where we could mark a table corrupted instead of crashing the server when found a corrupted buffer/page if the table created with innodb_file_per_table on.
* | Merge mysql-5.1 to mysql-5.5. Add a test case.Marko Mäkelä2011-08-151-2/+3
|\ \ | |/
* | Implement worklog #5743 InnoDB: Lift the limit of index key prefixes. Jimmy Yang2011-05-311-13/+47
| | | | | | | | | | | | | | | | With this change, the index prefix column length lifted from 767 bytes to 3072 bytes if "innodb_large_prefix" is set to "true". rb://603 approved by Marko
* | Bug#60309 - Bug#12356829: MYSQL 5.5.9 FOR MAC OSX HAS BUG WITH FOREIGN KEY ↵unknown2011-04-261-3/+2
| | | | | | | | | | | | | | | | | | | | CONSTRAINTS The innoDB global variable srv_lower_case_table_names is set to the value of lower_case_table_names declared in mysqld.h server in ha_innodb.cc. Since this variable can change at runtime, it is reset for each handler call to ::create, ::open, ::rename_table & ::delete_table. But it is possible for tables to be implicitly opened before an explicit handler call is made when an engine is first started or restarted. I was able to reproduce that with the testcase in this patch on a version of InnoDB from 2 weeks ago. It seemed like the change buffer entries for the secondary key was getting put into pages after the restart. (But I am not sure, I did not write down the call stack while it was reproducing.) In the current code, the implicit open, which is actually a call to dict_load_foreigns(), does not occur with this testcase. The change is to replace srv_lower_case_table_names by an interface function in innodb.cc that retrieves the server global variable when it is needed.
* | Merge from mysql-5.5.9-releaseJonathan Perkin2011-02-081-5/+5
|\ \
| * \ mergeGeorgi Kodinov2011-01-101-30/+43
| |\ \
| * | | Fix Bug #58643 InnoDB: too long table nameJimmy Yang2010-12-051-5/+5
| | | | | | | | | | | | | | | | | | | | rb://531 approved by Sunny Bains
* | | | Merge from mysql-5.1-innodb to mysql-5.5-innodbJimmy Yang2011-01-141-0/+10
|\ \ \ \ | |_|/ / |/| | / | | |/ | |/|
| * | Fix Bug#30423 "InnoDBs treatment of NULL in index stats causes bad Jimmy Yang2011-01-141-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | "rows examined" estimates". This change implements "innodb_stats_method" with options of "nulls_equal", "nulls_unequal" and "null_ignored". rb://553 approved by Marko
* | | merge from mysql-5.1-innodb to mysql-5.5-innodbJimmy Yang2011-01-051-1/+1
|\ \ \ | |/ /
| * | Fix Bug #59197 double quote in field comment prevents foreign keyJimmy Yang2011-01-041-1/+1
| | | | | | | | | | | | | | | | | | | | | constraint creation rb://557 Approved by Sunny Bains
* | | PS-instrument the array of latches (rw locks) dict_table_stats_latches[].Vasil Dimov2011-01-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds 64 new rows to performance_schema.rwlock_instances. This patch will make perfschema.binlog_mix perfschema.binlog_row tests fail, but they will be fixed by http://lists.mysql.com/commits/127862 Approved by: Jimmy (rb://554)
* | | Bug#55222 - RB://517 - Approved by Sunnyunknown2010-11-301-28/+40
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | InnoDB does not attempt to handle lower_case_table_names == 2 when looking up foreign table names and referenced table name. It turned that server variable into a boolean and ignored the possibility of it being '2'. The setting lower_case_table_names == 2 means that it should be stored and displayed in mixed case as given, but compared internally in lower case. Normally the server deals with this since it stores table names. But InnoDB stores referential constraints for the server, so it needs to keep track of both lower case and given names. This solution creates two table name pointers for each foreign and referenced table name. One to display the name, and one to look it up. Both pointers point to the same allocated string unless this setting is 2. So the overhead added is not too much. Two functions are created in dict0mem.c to populate the ..._lookup versions of these pointers. Both dict_mem_foreign_table_name_lookup_set() and dict_mem_referenced_table_name_lookup_set() are called 5 times each.
* | Fix Bug #16290 Unclear error message when adding foreign key constraintJimmy Yang2010-11-141-2/+2
| | | | | | | | | | rb://502 approved by Sunny Bains
* | Merge mysql-5.1-innodb -> mysql-5.5-innodbVasil Dimov2010-11-111-25/+4
|\ \ | |/
* | Merge from mysql-5.1-innodb to mysql-5.5-innodbJimmy Yang2010-11-101-2/+9
|\ \ | |/
* | Merge mysql-5.1-innodb -> mysql-5.5-innodbVasil Dimov2010-11-031-49/+93
|\ \ | |/
| * Bug#55832: selects crash too easily when innodb_force_recovery>3Marko Mäkelä2010-08-231-21/+34
| | | | | | | | | | | | | | | | | | | | dict_update_statistics_low(): Create bogus statistics for those indexes that cannot be accessed because of the innodb_force_recovery setting. ha_innobase::info(): Calculate statistics for each index, even if innodb_force_recovery is set. Fill in bogus data for those indexes that are not accessed because of the innodb_force_recovery setting.
| * Fix Bug #55027: assertion: mutex_own(&dict_sys->mutex) in dict_table_get_on_id()Sunny Bains2010-08-201-2/+1
| | | | | | | | | | | | | | | | | | The callers should indicate that the dictionary is locked or not using the trx->dict_operation_lock_mode == RW_X_LATCH mode. Checking explicitly for system tables is unnecessary. Approved by Marko on IRC.
| * Address bug #55465 ERROR 1280 (42000): Incorrect index name '<index name>',Jimmy Yang2010-08-061-2/+2
| | | | | | | | | | | | | | adding a couple FK related messages. rb://409 approved by Sunny Bains
| * Fix bug#54583. This change reverses rsvn:1350 by getting rid of a bogus ↵Sunny Bains2010-06-251-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | assertion and clarifies the invariant in dict_table_get_on_id(). In Mar 2007 Marko observed a crash during recovery, the crash resulted from an UNDO operation on a system table. His solution was to acquire an X lock on the data dictionary, this in hindsight was an overkill. It is unclear what caused the crash, current hypothesis is that it was a memory corruption. The X lock results in performance issues by when undoing changes due to rollback during normal operation on regular tables. Why the change is safe: ====================== The InnoDB code has changed since the original X lock change was made. In the new code we always lock the data dictionary in X mode during startup when UNDOing operations on the system tables (this is a given). This ensures that the crash Marko observed cannot happen as long as all transactions that update the system tables follow the standard rules by setting the appropriate DICT_OP flag when writing the log records when they make the changes. If transactions violate the above mentioned rule then during recovery (at startup) the rollback code (see trx0roll.c) will not acquire the X lock and we will see the crash again. This will however be a different bug.
| * Make the InnoDB FOREIGN KEY parser understand multi-statements. (Bug #48024)Marko Mäkelä2010-05-141-19/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also make InnoDB thinks that /*/ only starts a comment. (Bug #53644). struct trx_struct: Add mysql_query_len. ha_innodb.cc: Use trx_query_string() instead of trx_query() and initialize trx->mysql_query_len. INNOBASE_COPY_STMT(thd, trx): New macro, to initialize trx->mysql_query_str and trx->mysql_query_len. dict_strip_comments(): Add and observe the parameter sql_length. Treat /*/ as the start of a comment. dict_create_foreign_constraints(), row_table_add_foreign_constraints(): Add the parameter sql_length.
* | (dict0dict.c:4458) Bug#55227 Fix compiler warnings in innodb with gcc 4.6Vasil Dimov2010-09-201-9/+0
| |
* | Merge Bug#55832 fix from mysql-5.1-innodb:Marko Mäkelä2010-08-241-21/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ------------------------------------------------------------ revno: 3550 revision-id: marko.makela@oracle.com-20100824081003-v4ecy0tga99cpxw2 parent: marko.makela@oracle.com-20100823102854-t1clrojqis2ley36 committer: Marko Mäkelä <marko.makela@oracle.com> branch nick: 5.1-innodb timestamp: Tue 2010-08-24 11:10:03 +0300 message: Bug#55832: selects crash too easily when innodb_force_recovery>3 dict_update_statistics_low(): Create bogus statistics for those indexes that cannot be accessed because of the innodb_force_recovery setting. ha_innobase::info(): Calculate statistics for each index, even if innodb_force_recovery is set. Fill in bogus data for those indexes that are not accessed because of the innodb_force_recovery setting.
* | Fix bug#54583. This change reverses r1530 by getting rid of a bogus assertionSunny Bains2010-06-251-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and clarifies the invariant in dict_table_get_on_id(). In Mar 2007 Marko observed a crash during recovery, the crash resulted from an UNDO operation on a system table. His solution was to acquire an X lock on the data dictionary, this in hindsight was an overkill. It is unclear what caused the crash, current hypothesis is that it was a memory corruption. The X lock results in performance issues by when undoing changes due to rollback during normal operation on regular tables. Why the change is safe: ====================== The InnoDB code has changed since the original X lock change was made. In the new code we always lock the data dictionary in X mode during startup when UNDOing operations on the system tables (this is a given). This ensures that the crash Marko observed cannot happen as long as all transactions that update the system tables follow the standard rules by setting the appropriate DICT_OP flag when writing the log records when they make the changes. If transactions violate the above mentioned rule then during recovery (at startup) the rollback code (see trx0roll.c) will not acquire the X lock and we will see the crash again. This will however be a different bug.
* | Bug#54728: Replace the dulint struct with a 64-bit integer.Marko Mäkelä2010-06-231-27/+23
| |
* | Merge Bug#47991 fix from mysql-5.1-innodbVasil Dimov2010-06-231-8/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ------------------------------------------------------------ revno: 3517 revision-id: vasil.dimov@oracle.com-20100622163043-dc0lxy0byg74viet parent: marko.makela@oracle.com-20100621095148-8g73k8k68dpj080u committer: Vasil Dimov <vasil.dimov@oracle.com> branch nick: mysql-5.1-innodb timestamp: Tue 2010-06-22 19:30:43 +0300 message: Fix Bug#47991 InnoDB Dictionary Cache memory usage increases indefinitely when renaming tables Allocate the table name using ut_malloc() instead of table->heap because the latter cannot be freed. Adjust dict_sys->size calculations all over the code. Change dict_table_t::name from const char* to char* because we need to ut_malloc()/ut_free() it. Reviewed by: Inaam, Marko, Heikki (rb://384) Approved by: Heikki (rb://384) ------------------------------------------------------------
* | Merge from mysql-5.1-innodb:Marko Mäkelä2010-05-141-19/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Post-merge fixes: Remove the MYSQL_VERSION_ID checks, because they only apply to the InnoDB Plugin. Fix potential race condition accessing trx->op_info and trx->detailed_error. ------------------------------------------------------------ revno: 3466 revision-id: marko.makela@oracle.com-20100514130815-ym7j7cfu88ro6km4 parent: marko.makela@oracle.com-20100514130228-n3n42nw7ht78k0wn committer: Marko Mäkelä <marko.makela@oracle.com> branch nick: mysql-5.1-innodb2 timestamp: Fri 2010-05-14 16:08:15 +0300 message: Make the InnoDB FOREIGN KEY parser understand multi-statements. (Bug #48024) Also make InnoDB thinks that /*/ only starts a comment. (Bug #53644). This fixes the bugs in the InnoDB Plugin. ha_innodb.h: Use trx_query_string() instead of trx_query() when available (MySQL 5.1.42 or later). innobase_get_stmt(): New function, to retrieve the currently running SQL statement. struct trx_struct: Remove mysql_query_str. Use innobase_get_stmt() instead. dict_strip_comments(): Add and observe the parameter sql_length. Treat /*/ as the start of a comment. dict_create_foreign_constraints(), row_table_add_foreign_constraints(): Add the parameter sql_length.
* | Followup to vasil.dimov@oracle.com-20100504104629-0ovtc5lae2ghn7he :Vasil Dimov2010-05-041-1/+2
| | | | | | | | | | Add the missing parameter to mutex_create().
* | Merge from mysql-5.1-innodb:Vasil Dimov2010-05-041-0/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ------------------------------------------------------------ revno: 3430 revision-id: vasil.dimov@oracle.com-20100428103452-6btsq4xv6v1etb5b parent: vasil.dimov@oracle.com-20100428103200-vs5nzx245sv2qy7n committer: Vasil Dimov <vasil.dimov@oracle.com> branch nick: mysql-5.1-innodb timestamp: Wed 2010-04-28 13:34:52 +0300 message: Bug#53046 dict_update_statistics_low can still be run concurrently on same table Followup to vasil.dimov@oracle.com-20100428102033-dt3caf531rs3lidr : Add more asserions, which I forgot. modified: storage/innodb_plugin/dict/dict0dict.c 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fdict%2Fdict0dict.c ------------------------------------------------------------ revno: 3429 revision-id: vasil.dimov@oracle.com-20100428103200-vs5nzx245sv2qy7n parent: vasil.dimov@oracle.com-20100428102033-dt3caf531rs3lidr committer: Vasil Dimov <vasil.dimov@oracle.com> branch nick: mysql-5.1-innodb timestamp: Wed 2010-04-28 13:32:00 +0300 message: Revert the fix of Bug#38996 Race condition in ANALYZE TABLE This is branches/zip@r6032 in SVN and _is part_ of revid:svn-v4:16c675df-0fcb-4bc9-8058-dcc011a37293:branches/zip:6113 in BZR. This is being reverted because now the code is serialized directly on index->stat_n_diff_key_vals[] as the fix for Bug#53046 dict_update_statistics_low can still be run concurrently on same table goes. modified: storage/innodb_plugin/handler/ha_innodb.cc 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fhandler%2Fha_innodb.cc ------------------------------------------------------------ revno: 3428 revision-id: vasil.dimov@oracle.com-20100428102033-dt3caf531rs3lidr parent: vasil.dimov@oracle.com-20100428084627-wtrmc66wqvjsdgj7 committer: Vasil Dimov <vasil.dimov@oracle.com> branch nick: mysql-5.1-innodb timestamp: Wed 2010-04-28 13:20:33 +0300 message: Followup to vasil.dimov@oracle.com-20100428084627-wtrmc66wqvjsdgj7: Address Marko's suggestions wrt the fix of Bug#53046 dict_update_statistics_low can still be run concurrently on same table modified: storage/innodb_plugin/dict/dict0dict.c 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fdict%2Fdict0dict.c ------------------------------------------------------------ revno: 3427 revision-id: vasil.dimov@oracle.com-20100428084627-wtrmc66wqvjsdgj7 parent: mmakela@bk-internal.mysql.com-20100428063325-irts4ze9et5bsqdq committer: Vasil Dimov <vasil.dimov@oracle.com> branch nick: mysql-5.1-innodb timestamp: Wed 2010-04-28 11:46:27 +0300 message: Fix Bug#53046 dict_update_statistics_low can still be run concurrently on same table Protect dict_index_t::stat_n_diff_key_vals[] with an array of mutexes. Testing: tested all code paths under UNIV_SYNC_DEBUG for the one in dict_print() one has to enable the InnoDB table monitor: CREATE TABLE innodb_table_monitor (a int) ENGINE=INNODB; modified: storage/innodb_plugin/btr/btr0cur.c 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fbtr%2Fbtr0cur.c storage/innodb_plugin/dict/dict0dict.c 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fdict%2Fdict0dict.c storage/innodb_plugin/handler/ha_innodb.cc 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Fhandler%2Fha_innodb.cc storage/innodb_plugin/include/dict0dict.h 2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Finclude%2Fdict0dict.h ------------------------------------------------------------
* | Import branches/innodb+ from SVN on top of storage/innobase.Vasil Dimov2010-04-121-12/+32
| |
* | Merge Innodb Plugin 1.0.6 from mysql-5.1-bugteam storage/innodb_plugin to ↵Satya B2009-12-021-1/+72
|\ \ | |/ | | | | | | | | mysql-trunk-merge. Merging revisions 3221 to 3230 from mysql-5.1-bugteam
| * Applying InnoDB snapshot 5.1-ss5921, part 2. Fixes BUG#44369Satya B2009-10-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BUG#44369 - InnoDB: Does not uniformly disallow disallowed column names Detailed revision comments: r5741 | jyang | 2009-09-03 07:16:01 +0300 (Thu, 03 Sep 2009) | 5 lines branches/5.1: Block creating table with column name conflicting with Innodb reserved key words. (Bug #44369) rb://151 approved by Sunny Bains. r5760 | jyang | 2009-09-04 07:07:34 +0300 (Fri, 04 Sep 2009) | 3 lines branches/5.1: This is to revert change 5741. A return status for create_table_def() needs to be fixed. r5834 | jyang | 2009-09-11 00:43:05 +0300 (Fri, 11 Sep 2009) | 5 lines branches/5.1: Block creating table with column name conflicting with Innodb reserved key words. (Bug #44369) rb://151 approved by Sunny Bains.
* | Merging Innodb plugin 1.0.5 revisions from 5.1-main from revisions 3149 to 3163Satya B2009-10-161-8/+17
| | | | | | | | also merged missing Innodb plugin revisions r5636,r5635 manually
* | Renamed storage/innodb_plugin to storage/innobase, so that 1) it's the sameGuilhem Bichot2009-08-071-0/+4771
| | | | | | | | | | | | | | | | | | | | | | | | | | | | layout as we always had in trees containing only the builtin 2) win\configure.js WITH_INNOBASE_STORAGE_ENGINE still works. storage/innobase/CMakeLists.txt: fix to new directory name (and like 5.1) storage/innobase/Makefile.am: fix to new directory name (and like 5.1) storage/innobase/handler/ha_innodb.cc: fix to new directory name (and like 5.1) storage/innobase/plug.in: fix to new directory name (and like 5.1)
* | Creation of mysql-trunk = {summit + "Innodb plugin replacing the builtin"}:Guilhem Bichot2009-08-041-4253/+0
|\ \ | |/ | | | | | | | | | | | | bzr branch mysql-5.1-performance-version mysql-trunk # Summit cd mysql-trunk bzr merge mysql-5.1-innodb_plugin # which is 5.1 + Innodb plugin bzr rm innobase # remove the builtin Next step: build, test fixes.
| * merge to 5.1-bugteam treeSatya B2009-05-191-1/+1
| |\
| | * 5.0-bugteam->5.1-bugteam mergeSergey Glukhov2009-05-191-1/+1
| |/ |/|
| * Applying InnoDB snashot 5.1-ss5024, part 2. Fix for BUG#44320Satya B2009-05-191-1/+1
|/ | | | | | | | | | | | | | | BUG#44320 - InnoDB: missing DB_ROLL_PTR in Table Monitor COLUMNS output Detailed revision comments: r4976 | marko | 2009-05-13 15:44:54 +0300 (Wed, 13 May 2009) | 6 lines branches/5.1: Display DB_ROLL_PTR in the COLUMNS section of the innodb_table_monitor output. It was accidentally omitted due to an off-by-one loop condition. (Bug #44320) rb://116 approved by Heikki Tuuri
* Apply InnoDB snapshot innodb-5.1-ss2858, part 15. FixesTimothy Smith2008-12-141-17/+8
| | | | | | | | | | | | | | | | | | | Bug #39830: Table autoinc value not updated on first insert. Bug #35498: Cannot get table test/table1 auto-inccounter value in ::info Bug #36411: Failed to read auto-increment value from storage engine" in 5.1.24 auto-inc Detailed revision comments: r2854 | sunny | 2008-10-23 08:30:32 +0300 (Thu, 23 Oct 2008) | 13 lines branches/5.1: Backport changes from branches/zip r2725 Simplify the autoinc initialization code. This removes the non-determinism related to reading the table's autoinc value for the first time. This change has also reduced the sizeof dict_table_t by sizeof(ibool) bytes because we don't need the dict_table_t::autoinc_inited field anymore. rb://16
* Complete application of InnoDB snapshot innodb-5.1-ss2545.Timothy Smith2008-12-141-0/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix race condition which could result in freeing a struct that is still in use by another thread. Detailed revision comments: r2537 | inaam | 2008-07-15 20:46:03 +0300 (Tue, 15 Jul 2008) | 12 lines branches/5.1 issue# 4 Fixed a timing hole where a thread dropping an index can free the in-memory index struct while another thread is still using that structure to remove entries from adaptive hash index belonging to one of the pages that belongs to the index being dropped. The fix is to have a reference counter in the index struct and to wait for this counter to drop to zero beforing freeing the struct. Reviewed by: Heikki r2543 | inaam | 2008-07-22 18:57:43 +0300 (Tue, 22 Jul 2008) | 7 lines branches/5.1: Removed UNIV_INLINE qualifier from btr_search_info_get_ref_count(). Otherwise compilation failed on non-debug builds. Pointed by: Vasil
* apply snapshot innodb-5.1-ss2387unknown2008-03-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ------------------------------------------------------------------------ r2361 | sunny | 2008-03-12 09:08:09 +0200 (Wed, 12 Mar 2008) | 3 lines Changed paths: M /branches/5.1/include/srv0srv.h M /branches/5.1/os/os0file.c M /branches/5.1/srv/srv0srv.c M /branches/5.1/srv/srv0start.c branches/5.1: Remove the innodb_flush_method fdatasync option since it was not being used and there was a potential it could mislead users. ------------------------------------------------------------------------ r2367 | marko | 2008-03-17 10:23:03 +0200 (Mon, 17 Mar 2008) | 5 lines Changed paths: M /branches/5.1/handler/ha_innodb.cc branches/5.1: ha_innobase::check_if_incompatible_data(): Check HA_CREATE_USED_ROW_FORMAT before comparing row_type. Previously, the comparison was incorrectly guarded by the presence of an AUTO_INCREMENT attribute. ------------------------------------------------------------------------ r2374 | vasil | 2008-03-18 09:35:30 +0200 (Tue, 18 Mar 2008) | 11 lines Changed paths: M /branches/5.1/dict/dict0dict.c A /branches/5.1/mysql-test/innodb_bug35220.result A /branches/5.1/mysql-test/innodb_bug35220.test branches/5.1: Fix Bug#35220 ALTER TABLE too picky on reserved word "foreign". In ALTER TABLE, change the internal parser to search for ``FOREIGN[[:space:]]'' instead of only ``FOREIGN'' when parsing ALTER TABLE ... DROP FOREIGN KEY ...; otherwise it could be mistaken with ALTER TABLE ... DROP foreign_col; Approved by: Heikki ------------------------------------------------------------------------ r2379 | vasil | 2008-03-19 18:48:00 +0200 (Wed, 19 Mar 2008) | 10 lines Changed paths: M /branches/5.1/os/os0file.c branches/5.1: Fix Bug#34823: fsync() occasionally returns ENOLCK and causes InnoDB to restart mysqld Create a wrapper to fsync(2) that retries the operation if the error is ENOLCK. Use that wrapper instead of fsync(2). Approved by: Heikki ------------------------------------------------------------------------ r2380 | sunny | 2008-03-21 05:03:56 +0200 (Fri, 21 Mar 2008) | 9 lines Changed paths: M /branches/5.1/include/trx0undo.h M /branches/5.1/trx/trx0trx.c M /branches/5.1/trx/trx0undo.c branches/5.1: Fix for Bug# 35352. We've added a heuristic that checks the size of the UNDO slots cache lists (insert and upate). If either of cached lists has more than 500 entries then we add any UNDO slots that are freed, to the common free list instead of the cache list, this is to avoid the case where all the free slots end up in only one of the lists on startup after a crash. Tested with test case for 26590 and passes all mysql-test(s). ------------------------------------------------------------------------ r2383 | vasil | 2008-03-26 09:35:22 +0200 (Wed, 26 Mar 2008) | 4 lines Changed paths: M /branches/5.1/include/row0mysql.h branches/5.1: Fix typo in comment. ------------------------------------------------------------------------ r2384 | vasil | 2008-03-26 18:26:54 +0200 (Wed, 26 Mar 2008) | 20 lines Changed paths: A /branches/5.1/mysql-test/innodb_bug34300.result A /branches/5.1/mysql-test/innodb_bug34300.test M /branches/5.1/row/row0sel.c branches/5.1: Fix Bug#34300 Tinyblob & tinytext fields currupted after export/import and alter in 5.1 Copy the BLOB fields, that are stored internally, to a safe place (prebuilt->blob_heap) when converting a row from InnoDB format to MySQL format in row_sel_store_mysql_rec(). The bug was introduced in: ------------------------------------------------------------------------ r587 | osku | 2006-05-23 15:35:58 +0300 (Tue, 23 May 2006) | 3 lines Optimize BLOB selects by using prebuilt->blob_heap directly instead of first reading BLOB data to a temporary heap and then copying it to prebuilt->blob_heap. ------------------------------------------------------------------------ Approved by: Heikki ------------------------------------------------------------------------ r2386 | vasil | 2008-03-27 07:45:02 +0200 (Thu, 27 Mar 2008) | 22 lines Changed paths: M /branches/5.1/mysql-test/innodb.result branches/5.1: Merge change from MySQL (this fixes the failing innodb test): ChangeSet@1.1810.3601.4, 2008-02-07 02:33:21+04:00, gshchepa@host.loc +9 -0 Fixed bug#30059. Server handles truncation for assignment of too-long values into CHAR/VARCHAR/TEXT columns in a different ways when the truncated characters are spaces: 1. CHAR(N) columns silently ignore end-space truncation; 2. TEXT columns post a truncation warning/error in the non-strict/strict mode. 3. VARCHAR columns always post a truncation note in any mode. Space truncation processing has been synchronised over CHAR/VARCHAR/TEXT columns: current behavior of VARCHAR columns has been propagated as standard. Binary-encoded string/BLOB columns are not affected. ------------------------------------------------------------------------ r2387 | vasil | 2008-03-27 08:49:05 +0200 (Thu, 27 Mar 2008) | 8 lines Changed paths: M /branches/5.1/row/row0sel.c branches/5.1: Check whether *trx->mysql_query_str is != NULL in addition to trx->mysql_query_str. This adds more safety. This may or may not fix Bug#35226 RBR event crashes slave. ------------------------------------------------------------------------ storage/innobase/dict/dict0dict.c: apply snapshot innodb-5.1-ss2387 storage/innobase/handler/ha_innodb.cc: apply snapshot innodb-5.1-ss2387 storage/innobase/include/row0mysql.h: apply snapshot innodb-5.1-ss2387 storage/innobase/include/srv0srv.h: apply snapshot innodb-5.1-ss2387 storage/innobase/include/trx0undo.h: apply snapshot innodb-5.1-ss2387 storage/innobase/os/os0file.c: apply snapshot innodb-5.1-ss2387 storage/innobase/row/row0sel.c: apply snapshot innodb-5.1-ss2387 storage/innobase/srv/srv0srv.c: apply snapshot innodb-5.1-ss2387 storage/innobase/srv/srv0start.c: apply snapshot innodb-5.1-ss2387 storage/innobase/trx/trx0trx.c: apply snapshot innodb-5.1-ss2387 storage/innobase/trx/trx0undo.c: apply snapshot innodb-5.1-ss2387
* Apply innodb-5.1-ss2360 snapshotunknown2008-03-271-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes: - Bug #34920: auto_increment resets to 1 on foreign key creation We need to use/inherit the passed in autoinc counter for ALTER TABLE statements too. mysql-test/r/innodb.result: Apply innodb-5.1-ss2360 snapshot Revision r2345: branches/5.1: Fix Bug# 34920. We need to use/inherit the passed in autoinc counter for ALTER TABLE statements too. mysql-test/t/innodb.test: Apply innodb-5.1-ss2360 snapshot Revision r2345: branches/5.1: Fix Bug# 34920. We need to use/inherit the passed in autoinc counter for ALTER TABLE statements too. storage/innobase/dict/dict0dict.c: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/handler/ha_innodb.cc: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. Revision r2345: branches/5.1: Fix Bug# 34920. We need to use/inherit the passed in autoinc counter for ALTER TABLE statements too. storage/innobase/handler/ha_innodb.h: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/include/dict0dict.h: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/include/dict0mem.h: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/include/row0sel.h: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/include/univ.i: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned. storage/innobase/row/row0sel.c: Apply innodb-5.1-ss2360 snapshot Revision r2353: branches/5.1: Change the InnoDB autoinc type to ulint64. For this added a new typedef to univ.i (ib_ulonglong). Added checks for overflow and removed the assertion where it crashed previously, since the type has now changed to unsigned, it doesn't make sense to check for < 0. Added new tests, to check for overflow, for the different INT types supported for both signed and unsigned.