Merge lp:~akopytov/percona-server/bug785489-5.1 into lp:percona-server/5.1

Proposed by Alexey Kopytov
Status: Superseded
Proposed branch: lp:~akopytov/percona-server/bug785489-5.1
Merge into: lp:percona-server/5.1
Diff against target: 1147 lines (+177/-122)
11 files modified
patches/innodb_admin_command_base.patch (+10/-10)
patches/innodb_extend_slow.patch (+7/-7)
patches/innodb_lru_dump_restore.patch (+67/-16)
patches/innodb_pass_corrupt_table.patch (+28/-28)
patches/innodb_purge_thread.patch (+12/-12)
patches/innodb_recovery_patches.patch (+5/-5)
patches/innodb_separate_doublewrite.patch (+6/-6)
patches/innodb_show_lock_name.patch (+5/-5)
patches/innodb_stats.patch (+34/-32)
patches/mysql-test.diff (+2/-0)
patches/series (+1/-1)
To merge this branch: bzr merge lp:~akopytov/percona-server/bug785489-5.1
Reviewer Review Type Date Requested Status
Percona developers Pending
Review via email: mp+76885@code.launchpad.net

This proposal has been superseded by a proposal from 2011-09-25.

To post a comment you must log in.
Revision history for this message
Alexey Kopytov (akopytov) wrote :

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'patches/innodb_admin_command_base.patch'
--- patches/innodb_admin_command_base.patch 2011-09-06 08:23:51 +0000
+++ patches/innodb_admin_command_base.patch 2011-09-25 06:36:21 +0000
@@ -7,18 +7,18 @@
7# should be done or reviewed by the maintainer!7# should be done or reviewed by the maintainer!
8--- a/storage/innodb_plugin/handler/ha_innodb.cc8--- a/storage/innodb_plugin/handler/ha_innodb.cc
9+++ b/storage/innodb_plugin/handler/ha_innodb.cc9+++ b/storage/innodb_plugin/handler/ha_innodb.cc
10@@ -11608,6 +11608,7 @@10@@ -11534,6 +11534,7 @@
11 i_s_innodb_cmp_reset,
12 i_s_innodb_cmpmem,
11 i_s_innodb_cmpmem_reset,13 i_s_innodb_cmpmem_reset,
12 i_s_innodb_table_stats,
13 i_s_innodb_index_stats,
14+i_s_innodb_admin_command,14+i_s_innodb_admin_command,
15 i_s_innodb_patches15 i_s_innodb_patches
16 mysql_declare_plugin_end;16 mysql_declare_plugin_end;
17 17
18--- a/storage/innodb_plugin/handler/i_s.cc18--- a/storage/innodb_plugin/handler/i_s.cc
19+++ b/storage/innodb_plugin/handler/i_s.cc19+++ b/storage/innodb_plugin/handler/i_s.cc
20@@ -2947,3 +2947,139 @@20@@ -2602,3 +2602,139 @@
21 STRUCT_FLD(system_vars, NULL),21 /* void* */
22 STRUCT_FLD(__reserved1, NULL)22 STRUCT_FLD(__reserved1, NULL)
23 };23 };
24+24+
@@ -159,17 +159,17 @@
159+};159+};
160--- a/storage/innodb_plugin/handler/i_s.h160--- a/storage/innodb_plugin/handler/i_s.h
161+++ b/storage/innodb_plugin/handler/i_s.h161+++ b/storage/innodb_plugin/handler/i_s.h
162@@ -40,5 +40,6 @@162@@ -38,5 +38,6 @@
163 extern struct st_mysql_plugin i_s_innodb_cmpmem_reset;
164 extern struct st_mysql_plugin i_s_innodb_patches;
163 extern struct st_mysql_plugin i_s_innodb_rseg;165 extern struct st_mysql_plugin i_s_innodb_rseg;
164 extern struct st_mysql_plugin i_s_innodb_table_stats;
165 extern struct st_mysql_plugin i_s_innodb_index_stats;
166+extern struct st_mysql_plugin i_s_innodb_admin_command;166+extern struct st_mysql_plugin i_s_innodb_admin_command;
167 167
168 #endif /* i_s_h */168 #endif /* i_s_h */
169--- a/storage/innodb_plugin/handler/innodb_patch_info.h169--- a/storage/innodb_plugin/handler/innodb_patch_info.h
170+++ b/storage/innodb_plugin/handler/innodb_patch_info.h170+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
171@@ -38,5 +38,6 @@171@@ -37,5 +37,6 @@
172 {"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},172 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
173 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},173 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
174 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},174 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
175+{"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},175+{"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
176176
=== modified file 'patches/innodb_extend_slow.patch'
--- patches/innodb_extend_slow.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_extend_slow.patch 2011-09-25 06:36:21 +0000
@@ -374,7 +374,7 @@
374 374
375--- a/storage/innodb_plugin/handler/ha_innodb.cc375--- a/storage/innodb_plugin/handler/ha_innodb.cc
376+++ b/storage/innodb_plugin/handler/ha_innodb.cc376+++ b/storage/innodb_plugin/handler/ha_innodb.cc
377@@ -1391,6 +1391,16 @@377@@ -1390,6 +1390,16 @@
378 trx->check_unique_secondary = !thd_test_options(378 trx->check_unique_secondary = !thd_test_options(
379 thd, OPTION_RELAXED_UNIQUE_CHECKS);379 thd, OPTION_RELAXED_UNIQUE_CHECKS);
380 380
@@ -391,7 +391,7 @@
391 DBUG_VOID_RETURN;391 DBUG_VOID_RETURN;
392 }392 }
393 393
394@@ -1446,6 +1456,32 @@394@@ -1445,6 +1455,32 @@
395 }395 }
396 396
397 397
@@ -424,7 +424,7 @@
424 /*********************************************************************//**424 /*********************************************************************//**
425 Construct ha_innobase handler. */425 Construct ha_innobase handler. */
426 UNIV_INTERN426 UNIV_INTERN
427@@ -9024,6 +9060,25 @@427@@ -8975,6 +9011,25 @@
428 statement has ended */428 statement has ended */
429 429
430 if (trx->n_mysql_tables_in_use == 0) {430 if (trx->n_mysql_tables_in_use == 0) {
@@ -452,7 +452,7 @@
452 prebuilt->used_in_HANDLER = FALSE;452 prebuilt->used_in_HANDLER = FALSE;
453--- a/storage/innodb_plugin/handler/innodb_patch_info.h453--- a/storage/innodb_plugin/handler/innodb_patch_info.h
454+++ b/storage/innodb_plugin/handler/innodb_patch_info.h454+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
455@@ -40,5 +40,6 @@455@@ -39,5 +39,6 @@
456 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},456 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
457 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},457 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
458 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},458 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},
@@ -802,7 +802,7 @@
802 /* This is set to TRUE if the MySQL user has set it in MySQL; currently802 /* This is set to TRUE if the MySQL user has set it in MySQL; currently
803 affects only FOREIGN KEY definition parsing */803 affects only FOREIGN KEY definition parsing */
804 UNIV_INTERN ibool srv_lower_case_table_names = FALSE;804 UNIV_INTERN ibool srv_lower_case_table_names = FALSE;
805@@ -1159,6 +1162,10 @@805@@ -1156,6 +1159,10 @@
806 ibool has_slept = FALSE;806 ibool has_slept = FALSE;
807 srv_conc_slot_t* slot = NULL;807 srv_conc_slot_t* slot = NULL;
808 ulint i;808 ulint i;
@@ -813,7 +813,7 @@
813 813
814 if (trx->mysql_thd != NULL814 if (trx->mysql_thd != NULL
815 && thd_is_replication_slave_thread(trx->mysql_thd)) {815 && thd_is_replication_slave_thread(trx->mysql_thd)) {
816@@ -1235,6 +1242,7 @@816@@ -1232,6 +1239,7 @@
817 switches. */817 switches. */
818 if (SRV_THREAD_SLEEP_DELAY > 0) {818 if (SRV_THREAD_SLEEP_DELAY > 0) {
819 os_thread_sleep(SRV_THREAD_SLEEP_DELAY);819 os_thread_sleep(SRV_THREAD_SLEEP_DELAY);
@@ -821,7 +821,7 @@
821 }821 }
822 822
823 trx->op_info = "";823 trx->op_info = "";
824@@ -1290,12 +1298,25 @@824@@ -1287,12 +1295,25 @@
825 /* Go to wait for the event; when a thread leaves InnoDB it will825 /* Go to wait for the event; when a thread leaves InnoDB it will
826 release this thread */826 release this thread */
827 827
828828
=== modified file 'patches/innodb_lru_dump_restore.patch'
--- patches/innodb_lru_dump_restore.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_lru_dump_restore.patch 2011-09-25 06:36:21 +0000
@@ -41,7 +41,7 @@
41+--file_exists $MYSQLD_DATADIR/ib_lru_dump;41+--file_exists $MYSQLD_DATADIR/ib_lru_dump;
42--- a/storage/innodb_plugin/buf/buf0lru.c42--- a/storage/innodb_plugin/buf/buf0lru.c
43+++ b/storage/innodb_plugin/buf/buf0lru.c43+++ b/storage/innodb_plugin/buf/buf0lru.c
44@@ -2121,6 +2121,277 @@44@@ -2121,6 +2121,282 @@
45 memset(&buf_LRU_stat_cur, 0, sizeof buf_LRU_stat_cur);45 memset(&buf_LRU_stat_cur, 0, sizeof buf_LRU_stat_cur);
46 }46 }
47 47
@@ -201,6 +201,11 @@
201+ " InnoDB: cannot open %s\n", LRU_DUMP_FILE);201+ " InnoDB: cannot open %s\n", LRU_DUMP_FILE);
202+ goto end;202+ goto end;
203+ }203+ }
204+
205+ ut_print_timestamp(stderr);
206+ fprintf(stderr, " InnoDB: Restoring buffer pool pages from %s\n",
207+ LRU_DUMP_FILE);
208+
204+ if (size == 0 || size_high > 0 || size % 8) {209+ if (size == 0 || size_high > 0 || size % 8) {
205+ fprintf(stderr, " InnoDB: broken LRU dump file\n");210+ fprintf(stderr, " InnoDB: broken LRU dump file\n");
206+ goto end;211+ goto end;
@@ -302,7 +307,7 @@
302+307+
303+ ut_print_timestamp(stderr);308+ ut_print_timestamp(stderr);
304+ fprintf(stderr,309+ fprintf(stderr,
305+ " InnoDB: reading pages based on the dumped LRU list was done."310+ " InnoDB: Completed reading buffer pool pages"
306+ " (requested: %lu, read: %lu)\n", req, reads);311+ " (requested: %lu, read: %lu)\n", req, reads);
307+ ret = TRUE;312+ ret = TRUE;
308+end:313+end:
@@ -405,7 +410,25 @@
405 Waits for an aio operation to complete. This function is used to write the410 Waits for an aio operation to complete. This function is used to write the
406--- a/storage/innodb_plugin/handler/ha_innodb.cc411--- a/storage/innodb_plugin/handler/ha_innodb.cc
407+++ b/storage/innodb_plugin/handler/ha_innodb.cc412+++ b/storage/innodb_plugin/handler/ha_innodb.cc
408@@ -11547,6 +11547,12 @@413@@ -197,6 +197,8 @@
414
415 static char* innodb_version_str = (char*) INNODB_VERSION_STR;
416
417+static my_bool innobase_blocking_lru_restore = FALSE;
418+
419 /** Possible values for system variable "innodb_stats_method". The values
420 are defined the same as its corresponding MyISAM system variable
421 "myisam_stats_method"(see "myisam_stats_method_names"), for better usability */
422@@ -2408,6 +2410,8 @@
423 srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite;
424 srv_use_checksums = (ibool) innobase_use_checksums;
425
426+ srv_blocking_lru_restore = (ibool) innobase_blocking_lru_restore;
427+
428 #ifdef HAVE_LARGE_PAGES
429 if ((os_use_large_pages = (ibool) my_use_large_pages))
430 os_large_page_size = (ulint) opt_large_page_size;
431@@ -11478,6 +11482,18 @@
409 "Limit the allocated memory for dictionary cache. (0: unlimited)",432 "Limit the allocated memory for dictionary cache. (0: unlimited)",
410 NULL, NULL, 0, 0, LONG_MAX, 0);433 NULL, NULL, 0, 0, LONG_MAX, 0);
411 434
@@ -415,28 +438,35 @@
415+ "0 (the default) disables automatic dumps.",438+ "0 (the default) disables automatic dumps.",
416+ NULL, NULL, 0, 0, UINT_MAX32, 0);439+ NULL, NULL, 0, 0, UINT_MAX32, 0);
417+440+
441+static MYSQL_SYSVAR_BOOL(blocking_lru_restore, innobase_blocking_lru_restore,
442+ PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY,
443+ "Block XtraDB startup process until buffer pool is full restored from a "
444+ "dump file (if present). Disabled by default.",
445+ NULL, NULL, FALSE);
446+
418 static struct st_mysql_sys_var* innobase_system_variables[]= {447 static struct st_mysql_sys_var* innobase_system_variables[]= {
419 MYSQL_SYSVAR(additional_mem_pool_size),448 MYSQL_SYSVAR(additional_mem_pool_size),
420 MYSQL_SYSVAR(autoextend_increment),449 MYSQL_SYSVAR(autoextend_increment),
421@@ -11629,6 +11635,7 @@450@@ -11557,6 +11573,8 @@
422 #endif /* UNIV_DEBUG || UNIV_IBUF_DEBUG */451 #endif /* UNIV_DEBUG || UNIV_IBUF_DEBUG */
423 MYSQL_SYSVAR(read_ahead_threshold),452 MYSQL_SYSVAR(read_ahead_threshold),
424 MYSQL_SYSVAR(io_capacity),453 MYSQL_SYSVAR(io_capacity),
425+ MYSQL_SYSVAR(auto_lru_dump),454+ MYSQL_SYSVAR(auto_lru_dump),
455+ MYSQL_SYSVAR(blocking_lru_restore),
426 MYSQL_SYSVAR(use_purge_thread),456 MYSQL_SYSVAR(use_purge_thread),
427 NULL457 NULL
428 };458 };
429--- a/storage/innodb_plugin/handler/i_s.cc459--- a/storage/innodb_plugin/handler/i_s.cc
430+++ b/storage/innodb_plugin/handler/i_s.cc460+++ b/storage/innodb_plugin/handler/i_s.cc
431@@ -46,6 +46,7 @@461@@ -45,6 +45,7 @@
462 #include "btr0btr.h" /* for btr_page_get_index_id */
432 #include "trx0rseg.h" /* for trx_rseg_struct */463 #include "trx0rseg.h" /* for trx_rseg_struct */
433 #include "trx0sys.h" /* for trx_sys */464 #include "trx0sys.h" /* for trx_sys */
434 #include "dict0dict.h" /* for dict_sys */
435+#include "buf0lru.h" /* for XTRA_LRU_[DUMP/RESTORE] */465+#include "buf0lru.h" /* for XTRA_LRU_[DUMP/RESTORE] */
436 }466 }
437 467
438 static const char plugin_author[] = "Innobase Oy";468 static const char plugin_author[] = "Innobase Oy";
439@@ -3040,6 +3041,36 @@469@@ -2695,6 +2696,36 @@
440 "Hello!");470 "Hello!");
441 goto end_func;471 goto end_func;
442 }472 }
@@ -475,7 +505,7 @@
475 "Undefined XTRA_* command.");505 "Undefined XTRA_* command.");
476--- a/storage/innodb_plugin/handler/innodb_patch_info.h506--- a/storage/innodb_plugin/handler/innodb_patch_info.h
477+++ b/storage/innodb_plugin/handler/innodb_patch_info.h507+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
478@@ -41,5 +41,6 @@508@@ -40,5 +40,6 @@
479 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},509 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
480 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},510 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},
481 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},511 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},
@@ -562,17 +592,20 @@
562 handler for completed requests. The aio array of pending requests is divided592 handler for completed requests. The aio array of pending requests is divided
563--- a/storage/innodb_plugin/include/srv0srv.h593--- a/storage/innodb_plugin/include/srv0srv.h
564+++ b/storage/innodb_plugin/include/srv0srv.h594+++ b/storage/innodb_plugin/include/srv0srv.h
565@@ -335,6 +335,9 @@595@@ -332,6 +332,12 @@
566 reading of a disk page */596 reading of a disk page */
567 extern ulint srv_buf_pool_reads;597 extern ulint srv_buf_pool_reads;
568 598
569+/** Time in seconds between automatic buffer pool dumps */599+/** Time in seconds between automatic buffer pool dumps */
570+extern uint srv_auto_lru_dump;600+extern uint srv_auto_lru_dump;
571+601+
602+/** Whether startup should be blocked until buffer pool is fully restored */
603+extern ibool srv_blocking_lru_restore;
604+
572 /** Status variables to be passed to MySQL */605 /** Status variables to be passed to MySQL */
573 typedef struct export_var_struct export_struc;606 typedef struct export_var_struct export_struc;
574 607
575@@ -616,6 +619,16 @@608@@ -613,6 +619,16 @@
576 /*=====================*/609 /*=====================*/
577 void* arg); /*!< in: a dummy parameter required by610 void* arg); /*!< in: a dummy parameter required by
578 os_thread_create */611 os_thread_create */
@@ -591,17 +624,20 @@
591 @return FALSE if not all information printed624 @return FALSE if not all information printed
592--- a/storage/innodb_plugin/srv/srv0srv.c625--- a/storage/innodb_plugin/srv/srv0srv.c
593+++ b/storage/innodb_plugin/srv/srv0srv.c626+++ b/storage/innodb_plugin/srv/srv0srv.c
594@@ -303,6 +303,9 @@627@@ -303,6 +303,12 @@
595 reading of a disk page */628 reading of a disk page */
596 UNIV_INTERN ulint srv_buf_pool_reads = 0;629 UNIV_INTERN ulint srv_buf_pool_reads = 0;
597 630
598+/** Time in seconds between automatic buffer pool dumps */631+/** Time in seconds between automatic buffer pool dumps */
599+UNIV_INTERN uint srv_auto_lru_dump = 0;632+UNIV_INTERN uint srv_auto_lru_dump = 0;
600+633+
634+/** Whether startup should be blocked until buffer pool is fully restored */
635+UNIV_INTERN ibool srv_blocking_lru_restore;
636+
601 /* structure to pass status variables to MySQL */637 /* structure to pass status variables to MySQL */
602 UNIV_INTERN export_struc export_vars;638 UNIV_INTERN export_struc export_vars;
603 639
604@@ -2555,6 +2558,56 @@640@@ -2552,6 +2558,58 @@
605 OS_THREAD_DUMMY_RETURN;641 OS_THREAD_DUMMY_RETURN;
606 }642 }
607 643
@@ -626,7 +662,9 @@
626+ os_thread_pf(os_thread_get_curr_id()));662+ os_thread_pf(os_thread_get_curr_id()));
627+#endif663+#endif
628+664+
629+ if (srv_auto_lru_dump)665+ /* If srv_blocking_lru_restore is TRUE, restore will be done
666+ synchronously on startup. */
667+ if (srv_auto_lru_dump && !srv_blocking_lru_restore)
630+ buf_LRU_file_restore();668+ buf_LRU_file_restore();
631+669+
632+ last_dump_time = time(NULL);670+ last_dump_time = time(NULL);
@@ -660,7 +698,15 @@
660 and wakes up the master thread if it is suspended (not sleeping). Used698 and wakes up the master thread if it is suspended (not sleeping). Used
661--- a/storage/innodb_plugin/srv/srv0start.c699--- a/storage/innodb_plugin/srv/srv0start.c
662+++ b/storage/innodb_plugin/srv/srv0start.c700+++ b/storage/innodb_plugin/srv/srv0start.c
663@@ -126,9 +126,9 @@701@@ -88,6 +88,7 @@
702 # include "thr0loc.h"
703 # include "os0sync.h" /* for INNODB_RW_LOCKS_USE_ATOMICS */
704 # include "zlib.h" /* for ZLIB_VERSION */
705+# include "buf0lru.h" /* for buf_LRU_file_restore() */
706
707 /** Log sequence number immediately after startup */
708 UNIV_INTERN ib_uint64_t srv_start_lsn;
709@@ -126,9 +127,9 @@
664 static ulint ios;710 static ulint ios;
665 711
666 /** io_handler_thread parameters for thread identification */712 /** io_handler_thread parameters for thread identification */
@@ -672,7 +718,7 @@
672 718
673 /** We use this mutex to test the return value of pthread_mutex_trylock719 /** We use this mutex to test the return value of pthread_mutex_trylock
674 on successful locking. HP-UX does NOT return 0, though Linux et al do. */720 on successful locking. HP-UX does NOT return 0, though Linux et al do. */
675@@ -1706,6 +1706,10 @@721@@ -1706,6 +1707,15 @@
676 os_thread_create(&srv_monitor_thread, NULL,722 os_thread_create(&srv_monitor_thread, NULL,
677 thread_ids + 4 + SRV_MAX_N_IO_THREADS);723 thread_ids + 4 + SRV_MAX_N_IO_THREADS);
678 724
@@ -680,10 +726,15 @@
680+ os_thread_create(&srv_LRU_dump_restore_thread, NULL,726+ os_thread_create(&srv_LRU_dump_restore_thread, NULL,
681+ thread_ids + 5 + SRV_MAX_N_IO_THREADS);727+ thread_ids + 5 + SRV_MAX_N_IO_THREADS);
682+728+
729+ /* If srv_blocking_lru_restore is TRUE, load buffer pool contents
730+ synchronously */
731+ if (srv_auto_lru_dump && srv_blocking_lru_restore)
732+ buf_LRU_file_restore();
733+
683 srv_is_being_started = FALSE;734 srv_is_being_started = FALSE;
684 735
685 if (trx_doublewrite == NULL) {736 if (trx_doublewrite == NULL) {
686@@ -1730,13 +1734,13 @@737@@ -1730,13 +1740,13 @@
687 ulint i;738 ulint i;
688 739
689 os_thread_create(&srv_purge_thread, NULL, thread_ids740 os_thread_create(&srv_purge_thread, NULL, thread_ids
690741
=== modified file 'patches/innodb_pass_corrupt_table.patch'
--- patches/innodb_pass_corrupt_table.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_pass_corrupt_table.patch 2011-09-25 06:36:21 +0000
@@ -468,7 +468,7 @@
468 goto next_loop;468 goto next_loop;
469 469
470 cached_foreign_tables = 0;470 cached_foreign_tables = 0;
471@@ -4657,6 +4658,12 @@471@@ -4328,6 +4329,12 @@
472 }472 }
473 473
474 do {474 do {
@@ -481,7 +481,7 @@
481 if (UNIV_LIKELY481 if (UNIV_LIKELY
482 (srv_force_recovery < SRV_FORCE_NO_IBUF_MERGE482 (srv_force_recovery < SRV_FORCE_NO_IBUF_MERGE
483 || (srv_force_recovery < SRV_FORCE_NO_LOG_REDO483 || (srv_force_recovery < SRV_FORCE_NO_LOG_REDO
484@@ -5460,4 +5467,42 @@484@@ -5054,4 +5061,42 @@
485 rw_lock_free(&dict_table_stats_latches[i]);485 rw_lock_free(&dict_table_stats_latches[i]);
486 }486 }
487 }487 }
@@ -757,7 +757,7 @@
757 if (descr != NULL) {757 if (descr != NULL) {
758--- a/storage/innodb_plugin/handler/ha_innodb.cc758--- a/storage/innodb_plugin/handler/ha_innodb.cc
759+++ b/storage/innodb_plugin/handler/ha_innodb.cc759+++ b/storage/innodb_plugin/handler/ha_innodb.cc
760@@ -3735,6 +3735,12 @@760@@ -3732,6 +3732,12 @@
761 DBUG_RETURN(1);761 DBUG_RETURN(1);
762 }762 }
763 763
@@ -770,7 +770,7 @@
770 /* Create buffers for packing the fields of a record. Why770 /* Create buffers for packing the fields of a record. Why
771 table->reclength did not work here? Obviously, because char771 table->reclength did not work here? Obviously, because char
772 fields when packed actually became 1 byte longer, when we also772 fields when packed actually became 1 byte longer, when we also
773@@ -3762,6 +3768,19 @@773@@ -3759,6 +3765,19 @@
774 /* Get pointer to a table object in InnoDB dictionary cache */774 /* Get pointer to a table object in InnoDB dictionary cache */
775 ib_table = dict_table_get(norm_name, TRUE);775 ib_table = dict_table_get(norm_name, TRUE);
776 776
@@ -790,7 +790,7 @@
790 if (NULL == ib_table) {790 if (NULL == ib_table) {
791 if (is_part && retries < 10) {791 if (is_part && retries < 10) {
792 ++retries;792 ++retries;
793@@ -4928,6 +4947,10 @@793@@ -4925,6 +4944,10 @@
794 794
795 ha_statistic_increment(&SSV::ha_write_count);795 ha_statistic_increment(&SSV::ha_write_count);
796 796
@@ -801,7 +801,7 @@
801 if (table->timestamp_field_type & TIMESTAMP_AUTO_SET_ON_INSERT)801 if (table->timestamp_field_type & TIMESTAMP_AUTO_SET_ON_INSERT)
802 table->timestamp_field->set_time();802 table->timestamp_field->set_time();
803 803
804@@ -5145,6 +5168,10 @@804@@ -5138,6 +5161,10 @@
805 func_exit:805 func_exit:
806 innobase_active_small();806 innobase_active_small();
807 807
@@ -812,7 +812,7 @@
812 DBUG_RETURN(error_result);812 DBUG_RETURN(error_result);
813 }813 }
814 814
815@@ -5321,6 +5348,10 @@815@@ -5314,6 +5341,10 @@
816 816
817 ha_statistic_increment(&SSV::ha_update_count);817 ha_statistic_increment(&SSV::ha_update_count);
818 818
@@ -823,7 +823,7 @@
823 if (table->timestamp_field_type & TIMESTAMP_AUTO_SET_ON_UPDATE)823 if (table->timestamp_field_type & TIMESTAMP_AUTO_SET_ON_UPDATE)
824 table->timestamp_field->set_time();824 table->timestamp_field->set_time();
825 825
826@@ -5410,6 +5441,10 @@826@@ -5399,6 +5430,10 @@
827 827
828 innobase_active_small();828 innobase_active_small();
829 829
@@ -834,7 +834,7 @@
834 DBUG_RETURN(error);834 DBUG_RETURN(error);
835 }835 }
836 836
837@@ -5431,6 +5466,10 @@837@@ -5420,6 +5455,10 @@
838 838
839 ha_statistic_increment(&SSV::ha_delete_count);839 ha_statistic_increment(&SSV::ha_delete_count);
840 840
@@ -845,7 +845,7 @@
845 if (!prebuilt->upd_node) {845 if (!prebuilt->upd_node) {
846 row_get_prebuilt_update_vector(prebuilt);846 row_get_prebuilt_update_vector(prebuilt);
847 }847 }
848@@ -5457,6 +5496,10 @@848@@ -5442,6 +5481,10 @@
849 849
850 innobase_active_small();850 innobase_active_small();
851 851
@@ -856,7 +856,7 @@
856 DBUG_RETURN(error);856 DBUG_RETURN(error);
857 }857 }
858 858
859@@ -5696,6 +5739,10 @@859@@ -5681,6 +5724,10 @@
860 860
861 ha_statistic_increment(&SSV::ha_read_key_count);861 ha_statistic_increment(&SSV::ha_read_key_count);
862 862
@@ -867,7 +867,7 @@
867 index = prebuilt->index;867 index = prebuilt->index;
868 868
869 if (UNIV_UNLIKELY(index == NULL)) {869 if (UNIV_UNLIKELY(index == NULL)) {
870@@ -5761,6 +5808,10 @@870@@ -5746,6 +5793,10 @@
871 ret = DB_UNSUPPORTED;871 ret = DB_UNSUPPORTED;
872 }872 }
873 873
@@ -878,7 +878,7 @@
878 switch (ret) {878 switch (ret) {
879 case DB_SUCCESS:879 case DB_SUCCESS:
880 error = 0;880 error = 0;
881@@ -5876,6 +5927,10 @@881@@ -5856,6 +5907,10 @@
882 {882 {
883 DBUG_ENTER("change_active_index");883 DBUG_ENTER("change_active_index");
884 884
@@ -889,7 +889,7 @@
889 ut_ad(user_thd == ha_thd());889 ut_ad(user_thd == ha_thd());
890 ut_a(prebuilt->trx == thd_to_trx(user_thd));890 ut_a(prebuilt->trx == thd_to_trx(user_thd));
891 891
892@@ -5966,6 +6021,10 @@892@@ -5946,6 +6001,10 @@
893 893
894 DBUG_ENTER("general_fetch");894 DBUG_ENTER("general_fetch");
895 895
@@ -900,7 +900,7 @@
900 ut_a(prebuilt->trx == thd_to_trx(user_thd));900 ut_a(prebuilt->trx == thd_to_trx(user_thd));
901 901
902 innodb_srv_conc_enter_innodb(prebuilt->trx);902 innodb_srv_conc_enter_innodb(prebuilt->trx);
903@@ -5975,6 +6034,10 @@903@@ -5955,6 +6014,10 @@
904 904
905 innodb_srv_conc_exit_innodb(prebuilt->trx);905 innodb_srv_conc_exit_innodb(prebuilt->trx);
906 906
@@ -911,7 +911,7 @@
911 switch (ret) {911 switch (ret) {
912 case DB_SUCCESS:912 case DB_SUCCESS:
913 error = 0;913 error = 0;
914@@ -7227,6 +7290,10 @@914@@ -7202,6 +7265,10 @@
915 DBUG_RETURN(my_errno=HA_ERR_WRONG_COMMAND);915 DBUG_RETURN(my_errno=HA_ERR_WRONG_COMMAND);
916 }916 }
917 917
@@ -922,7 +922,7 @@
922 /* Truncate the table in InnoDB */922 /* Truncate the table in InnoDB */
923 923
924 error = row_truncate_table_for_mysql(prebuilt->table, prebuilt->trx);924 error = row_truncate_table_for_mysql(prebuilt->table, prebuilt->trx);
925@@ -7235,6 +7302,10 @@925@@ -7210,6 +7277,10 @@
926 goto fallback;926 goto fallback;
927 }927 }
928 928
@@ -933,7 +933,7 @@
933 error = convert_error_code_to_mysql(error, prebuilt->table->flags,933 error = convert_error_code_to_mysql(error, prebuilt->table->flags,
934 NULL);934 NULL);
935 935
936@@ -7739,6 +7810,16 @@936@@ -7714,6 +7785,16 @@
937 return(ranges + (double) rows / (double) total_rows * time_for_scan);937 return(ranges + (double) rows / (double) total_rows * time_for_scan);
938 }938 }
939 939
@@ -950,7 +950,7 @@
950 /*********************************************************************//**950 /*********************************************************************//**
951 Calculates the key number used inside MySQL for an Innobase index. We will951 Calculates the key number used inside MySQL for an Innobase index. We will
952 first check the "index translation table" for a match of the index to get952 first check the "index translation table" for a match of the index to get
953@@ -7919,7 +8000,7 @@953@@ -7894,7 +7975,7 @@
954 ib_table = prebuilt->table;954 ib_table = prebuilt->table;
955 955
956 if (flag & HA_STATUS_TIME) {956 if (flag & HA_STATUS_TIME) {
@@ -959,7 +959,7 @@
959 /* In sql_show we call with this flag: update959 /* In sql_show we call with this flag: update
960 then statistics so that they are up-to-date */960 then statistics so that they are up-to-date */
961 961
962@@ -8209,10 +8290,18 @@962@@ -8160,10 +8241,18 @@
963 THD* thd, /*!< in: connection thread handle */963 THD* thd, /*!< in: connection thread handle */
964 HA_CHECK_OPT* check_opt) /*!< in: currently ignored */964 HA_CHECK_OPT* check_opt) /*!< in: currently ignored */
965 {965 {
@@ -978,7 +978,7 @@
978 return(0);978 return(0);
979 }979 }
980 980
981@@ -8394,6 +8483,10 @@981@@ -8345,6 +8434,10 @@
982 my_error(ER_QUERY_INTERRUPTED, MYF(0));982 my_error(ER_QUERY_INTERRUPTED, MYF(0));
983 }983 }
984 984
@@ -989,7 +989,7 @@
989 DBUG_RETURN(is_ok ? HA_ADMIN_OK : HA_ADMIN_CORRUPT);989 DBUG_RETURN(is_ok ? HA_ADMIN_OK : HA_ADMIN_CORRUPT);
990 }990 }
991 991
992@@ -9127,6 +9220,10 @@992@@ -9078,6 +9171,10 @@
993 993
994 update_thd(thd);994 update_thd(thd);
995 995
@@ -1000,7 +1000,7 @@
1000 if (prebuilt->table->ibd_file_missing && !thd_tablespace_op(thd)) {1000 if (prebuilt->table->ibd_file_missing && !thd_tablespace_op(thd)) {
1001 ut_print_timestamp(stderr);1001 ut_print_timestamp(stderr);
1002 fprintf(stderr,1002 fprintf(stderr,
1003@@ -11561,6 +11658,14 @@1003@@ -11492,6 +11589,14 @@
1004 "0 (the default) disables automatic dumps.",1004 "0 (the default) disables automatic dumps.",
1005 NULL, NULL, 0, 0, UINT_MAX32, 0);1005 NULL, NULL, 0, 0, UINT_MAX32, 0);
1006 1006
@@ -1015,7 +1015,7 @@
1015 static struct st_mysql_sys_var* innobase_system_variables[]= {1015 static struct st_mysql_sys_var* innobase_system_variables[]= {
1016 MYSQL_SYSVAR(additional_mem_pool_size),1016 MYSQL_SYSVAR(additional_mem_pool_size),
1017 MYSQL_SYSVAR(autoextend_increment),1017 MYSQL_SYSVAR(autoextend_increment),
1018@@ -11646,6 +11751,7 @@1018@@ -11574,6 +11679,7 @@
1019 MYSQL_SYSVAR(io_capacity),1019 MYSQL_SYSVAR(io_capacity),
1020 MYSQL_SYSVAR(auto_lru_dump),1020 MYSQL_SYSVAR(auto_lru_dump),
1021 MYSQL_SYSVAR(use_purge_thread),1021 MYSQL_SYSVAR(use_purge_thread),
@@ -1043,7 +1043,7 @@
1043 int update_row(const uchar * old_data, uchar * new_data);1043 int update_row(const uchar * old_data, uchar * new_data);
1044--- a/storage/innodb_plugin/handler/innodb_patch_info.h1044--- a/storage/innodb_plugin/handler/innodb_patch_info.h
1045+++ b/storage/innodb_plugin/handler/innodb_patch_info.h1045+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
1046@@ -43,5 +43,6 @@1046@@ -42,5 +42,6 @@
1047 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},1047 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},
1048 {"innodb_lru_dump_restore","Dump and restore command for content of buffer pool","","http://www.percona.com/docs/wiki/percona-xtradb"},1048 {"innodb_lru_dump_restore","Dump and restore command for content of buffer pool","","http://www.percona.com/docs/wiki/percona-xtradb"},
1049 {"innodb_separate_doublewrite","Add option 'innodb_doublewrite_file' to separate doublewrite dedicated tablespace","","http://www.percona.com/docs/wiki/percona-xtradb"},1049 {"innodb_separate_doublewrite","Add option 'innodb_doublewrite_file' to separate doublewrite dedicated tablespace","","http://www.percona.com/docs/wiki/percona-xtradb"},
@@ -1117,7 +1117,7 @@
1117 switch (buf_block_get_state(block)) {1117 switch (buf_block_get_state(block)) {
1118--- a/storage/innodb_plugin/include/dict0dict.h1118--- a/storage/innodb_plugin/include/dict0dict.h
1119+++ b/storage/innodb_plugin/include/dict0dict.h1119+++ b/storage/innodb_plugin/include/dict0dict.h
1120@@ -1206,6 +1206,15 @@1120@@ -1197,6 +1197,15 @@
1121 dict_close(void);1121 dict_close(void);
1122 /*============*/1122 /*============*/
1123 1123
@@ -1224,7 +1224,7 @@
1224 Decompress a page. This function should tolerate errors on the compressed1224 Decompress a page. This function should tolerate errors on the compressed
1225--- a/storage/innodb_plugin/include/srv0srv.h1225--- a/storage/innodb_plugin/include/srv0srv.h
1226+++ b/storage/innodb_plugin/include/srv0srv.h1226+++ b/storage/innodb_plugin/include/srv0srv.h
1227@@ -231,6 +231,7 @@1227@@ -228,6 +228,7 @@
1228 extern ulint srv_adaptive_checkpoint;1228 extern ulint srv_adaptive_checkpoint;
1229 1229
1230 extern ulint srv_expand_import;1230 extern ulint srv_expand_import;
@@ -1319,7 +1319,7 @@
1319 fprintf(stderr,1319 fprintf(stderr,
1320--- a/storage/innodb_plugin/srv/srv0srv.c1320--- a/storage/innodb_plugin/srv/srv0srv.c
1321+++ b/storage/innodb_plugin/srv/srv0srv.c1321+++ b/storage/innodb_plugin/srv/srv0srv.c
1322@@ -406,6 +406,7 @@1322@@ -403,6 +403,7 @@
1323 UNIV_INTERN ulint srv_adaptive_checkpoint = 0; /* 0: none 1: reflex 2: estimate */1323 UNIV_INTERN ulint srv_adaptive_checkpoint = 0; /* 0: none 1: reflex 2: estimate */
1324 1324
1325 UNIV_INTERN ulint srv_expand_import = 0; /* 0:disable 1:enable */1325 UNIV_INTERN ulint srv_expand_import = 0; /* 0:disable 1:enable */
13261326
=== modified file 'patches/innodb_purge_thread.patch'
--- patches/innodb_purge_thread.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_purge_thread.patch 2011-09-25 06:36:21 +0000
@@ -7,7 +7,7 @@
7# should be done or reviewed by the maintainer!7# should be done or reviewed by the maintainer!
8--- a/storage/innodb_plugin/handler/ha_innodb.cc8--- a/storage/innodb_plugin/handler/ha_innodb.cc
9+++ b/storage/innodb_plugin/handler/ha_innodb.cc9+++ b/storage/innodb_plugin/handler/ha_innodb.cc
10@@ -11060,6 +11060,11 @@10@@ -11011,6 +11011,11 @@
11 "Output statistics of recovery process after it.",11 "Output statistics of recovery process after it.",
12 NULL, NULL, FALSE);12 NULL, NULL, FALSE);
13 13
@@ -19,7 +19,7 @@
19 static MYSQL_SYSVAR_BOOL(overwrite_relay_log_info, innobase_overwrite_relay_log_info,19 static MYSQL_SYSVAR_BOOL(overwrite_relay_log_info, innobase_overwrite_relay_log_info,
20 PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY,20 PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY,
21 "During InnoDB crash recovery on slave overwrite relay-log.info "21 "During InnoDB crash recovery on slave overwrite relay-log.info "
22@@ -11571,6 +11576,7 @@22@@ -11499,6 +11504,7 @@
23 #endif /* UNIV_DEBUG || UNIV_IBUF_DEBUG */23 #endif /* UNIV_DEBUG || UNIV_IBUF_DEBUG */
24 MYSQL_SYSVAR(read_ahead_threshold),24 MYSQL_SYSVAR(read_ahead_threshold),
25 MYSQL_SYSVAR(io_capacity),25 MYSQL_SYSVAR(io_capacity),
@@ -29,9 +29,9 @@
29 29
30--- a/storage/innodb_plugin/handler/innodb_patch_info.h30--- a/storage/innodb_plugin/handler/innodb_patch_info.h
31+++ b/storage/innodb_plugin/handler/innodb_patch_info.h31+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
32@@ -37,5 +37,6 @@32@@ -36,5 +36,6 @@
33 {"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},
33 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},34 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
34 {"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},
35 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},35 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
36+{"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},36+{"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
37 {NULL, NULL, NULL, NULL}37 {NULL, NULL, NULL, NULL}
@@ -47,7 +47,7 @@
47 extern ibool srv_auto_extend_last_data_file;47 extern ibool srv_auto_extend_last_data_file;
48 extern ulint srv_last_file_size_max;48 extern ulint srv_last_file_size_max;
49 extern char** srv_log_group_home_dirs;49 extern char** srv_log_group_home_dirs;
50@@ -421,6 +423,8 @@50@@ -418,6 +420,8 @@
51 SRV_RECOVERY, /**< threads finishing a recovery */51 SRV_RECOVERY, /**< threads finishing a recovery */
52 SRV_INSERT, /**< thread flushing the insert buffer to disk */52 SRV_INSERT, /**< thread flushing the insert buffer to disk */
53 #endif53 #endif
@@ -56,7 +56,7 @@
56 SRV_MASTER /**< the master thread, (whose type number must56 SRV_MASTER /**< the master thread, (whose type number must
57 be biggest) */57 be biggest) */
58 };58 };
59@@ -494,6 +498,21 @@59@@ -491,6 +495,21 @@
60 /*==============*/60 /*==============*/
61 void* arg); /*!< in: a dummy parameter required by61 void* arg); /*!< in: a dummy parameter required by
62 os_thread_create */62 os_thread_create */
@@ -148,7 +148,7 @@
148 /* if TRUE, then we auto-extend the last data file */148 /* if TRUE, then we auto-extend the last data file */
149 UNIV_INTERN ibool srv_auto_extend_last_data_file = FALSE;149 UNIV_INTERN ibool srv_auto_extend_last_data_file = FALSE;
150 /* if != 0, this tells the max size auto-extending may increase the150 /* if != 0, this tells the max size auto-extending may increase the
151@@ -2639,10 +2641,10 @@151@@ -2636,10 +2638,10 @@
152 srv_main_thread_process_no = os_proc_get_number();152 srv_main_thread_process_no = os_proc_get_number();
153 srv_main_thread_id = os_thread_pf(os_thread_get_curr_id());153 srv_main_thread_id = os_thread_pf(os_thread_get_curr_id());
154 154
@@ -160,7 +160,7 @@
160 srv_n_threads_active[SRV_MASTER]++;160 srv_n_threads_active[SRV_MASTER]++;
161 161
162 mutex_exit(&kernel_mutex);162 mutex_exit(&kernel_mutex);
163@@ -3100,6 +3102,7 @@163@@ -3097,6 +3099,7 @@
164 /* Flush logs if needed */164 /* Flush logs if needed */
165 srv_sync_log_buffer_in_background();165 srv_sync_log_buffer_in_background();
166 166
@@ -168,7 +168,7 @@
168 /* We run a full purge every 10 seconds, even if the server168 /* We run a full purge every 10 seconds, even if the server
169 were active */169 were active */
170 do {170 do {
171@@ -3116,6 +3119,7 @@171@@ -3113,6 +3116,7 @@
172 srv_sync_log_buffer_in_background();172 srv_sync_log_buffer_in_background();
173 173
174 } while (n_pages_purged);174 } while (n_pages_purged);
@@ -176,7 +176,7 @@
176 176
177 srv_main_thread_op_info = "flushing buffer pool pages";177 srv_main_thread_op_info = "flushing buffer pool pages";
178 178
179@@ -3184,6 +3188,7 @@179@@ -3181,6 +3185,7 @@
180 os_thread_sleep(100000);180 os_thread_sleep(100000);
181 }181 }
182 182
@@ -184,7 +184,7 @@
184 srv_main_thread_op_info = "purging";184 srv_main_thread_op_info = "purging";
185 185
186 /* Run a full purge */186 /* Run a full purge */
187@@ -3200,6 +3205,7 @@187@@ -3197,6 +3202,7 @@
188 srv_sync_log_buffer_in_background();188 srv_sync_log_buffer_in_background();
189 189
190 } while (n_pages_purged);190 } while (n_pages_purged);
@@ -192,7 +192,7 @@
192 192
193 srv_main_thread_op_info = "reserving kernel mutex";193 srv_main_thread_op_info = "reserving kernel mutex";
194 194
195@@ -3352,3 +3358,143 @@195@@ -3349,3 +3355,143 @@
196 196
197 OS_THREAD_DUMMY_RETURN; /* Not reached, avoid compiler warning */197 OS_THREAD_DUMMY_RETURN; /* Not reached, avoid compiler warning */
198 }198 }
199199
=== modified file 'patches/innodb_recovery_patches.patch'
--- patches/innodb_recovery_patches.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_recovery_patches.patch 2011-09-25 06:36:21 +0000
@@ -116,7 +116,7 @@
116 static my_bool innobase_locks_unsafe_for_binlog = FALSE;116 static my_bool innobase_locks_unsafe_for_binlog = FALSE;
117 static my_bool innobase_overwrite_relay_log_info = FALSE;117 static my_bool innobase_overwrite_relay_log_info = FALSE;
118 static my_bool innobase_rollback_on_timeout = FALSE;118 static my_bool innobase_rollback_on_timeout = FALSE;
119@@ -2368,6 +2370,8 @@119@@ -2365,6 +2367,8 @@
120 120
121 srv_force_recovery = (ulint) innobase_force_recovery;121 srv_force_recovery = (ulint) innobase_force_recovery;
122 122
@@ -125,7 +125,7 @@
125 srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite;125 srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite;
126 srv_use_checksums = (ibool) innobase_use_checksums;126 srv_use_checksums = (ibool) innobase_use_checksums;
127 127
128@@ -11046,6 +11050,16 @@128@@ -10997,6 +11001,16 @@
129 "don't use the datafile for normal mysqld or ibbackup! ####",129 "don't use the datafile for normal mysqld or ibbackup! ####",
130 NULL, NULL, FALSE);130 NULL, NULL, FALSE);
131 131
@@ -142,7 +142,7 @@
142 static MYSQL_SYSVAR_BOOL(overwrite_relay_log_info, innobase_overwrite_relay_log_info,142 static MYSQL_SYSVAR_BOOL(overwrite_relay_log_info, innobase_overwrite_relay_log_info,
143 PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY,143 PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY,
144 "During InnoDB crash recovery on slave overwrite relay-log.info "144 "During InnoDB crash recovery on slave overwrite relay-log.info "
145@@ -11486,6 +11500,8 @@145@@ -11417,6 +11431,8 @@
146 MYSQL_SYSVAR(data_home_dir),146 MYSQL_SYSVAR(data_home_dir),
147 MYSQL_SYSVAR(doublewrite),147 MYSQL_SYSVAR(doublewrite),
148 MYSQL_SYSVAR(extra_undoslots),148 MYSQL_SYSVAR(extra_undoslots),
@@ -153,10 +153,10 @@
153 MYSQL_SYSVAR(read_io_threads),153 MYSQL_SYSVAR(read_io_threads),
154--- a/storage/innodb_plugin/handler/innodb_patch_info.h154--- a/storage/innodb_plugin/handler/innodb_patch_info.h
155+++ b/storage/innodb_plugin/handler/innodb_patch_info.h155+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
156@@ -36,5 +36,6 @@156@@ -35,5 +35,6 @@
157 {"innodb_expand_import","convert .ibd file automatically when import tablespace","the files are generated by xtrabackup export mode.","http://www.percona.com/docs/wiki/percona-xtradb"},
157 {"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},158 {"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},
158 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},159 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
159 {"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},
160+{"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},160+{"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
161 {NULL, NULL, NULL, NULL}161 {NULL, NULL, NULL, NULL}
162 };162 };
163163
=== modified file 'patches/innodb_separate_doublewrite.patch'
--- patches/innodb_separate_doublewrite.patch 2011-09-06 08:23:51 +0000
+++ patches/innodb_separate_doublewrite.patch 2011-09-25 06:36:21 +0000
@@ -341,7 +341,7 @@
341 341
342 /* Note: This variable can be set to on/off and any of the supported342 /* Note: This variable can be set to on/off and any of the supported
343 file formats in the configuration file, but can only be set to any343 file formats in the configuration file, but can only be set to any
344@@ -2267,6 +2268,8 @@344@@ -2266,6 +2267,8 @@
345 goto error;345 goto error;
346 }346 }
347 347
@@ -349,8 +349,8 @@
349+349+
350 srv_extra_undoslots = (ibool) innobase_extra_undoslots;350 srv_extra_undoslots = (ibool) innobase_extra_undoslots;
351 351
352 srv_use_sys_stats_table = (ibool) innobase_use_sys_stats_table;352 /* -------------- Log files ---------------------------*/
353@@ -11388,6 +11391,11 @@353@@ -11319,6 +11322,11 @@
354 "Path to individual files and their sizes.",354 "Path to individual files and their sizes.",
355 NULL, NULL, NULL);355 NULL, NULL, NULL);
356 356
@@ -362,7 +362,7 @@
362 static MYSQL_SYSVAR_LONG(autoinc_lock_mode, innobase_autoinc_lock_mode,362 static MYSQL_SYSVAR_LONG(autoinc_lock_mode, innobase_autoinc_lock_mode,
363 PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,363 PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY,
364 "The AUTOINC lock modes supported by InnoDB: "364 "The AUTOINC lock modes supported by InnoDB: "
365@@ -11561,6 +11569,7 @@365@@ -11492,6 +11500,7 @@
366 MYSQL_SYSVAR(commit_concurrency),366 MYSQL_SYSVAR(commit_concurrency),
367 MYSQL_SYSVAR(concurrency_tickets),367 MYSQL_SYSVAR(concurrency_tickets),
368 MYSQL_SYSVAR(data_file_path),368 MYSQL_SYSVAR(data_file_path),
@@ -372,7 +372,7 @@
372 MYSQL_SYSVAR(extra_undoslots),372 MYSQL_SYSVAR(extra_undoslots),
373--- a/storage/innodb_plugin/handler/innodb_patch_info.h373--- a/storage/innodb_plugin/handler/innodb_patch_info.h
374+++ b/storage/innodb_plugin/handler/innodb_patch_info.h374+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
375@@ -42,5 +42,6 @@375@@ -41,5 +41,6 @@
376 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},376 {"innodb_show_lock_name","Show mutex/lock name instead of crated file/line","","http://www.percona.com/docs/wiki/percona-xtradb"},
377 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},377 {"innodb_extend_slow","Extended statistics in slow.log","It is InnoDB-part only. It needs to patch also to mysqld.","http://www.percona.com/docs/wiki/percona-xtradb"},
378 {"innodb_lru_dump_restore","Dump and restore command for content of buffer pool","","http://www.percona.com/docs/wiki/percona-xtradb"},378 {"innodb_lru_dump_restore","Dump and restore command for content of buffer pool","","http://www.percona.com/docs/wiki/percona-xtradb"},
@@ -515,7 +515,7 @@
515 UNIV_INLINE515 UNIV_INLINE
516--- a/storage/innodb_plugin/row/row0mysql.c516--- a/storage/innodb_plugin/row/row0mysql.c
517+++ b/storage/innodb_plugin/row/row0mysql.c517+++ b/storage/innodb_plugin/row/row0mysql.c
518@@ -3401,7 +3401,7 @@518@@ -3331,7 +3331,7 @@
519 /* Do not drop possible .ibd tablespace if something went519 /* Do not drop possible .ibd tablespace if something went
520 wrong: we do not want to delete valuable data of the user */520 wrong: we do not want to delete valuable data of the user */
521 521
522522
=== modified file 'patches/innodb_show_lock_name.patch'
--- patches/innodb_show_lock_name.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_show_lock_name.patch 2011-09-25 06:36:21 +0000
@@ -7,7 +7,7 @@
7# should be done or reviewed by the maintainer!7# should be done or reviewed by the maintainer!
8--- a/storage/innodb_plugin/handler/ha_innodb.cc8--- a/storage/innodb_plugin/handler/ha_innodb.cc
9+++ b/storage/innodb_plugin/handler/ha_innodb.cc9+++ b/storage/innodb_plugin/handler/ha_innodb.cc
10@@ -9317,8 +9317,8 @@10@@ -9268,8 +9268,8 @@
11 rw_lock_wait_time += mutex->lspent_time;11 rw_lock_wait_time += mutex->lspent_time;
12 }12 }
13 #else /* UNIV_DEBUG */13 #else /* UNIV_DEBUG */
@@ -18,7 +18,7 @@
18 buf2len= (uint) my_snprintf(buf2, sizeof(buf2), "os_waits=%lu",18 buf2len= (uint) my_snprintf(buf2, sizeof(buf2), "os_waits=%lu",
19 (ulong) mutex->count_os_wait);19 (ulong) mutex->count_os_wait);
20 20
21@@ -9333,9 +9333,8 @@21@@ -9284,9 +9284,8 @@
22 22
23 if (block_mutex) {23 if (block_mutex) {
24 buf1len = (uint) my_snprintf(buf1, sizeof buf1,24 buf1len = (uint) my_snprintf(buf1, sizeof buf1,
@@ -30,7 +30,7 @@
30 buf2len = (uint) my_snprintf(buf2, sizeof buf2,30 buf2len = (uint) my_snprintf(buf2, sizeof buf2,
31 "os_waits=%lu",31 "os_waits=%lu",
32 (ulong) block_mutex_oswait_count);32 (ulong) block_mutex_oswait_count);
33@@ -9364,8 +9363,8 @@33@@ -9315,8 +9314,8 @@
34 continue;34 continue;
35 }35 }
36 36
@@ -41,7 +41,7 @@
41 buf2len = my_snprintf(buf2, sizeof buf2, "os_waits=%lu",41 buf2len = my_snprintf(buf2, sizeof buf2, "os_waits=%lu",
42 (ulong) lock->count_os_wait);42 (ulong) lock->count_os_wait);
43 43
44@@ -9379,9 +9378,8 @@44@@ -9330,9 +9329,8 @@
45 45
46 if (block_lock) {46 if (block_lock) {
47 buf1len = (uint) my_snprintf(buf1, sizeof buf1,47 buf1len = (uint) my_snprintf(buf1, sizeof buf1,
@@ -55,7 +55,7 @@
55 (ulong) block_lock_oswait_count);55 (ulong) block_lock_oswait_count);
56--- a/storage/innodb_plugin/handler/innodb_patch_info.h56--- a/storage/innodb_plugin/handler/innodb_patch_info.h
57+++ b/storage/innodb_plugin/handler/innodb_patch_info.h57+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
58@@ -39,5 +39,6 @@58@@ -38,5 +38,6 @@
59 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},59 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
60 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},60 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
61 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},61 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
6262
=== modified file 'patches/innodb_stats.patch'
--- patches/innodb_stats.patch 2011-08-09 13:35:34 +0000
+++ patches/innodb_stats.patch 2011-09-25 06:36:21 +0000
@@ -347,7 +347,7 @@
347 not of the right form.347 not of the right form.
348--- a/storage/innodb_plugin/dict/dict0dict.c348--- a/storage/innodb_plugin/dict/dict0dict.c
349+++ b/storage/innodb_plugin/dict/dict0dict.c349+++ b/storage/innodb_plugin/dict/dict0dict.c
350@@ -739,7 +739,7 @@350@@ -740,7 +740,7 @@
351 print an error message and return without doing351 print an error message and return without doing
352 anything. */352 anything. */
353 dict_update_statistics(table, TRUE /* only update stats353 dict_update_statistics(table, TRUE /* only update stats
@@ -356,7 +356,7 @@
356 }356 }
357 357
358 return(table);358 return(table);
359@@ -4282,6 +4282,313 @@359@@ -4283,6 +4283,313 @@
360 }360 }
361 361
362 /*********************************************************************//**362 /*********************************************************************//**
@@ -670,7 +670,7 @@
670 Calculates new estimates for table and index statistics. The statistics670 Calculates new estimates for table and index statistics. The statistics
671 are used in query optimization. */671 are used in query optimization. */
672 UNIV_INTERN672 UNIV_INTERN
673@@ -4289,10 +4596,11 @@673@@ -4290,10 +4597,11 @@
674 dict_update_statistics(674 dict_update_statistics(
675 /*===================*/675 /*===================*/
676 dict_table_t* table, /*!< in/out: table */676 dict_table_t* table, /*!< in/out: table */
@@ -683,7 +683,7 @@
683 {683 {
684 dict_index_t* index;684 dict_index_t* index;
685 ulint sum_of_index_sizes = 0;685 ulint sum_of_index_sizes = 0;
686@@ -4309,6 +4617,27 @@686@@ -4310,6 +4618,27 @@
687 return;687 return;
688 }688 }
689 689
@@ -711,7 +711,7 @@
711 /* Find out the sizes of the indexes and how many different values711 /* Find out the sizes of the indexes and how many different values
712 for the key they approximately have */712 for the key they approximately have */
713 713
714@@ -4373,6 +4702,11 @@714@@ -4380,6 +4709,11 @@
715 index = dict_table_get_next_index(index);715 index = dict_table_get_next_index(index);
716 } while (index);716 } while (index);
717 717
@@ -723,7 +723,7 @@
723 index = dict_table_get_first_index(table);723 index = dict_table_get_first_index(table);
724 724
725 table->stat_n_rows = index->stat_n_diff_key_vals[725 table->stat_n_rows = index->stat_n_diff_key_vals[
726@@ -4390,6 +4724,78 @@726@@ -4397,6 +4731,78 @@
727 dict_table_stats_unlock(table, RW_X_LATCH);727 dict_table_stats_unlock(table, RW_X_LATCH);
728 }728 }
729 729
@@ -802,7 +802,7 @@
802 /**********************************************************************//**802 /**********************************************************************//**
803 Prints info of a foreign key constraint. */803 Prints info of a foreign key constraint. */
804 static804 static
805@@ -4467,7 +4873,7 @@805@@ -4474,7 +4880,7 @@
806 806
807 ut_ad(mutex_own(&(dict_sys->mutex)));807 ut_ad(mutex_own(&(dict_sys->mutex)));
808 808
@@ -813,7 +813,7 @@
813 813
814--- a/storage/innodb_plugin/dict/dict0load.c814--- a/storage/innodb_plugin/dict/dict0load.c
815+++ b/storage/innodb_plugin/dict/dict0load.c815+++ b/storage/innodb_plugin/dict/dict0load.c
816@@ -223,7 +223,7 @@816@@ -224,7 +224,7 @@
817 817
818 if (dict_table_get_first_index(table)) {818 if (dict_table_get_first_index(table)) {
819 dict_update_statistics(table, FALSE /* update819 dict_update_statistics(table, FALSE /* update
@@ -824,7 +824,7 @@
824 dict_table_print_low(table);824 dict_table_print_low(table);
825--- a/storage/innodb_plugin/handler/ha_innodb.cc825--- a/storage/innodb_plugin/handler/ha_innodb.cc
826+++ b/storage/innodb_plugin/handler/ha_innodb.cc826+++ b/storage/innodb_plugin/handler/ha_innodb.cc
827@@ -190,6 +190,7 @@827@@ -193,6 +193,7 @@
828 static my_bool innobase_rollback_on_timeout = FALSE;828 static my_bool innobase_rollback_on_timeout = FALSE;
829 static my_bool innobase_create_status_file = FALSE;829 static my_bool innobase_create_status_file = FALSE;
830 static my_bool innobase_stats_on_metadata = TRUE;830 static my_bool innobase_stats_on_metadata = TRUE;
@@ -832,7 +832,7 @@
832 832
833 static char* internal_innobase_data_file_path = NULL;833 static char* internal_innobase_data_file_path = NULL;
834 834
835@@ -2230,6 +2231,8 @@835@@ -2271,6 +2272,8 @@
836 836
837 srv_extra_undoslots = (ibool) innobase_extra_undoslots;837 srv_extra_undoslots = (ibool) innobase_extra_undoslots;
838 838
@@ -841,7 +841,7 @@
841 /* -------------- Log files ---------------------------*/841 /* -------------- Log files ---------------------------*/
842 842
843 /* The default dir for log files is the datadir of MySQL */843 /* The default dir for log files is the datadir of MySQL */
844@@ -5000,6 +5003,10 @@844@@ -5066,6 +5069,10 @@
845 845
846 error = row_insert_for_mysql((byte*) record, prebuilt);846 error = row_insert_for_mysql((byte*) record, prebuilt);
847 847
@@ -852,7 +852,7 @@
852 /* Handle duplicate key errors */852 /* Handle duplicate key errors */
853 if (auto_inc_used) {853 if (auto_inc_used) {
854 ulint err;854 ulint err;
855@@ -5336,6 +5343,10 @@855@@ -5410,6 +5417,10 @@
856 }856 }
857 }857 }
858 858
@@ -863,7 +863,7 @@
863 innodb_srv_conc_exit_innodb(trx);863 innodb_srv_conc_exit_innodb(trx);
864 864
865 error = convert_error_code_to_mysql(error,865 error = convert_error_code_to_mysql(error,
866@@ -5389,6 +5400,10 @@866@@ -5471,6 +5482,10 @@
867 867
868 error = row_update_for_mysql((byte*) record, prebuilt);868 error = row_update_for_mysql((byte*) record, prebuilt);
869 869
@@ -874,7 +874,7 @@
874 innodb_srv_conc_exit_innodb(trx);874 innodb_srv_conc_exit_innodb(trx);
875 875
876 error = convert_error_code_to_mysql(876 error = convert_error_code_to_mysql(
877@@ -5707,6 +5722,11 @@877@@ -5801,6 +5816,11 @@
878 case DB_SUCCESS:878 case DB_SUCCESS:
879 error = 0;879 error = 0;
880 table->status = 0;880 table->status = 0;
@@ -886,7 +886,7 @@
886 break;886 break;
887 case DB_RECORD_NOT_FOUND:887 case DB_RECORD_NOT_FOUND:
888 error = HA_ERR_KEY_NOT_FOUND;888 error = HA_ERR_KEY_NOT_FOUND;
889@@ -5916,6 +5936,11 @@889@@ -6022,6 +6042,11 @@
890 case DB_SUCCESS:890 case DB_SUCCESS:
891 error = 0;891 error = 0;
892 table->status = 0;892 table->status = 0;
@@ -898,7 +898,7 @@
898 break;898 break;
899 case DB_RECORD_NOT_FOUND:899 case DB_RECORD_NOT_FOUND:
900 error = HA_ERR_END_OF_FILE;900 error = HA_ERR_END_OF_FILE;
901@@ -7855,11 +7880,35 @@901@@ -7979,11 +8004,35 @@
902 /* In sql_show we call with this flag: update902 /* In sql_show we call with this flag: update
903 then statistics so that they are up-to-date */903 then statistics so that they are up-to-date */
904 904
@@ -935,7 +935,7 @@
935 935
936 prebuilt->trx->op_info = "returning various info to MySQL";936 prebuilt->trx->op_info = "returning various info to MySQL";
937 }937 }
938@@ -7937,7 +7986,7 @@938@@ -8061,7 +8110,7 @@
939 are asked by MySQL to avoid locking. Another reason to939 are asked by MySQL to avoid locking. Another reason to
940 avoid the call is that it uses quite a lot of CPU.940 avoid the call is that it uses quite a lot of CPU.
941 See Bug#38185. */941 See Bug#38185. */
@@ -944,7 +944,7 @@
944 /* We do not update delete_length if no944 /* We do not update delete_length if no
945 locking is requested so the "old" value can945 locking is requested so the "old" value can
946 remain. delete_length is initialized to 0 in946 remain. delete_length is initialized to 0 in
947@@ -11122,6 +11171,26 @@947@@ -11294,6 +11343,26 @@
948 "The number of index pages to sample when calculating statistics (default 8)",948 "The number of index pages to sample when calculating statistics (default 8)",
949 NULL, NULL, 8, 1, ~0ULL, 0);949 NULL, NULL, 8, 1, ~0ULL, 0);
950 950
@@ -971,7 +971,7 @@
971 static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled,971 static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled,
972 PLUGIN_VAR_OPCMDARG,972 PLUGIN_VAR_OPCMDARG,
973 "Enable InnoDB adaptive hash index (enabled by default). "973 "Enable InnoDB adaptive hash index (enabled by default). "
974@@ -11447,6 +11516,9 @@974@@ -11641,6 +11710,9 @@
975 MYSQL_SYSVAR(overwrite_relay_log_info),975 MYSQL_SYSVAR(overwrite_relay_log_info),
976 MYSQL_SYSVAR(rollback_on_timeout),976 MYSQL_SYSVAR(rollback_on_timeout),
977 MYSQL_SYSVAR(stats_on_metadata),977 MYSQL_SYSVAR(stats_on_metadata),
@@ -981,15 +981,15 @@
981 MYSQL_SYSVAR(stats_sample_pages),981 MYSQL_SYSVAR(stats_sample_pages),
982 MYSQL_SYSVAR(adaptive_hash_index),982 MYSQL_SYSVAR(adaptive_hash_index),
983 MYSQL_SYSVAR(stats_method),983 MYSQL_SYSVAR(stats_method),
984@@ -11512,6 +11584,8 @@984@@ -11709,6 +11781,8 @@
985 i_s_innodb_cmp_reset,985 i_s_innodb_cmp_reset,
986 i_s_innodb_cmpmem,986 i_s_innodb_cmpmem,
987 i_s_innodb_cmpmem_reset,987 i_s_innodb_cmpmem_reset,
988+i_s_innodb_table_stats,988+i_s_innodb_table_stats,
989+i_s_innodb_index_stats,989+i_s_innodb_index_stats,
990 i_s_innodb_admin_command,
990 i_s_innodb_patches991 i_s_innodb_patches
991 mysql_declare_plugin_end;992 mysql_declare_plugin_end;
992
993--- a/storage/innodb_plugin/handler/i_s.cc993--- a/storage/innodb_plugin/handler/i_s.cc
994+++ b/storage/innodb_plugin/handler/i_s.cc994+++ b/storage/innodb_plugin/handler/i_s.cc
995@@ -45,6 +45,7 @@995@@ -45,6 +45,7 @@
@@ -997,11 +997,11 @@
997 #include "trx0rseg.h" /* for trx_rseg_struct */997 #include "trx0rseg.h" /* for trx_rseg_struct */
998 #include "trx0sys.h" /* for trx_sys */998 #include "trx0sys.h" /* for trx_sys */
999+#include "dict0dict.h" /* for dict_sys */999+#include "dict0dict.h" /* for dict_sys */
1000 #include "buf0lru.h" /* for XTRA_LRU_[DUMP/RESTORE] */
1000 }1001 }
1001 1002
1002 static const char plugin_author[] = "Innobase Oy";1003@@ -2769,3 +2770,347 @@
1003@@ -2602,3 +2603,347 @@1004 STRUCT_FLD(system_vars, NULL),
1004 /* void* */
1005 STRUCT_FLD(__reserved1, NULL)1005 STRUCT_FLD(__reserved1, NULL)
1006 };1006 };
1007+1007+
@@ -1350,23 +1350,25 @@
1350+};1350+};
1351--- a/storage/innodb_plugin/handler/i_s.h1351--- a/storage/innodb_plugin/handler/i_s.h
1352+++ b/storage/innodb_plugin/handler/i_s.h1352+++ b/storage/innodb_plugin/handler/i_s.h
1353@@ -38,5 +38,7 @@1353@@ -38,6 +38,8 @@
1354 extern struct st_mysql_plugin i_s_innodb_cmpmem_reset;1354 extern struct st_mysql_plugin i_s_innodb_cmpmem_reset;
1355 extern struct st_mysql_plugin i_s_innodb_patches;1355 extern struct st_mysql_plugin i_s_innodb_patches;
1356 extern struct st_mysql_plugin i_s_innodb_rseg;1356 extern struct st_mysql_plugin i_s_innodb_rseg;
1357+extern struct st_mysql_plugin i_s_innodb_table_stats;1357+extern struct st_mysql_plugin i_s_innodb_table_stats;
1358+extern struct st_mysql_plugin i_s_innodb_index_stats;1358+extern struct st_mysql_plugin i_s_innodb_index_stats;
1359 extern struct st_mysql_plugin i_s_innodb_admin_command;
1359 1360
1360 #endif /* i_s_h */1361 #endif /* i_s_h */
1361--- a/storage/innodb_plugin/handler/innodb_patch_info.h1362--- a/storage/innodb_plugin/handler/innodb_patch_info.h
1362+++ b/storage/innodb_plugin/handler/innodb_patch_info.h1363+++ b/storage/innodb_plugin/handler/innodb_patch_info.h
1363@@ -35,5 +35,6 @@1364@@ -35,6 +35,7 @@
1364 {"innodb_expand_import","convert .ibd file automatically when import tablespace","the files are generated by xtrabackup export mode.","http://www.percona.com/docs/wiki/percona-xtradb"},1365 {"innodb_expand_import","convert .ibd file automatically when import tablespace","the files are generated by xtrabackup export mode.","http://www.percona.com/docs/wiki/percona-xtradb"},
1365 {"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},1366 {"innodb_dict_size_limit","Limit dictionary cache size","Variable innodb_dict_size_limit in bytes","http://www.percona.com/docs/wiki/percona-xtradb"},
1366 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},1367 {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
1367+{"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},1368+{"innodb_stats","Additional features about InnoDB statistics/optimizer","","http://www.percona.com/docs/wiki/percona-xtradb"},
1368 {NULL, NULL, NULL, NULL}1369 {"innodb_recovery_patches","Bugfixes and adjustments about recovery process","","http://www.percona.com/docs/wiki/percona-xtradb"},
1369 };1370 {"innodb_purge_thread","Enable to use purge devoted thread","","http://www.percona.com/docs/wiki/percona-xtradb"},
1371 {"innodb_admin_command_base","XtraDB specific command interface through i_s","","http://www.percona.com/docs/wiki/percona-xtradb"},
1370--- a/storage/innodb_plugin/include/dict0boot.h1372--- a/storage/innodb_plugin/include/dict0boot.h
1371+++ b/storage/innodb_plugin/include/dict0boot.h1373+++ b/storage/innodb_plugin/include/dict0boot.h
1372@@ -101,6 +101,7 @@1374@@ -101,6 +101,7 @@
@@ -1531,7 +1533,7 @@
1531 should be called after the indexes for a table have been created.1533 should be called after the indexes for a table have been created.
1532--- a/storage/innodb_plugin/include/srv0srv.h1534--- a/storage/innodb_plugin/include/srv0srv.h
1533+++ b/storage/innodb_plugin/include/srv0srv.h1535+++ b/storage/innodb_plugin/include/srv0srv.h
1534@@ -197,6 +197,9 @@1536@@ -206,6 +206,9 @@
1535 extern ibool srv_innodb_status;1537 extern ibool srv_innodb_status;
1536 1538
1537 extern unsigned long long srv_stats_sample_pages;1539 extern unsigned long long srv_stats_sample_pages;
@@ -1585,7 +1587,7 @@
1585 } else {1587 } else {
1586--- a/storage/innodb_plugin/row/row0ins.c1588--- a/storage/innodb_plugin/row/row0ins.c
1587+++ b/storage/innodb_plugin/row/row0ins.c1589+++ b/storage/innodb_plugin/row/row0ins.c
1588@@ -2020,6 +2020,8 @@1590@@ -2026,6 +2026,8 @@
1589 }1591 }
1590 1592
1591 #ifdef UNIV_DEBUG1593 #ifdef UNIV_DEBUG
@@ -1596,7 +1598,7 @@
1596 rec_t* first_rec = page_rec_get_next(1598 rec_t* first_rec = page_rec_get_next(
1597--- a/storage/innodb_plugin/row/row0merge.c1599--- a/storage/innodb_plugin/row/row0merge.c
1598+++ b/storage/innodb_plugin/row/row0merge.c1600+++ b/storage/innodb_plugin/row/row0merge.c
1599@@ -2021,6 +2021,8 @@1601@@ -2028,6 +2028,8 @@
1600 "UPDATE SYS_INDEXES SET NAME=CONCAT('"1602 "UPDATE SYS_INDEXES SET NAME=CONCAT('"
1601 TEMP_INDEX_PREFIX_STR "', NAME) WHERE ID = :indexid;\n"1603 TEMP_INDEX_PREFIX_STR "', NAME) WHERE ID = :indexid;\n"
1602 "COMMIT WORK;\n"1604 "COMMIT WORK;\n"
@@ -1784,7 +1786,7 @@
1784 dfield = dtuple_get_nth_field(entry, i);1786 dfield = dtuple_get_nth_field(entry, i);
1785--- a/storage/innodb_plugin/srv/srv0srv.c1787--- a/storage/innodb_plugin/srv/srv0srv.c
1786+++ b/storage/innodb_plugin/srv/srv0srv.c1788+++ b/storage/innodb_plugin/srv/srv0srv.c
1787@@ -369,6 +369,9 @@1789@@ -381,6 +381,9 @@
1788 /* When estimating number of different key values in an index, sample1790 /* When estimating number of different key values in an index, sample
1789 this many index pages */1791 this many index pages */
1790 UNIV_INTERN unsigned long long srv_stats_sample_pages = 8;1792 UNIV_INTERN unsigned long long srv_stats_sample_pages = 8;
17911793
=== modified file 'patches/mysql-test.diff'
--- patches/mysql-test.diff 2011-09-12 12:25:39 +0000
+++ patches/mysql-test.diff 2011-09-25 06:36:21 +0000
@@ -4093,6 +4093,7 @@
4093+INNODB_AUTOEXTEND_INCREMENT4093+INNODB_AUTOEXTEND_INCREMENT
4094+INNODB_AUTOINC_LOCK_MODE4094+INNODB_AUTOINC_LOCK_MODE
4095+INNODB_AUTO_LRU_DUMP4095+INNODB_AUTO_LRU_DUMP
4096+INNODB_BLOCKING_LRU_RESTORE
4096+INNODB_BUFFER_POOL_SHM_CHECKSUM4097+INNODB_BUFFER_POOL_SHM_CHECKSUM
4097+INNODB_BUFFER_POOL_SHM_KEY4098+INNODB_BUFFER_POOL_SHM_KEY
4098+INNODB_BUFFER_POOL_SIZE4099+INNODB_BUFFER_POOL_SIZE
@@ -4441,6 +4442,7 @@
4441+INNODB_AUTOEXTEND_INCREMENT4442+INNODB_AUTOEXTEND_INCREMENT
4442+INNODB_AUTOINC_LOCK_MODE4443+INNODB_AUTOINC_LOCK_MODE
4443+INNODB_AUTO_LRU_DUMP4444+INNODB_AUTO_LRU_DUMP
4445+INNODB_BLOCKING_LRU_RESTORE
4444+INNODB_BUFFER_POOL_SHM_CHECKSUM4446+INNODB_BUFFER_POOL_SHM_CHECKSUM
4445+INNODB_BUFFER_POOL_SHM_KEY4447+INNODB_BUFFER_POOL_SHM_KEY
4446+INNODB_BUFFER_POOL_SIZE4448+INNODB_BUFFER_POOL_SIZE
44474449
=== modified file 'patches/series'
--- patches/series 2011-09-06 08:23:51 +0000
+++ patches/series 2011-09-25 06:36:21 +0000
@@ -20,7 +20,6 @@
20innodb_dict_size_limit.patch20innodb_dict_size_limit.patch
21innodb_split_buf_pool_mutex.patch21innodb_split_buf_pool_mutex.patch
22innodb_expand_import.patch22innodb_expand_import.patch
23innodb_stats.patch
24innodb_recovery_patches.patch23innodb_recovery_patches.patch
25innodb_purge_thread.patch24innodb_purge_thread.patch
26innodb_admin_command_base.patch25innodb_admin_command_base.patch
@@ -29,6 +28,7 @@
29innodb_lru_dump_restore.patch28innodb_lru_dump_restore.patch
30innodb_separate_doublewrite.patch29innodb_separate_doublewrite.patch
31innodb_pass_corrupt_table.patch30innodb_pass_corrupt_table.patch
31innodb_stats.patch
32innodb_fast_checksum.patch32innodb_fast_checksum.patch
33innodb_files_extend.patch33innodb_files_extend.patch
34innodb_show_sys_tables.patch34innodb_show_sys_tables.patch

Subscribers

People subscribed via source and target branches