Merge lp:~percona-dev/percona-server/release-5.1.47-11-fix-bug589639 into lp:percona-server/release-5.1.47-11

Proposed by Yasufumi Kinoshita on 2010-06-07
Status: Merged
Approved by: Vadim Tkachenko on 2010-06-07
Approved revision: 32
Merged at revision: 35
Proposed branch: lp:~percona-dev/percona-server/release-5.1.47-11-fix-bug589639
Merge into: lp:percona-server/release-5.1.47-11
Diff against target: 74 lines (+52/-1)
2 files modified
innodb_extend_slow.patch (+1/-1)
innodb_recovery_patches.patch (+51/-0)
To merge this branch: bzr merge lp:~percona-dev/percona-server/release-5.1.47-11-fix-bug589639
Reviewer Review Type Date Requested Status
Vadim Tkachenko 2010-06-07 Approve on 2010-06-07
Review via email: mp+26915@code.launchpad.net
To post a comment you must log in.
Vadim Tkachenko (vadim-tk) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'innodb_extend_slow.patch'
--- innodb_extend_slow.patch 2010-05-26 10:15:29 +0000
+++ innodb_extend_slow.patch 2010-06-07 09:06:23 +0000
@@ -312,7 +312,7 @@
312 312
313 if (UNIV_UNLIKELY(err == DB_TABLESPACE_DELETED)) {313 if (UNIV_UNLIKELY(err == DB_TABLESPACE_DELETED)) {
314 tablespace_deleted:314 tablespace_deleted:
315@@ -684,12 +687,12 @@315@@ -728,12 +731,12 @@
316 if ((i + 1 == n_stored) && sync) {316 if ((i + 1 == n_stored) && sync) {
317 buf_read_page_low(&err, TRUE, BUF_READ_ANY_PAGE, space,317 buf_read_page_low(&err, TRUE, BUF_READ_ANY_PAGE, space,
318 zip_size, TRUE, tablespace_version,318 zip_size, TRUE, tablespace_version,
319319
=== modified file 'innodb_recovery_patches.patch'
--- innodb_recovery_patches.patch 2010-05-26 10:15:29 +0000
+++ innodb_recovery_patches.patch 2010-06-07 09:06:23 +0000
@@ -48,6 +48,57 @@
48 48
49 return(0);49 return(0);
50 }50 }
51@@ -606,6 +646,50 @@
52 /* It is a single table tablespace and the .ibd file is
53 missing: do nothing */
54
55+ /* the log records should be treated here same reason
56+ for http://bugs.mysql.com/bug.php?id=43948 */
57+
58+ if (recv_recovery_is_on()) {
59+ recv_addr_t* recv_addr;
60+
61+ mutex_enter(&(recv_sys->mutex));
62+
63+ if (recv_sys->apply_log_recs == FALSE) {
64+ mutex_exit(&(recv_sys->mutex));
65+ goto not_to_recover;
66+ }
67+
68+ for (i = 0; i < n_stored; i++) {
69+ /* recv_get_fil_addr_struct() */
70+ recv_addr = HASH_GET_FIRST(recv_sys->addr_hash,
71+ hash_calc_hash(ut_fold_ulint_pair(space, page_nos[i]),
72+ recv_sys->addr_hash));
73+ while (recv_addr) {
74+ if ((recv_addr->space == space)
75+ && (recv_addr->page_no == page_nos[i])) {
76+ break;
77+ }
78+ recv_addr = HASH_GET_NEXT(addr_hash, recv_addr);
79+ }
80+
81+ if ((recv_addr == NULL)
82+ || (recv_addr->state == RECV_BEING_PROCESSED)
83+ || (recv_addr->state == RECV_PROCESSED)) {
84+ continue;
85+ }
86+
87+ recv_addr->state = RECV_PROCESSED;
88+
89+ ut_a(recv_sys->n_addrs);
90+ recv_sys->n_addrs--;
91+ }
92+
93+ mutex_exit(&(recv_sys->mutex));
94+
95+ fprintf(stderr, " (cannot find space: %lu)", space);
96+ }
97+not_to_recover:
98+
99 return;
100 }
101
51diff -ruN a/storage/innodb_plugin/handler/ha_innodb.cc b/storage/innodb_plugin/handler/ha_innodb.cc102diff -ruN a/storage/innodb_plugin/handler/ha_innodb.cc b/storage/innodb_plugin/handler/ha_innodb.cc
52--- a/storage/innodb_plugin/handler/ha_innodb.cc 2010-04-30 10:49:58.000000000 +0900103--- a/storage/innodb_plugin/handler/ha_innodb.cc 2010-04-30 10:49:58.000000000 +0900
53+++ b/storage/innodb_plugin/handler/ha_innodb.cc 2010-04-30 13:53:47.000000000 +0900104+++ b/storage/innodb_plugin/handler/ha_innodb.cc 2010-04-30 13:53:47.000000000 +0900

Subscribers

No one subscribed via source and target branches