-
Notifications
You must be signed in to change notification settings - Fork 484
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PS-5541: Do not try to decrypt blocks in changed page tracking. (5.7) #3150
Conversation
mysql-test/t/percona_bug_ps5541.test
Outdated
@@ -0,0 +1,47 @@ | |||
-- source include/big_test.inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I understand correctly, the test does not require redo log encryption itself to be enabled, correct? In which case this scenario should be test by existing innodb.percona_changed* testcases, please check, whether the new testcase is required at all
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's right, encryption is not needed - but a huge amount of data is. If I insert fewer records than what we have in this test case, the issue won't show up without this commit. And with this amount, it runs for 15-20 minutes on a debug build.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, then the existing bitmap testcases have predetermined name prefix (percona_changed_page_bmp in general, percona_changes_pages for I_S queries like this one), so please rename to percona_changed_pages_big and add a header comment --echo # / --echo # PS-5541: blah blah / --echo #
mysql-test/t/percona_bug_ps5541.test
Outdated
@@ -0,0 +1,47 @@ | |||
-- source include/big_test.inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, then the existing bitmap testcases have predetermined name prefix (percona_changed_page_bmp in general, percona_changes_pages for I_S queries like this one), so please rename to percona_changed_pages_big and add a header comment --echo # / --echo # PS-5541: blah blah / --echo #
mysql-test/t/percona_bug_ps5541.test
Outdated
show status like 'Innodb_page%'; | ||
--enable_result_log | ||
|
||
USE test; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Redundant
mysql-test/t/percona_bug_ps5541.test
Outdated
-- source include/big_test.inc | ||
|
||
--disable_result_log | ||
show status like 'Innodb_page%'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
mysql-test/t/percona_bug_ps5541.test
Outdated
@@ -0,0 +1,47 @@ | |||
-- source include/big_test.inc | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
--source include/have_innodb.inc
mysql-test/t/percona_bug_ps5541.test
Outdated
`g` int(11) NOT NULL, | ||
PRIMARY KEY (`i`), | ||
KEY key_g (`g`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=latin1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | |
) ENGINE=InnoDB DEFAULT CHARSET=latin1; |
mysql-test/t/percona_bug_ps5541.test
Outdated
KEY key_g (`g`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | ||
|
||
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), (FLOOR( 1 + RAND( ) *60 ))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everywhere
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), (FLOOR( 1 + RAND( ) *60 ))); | |
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), (FLOOR(1 + RAND() * 60))); |
mysql-test/t/percona_bug_ps5541.test
Outdated
INSERT INTO joinit SELECT NULL, uuid(), time(now()), (FLOOR( 1 + RAND( ) *60 )) FROM joinit; | ||
|
||
--disable_result_log | ||
show status like 'Innodb_page%'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
@@ -0,0 +1,2 @@ | |||
--innodb_track_changed_pages=1 --innodb_max_bitmap_file_size=1G --innodb_buffer_pool_size=1G |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is 1G buffer pool size necessary?
KEY key_g (`g`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | ||
|
||
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), FLOOR(1 + RAND() *60 )); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment not addressed
INSERT INTO joinit SELECT NULL, uuid(), time(now()), FLOOR(1 + RAND() *60) FROM joinit; | ||
|
||
--disable_result_log | ||
select count(*) as count_innodb_changed_pages from information_schema.INNODB_CHANGED_PAGES; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make SQL case consistent
KEY key_g (`g`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=latin1; | ||
|
||
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), FLOOR(1 + RAND() * 60)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Strictly speaking
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), FLOOR(1 + RAND() * 60)); | |
INSERT INTO joinit VALUES (NULL, uuid(), time(now()), FLOOR(1 + RAND() * 60)); |
still not done but of course not enough to cause a PR respin by itself
Issue: changed page tracking uses the LOG flag during read operations to follow the correct code path. Redo log encryption backported from 8.0 tries to decrypt pages with a certain bit set, and fails. While the end result is the same, the error log gets flooded with decryption errors. Solution: the NO_ENCRYPTION flag, previously ignored by log encryption now disables decryption during log reads too.
Issue: changed page tracking uses the LOG flag during read
operations to follow the correct code path. Redo log encryption
backported from 8.0 tries to decrypt pages with a certain bit set,
and fails. While the end result is the same, the error log gets
flooded with decryption errors.
Solution: the NO_ENCRYPTION flag, previously ignored by log
encryption now disables decryption during log reads too.