diff options
author | Yasufumi Kinoshita <yasufumi.kinoshita@oracle.com> | 2012-01-10 14:23:20 +0900 |
---|---|---|
committer | Yasufumi Kinoshita <yasufumi.kinoshita@oracle.com> | 2012-01-10 14:23:20 +0900 |
commit | ad6a4986eb6fef7bf0fca81670c25abd698baf5a (patch) | |
tree | 5c8822a715af57264d53191c97505762f326a206 /storage/innobase/include | |
parent | 85f874184f4493149cb59f0cd2c77b5ac0ba73fd (diff) | |
parent | 115f5e8551b9243ef3ca98ce882993fb78c426e1 (diff) | |
download | mariadb-git-ad6a4986eb6fef7bf0fca81670c25abd698baf5a.tar.gz |
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
Diffstat (limited to 'storage/innobase/include')
-rw-r--r-- | storage/innobase/include/trx0rseg.ic | 9 | ||||
-rw-r--r-- | storage/innobase/include/trx0sys.h | 6 |
2 files changed, 14 insertions, 1 deletions
diff --git a/storage/innobase/include/trx0rseg.ic b/storage/innobase/include/trx0rseg.ic index daffa92fc7d..5e8d2b41120 100644 --- a/storage/innobase/include/trx0rseg.ic +++ b/storage/innobase/include/trx0rseg.ic @@ -25,6 +25,7 @@ Created 3/26/1996 Heikki Tuuri #include "srv0srv.h" #include "mtr0log.h" +#include "trx0sys.h" /******************************************************************//** Gets a rollback segment header. @@ -131,7 +132,13 @@ trx_rsegf_undo_find_free( ulint i; ulint page_no; - for (i = 0; i < TRX_RSEG_N_SLOTS; i++) { + for (i = 0; +#ifndef UNIV_DEBUG + i < TRX_RSEG_N_SLOTS; +#else + i < (trx_rseg_n_slots_debug ? trx_rseg_n_slots_debug : TRX_RSEG_N_SLOTS); +#endif + i++) { page_no = trx_rsegf_get_nth_undo(rsegf, i, mtr); diff --git a/storage/innobase/include/trx0sys.h b/storage/innobase/include/trx0sys.h index 9cec1933e9d..3913792d594 100644 --- a/storage/innobase/include/trx0sys.h +++ b/storage/innobase/include/trx0sys.h @@ -223,6 +223,12 @@ trx_id_t trx_sys_get_new_trx_id(void); /*========================*/ #endif /* !UNIV_HOTBACKUP */ + +#ifdef UNIV_DEBUG +/* Flag to control TRX_RSEG_N_SLOTS behavior debugging. */ +extern uint trx_rseg_n_slots_debug; +#endif + /*****************************************************************//** Writes a trx id to an index page. In case that the id size changes in some future version, this function should be used instead of |