mirror of
https://github.com/MariaDB/server.git
synced 2025-07-20 10:24:14 +03:00
Let us make innodb_buffer_pool_filename a read-only variable so that a malicious user cannot cause an important file to be deleted on InnoDB shutdown. An attempt to delete a directory will fail because it is not a regular file, but what if the variable pointed to (say) ibdata1, ib_logfile0 or some *.ibd file? It does not seem to make much sense for this parameter to be configurable in the first place, but we will not change that in order to avoid breaking compatibility.
20 lines
758 B
Plaintext
20 lines
758 B
Plaintext
CREATE TABLE tab5 (col1 int auto_increment primary key,
|
|
col2 VARCHAR(25), col3 varchar(25)) ENGINE=InnoDB;
|
|
CREATE INDEX idx1 ON tab5(col2(10));
|
|
CREATE INDEX idx2 ON tab5(col3(10));
|
|
SET GLOBAL innodb_buffer_pool_dump_pct=100;
|
|
SELECT variable_value INTO @IBPDS
|
|
FROM information_schema.global_status
|
|
WHERE variable_name = 'INNODB_BUFFER_POOL_DUMP_STATUS';
|
|
SET GLOBAL innodb_buffer_pool_dump_now=ON;
|
|
SET GLOBAL innodb_buffer_pool_dump_pct=1;
|
|
SELECT @@global.innodb_buffer_pool_dump_pct;
|
|
@@global.innodb_buffer_pool_dump_pct
|
|
1
|
|
SELECT variable_value INTO @IBPDS
|
|
FROM information_schema.global_status
|
|
WHERE variable_name = 'INNODB_BUFFER_POOL_DUMP_STATUS';
|
|
SET GLOBAL innodb_buffer_pool_dump_now=ON;
|
|
SET GLOBAL innodb_buffer_pool_dump_pct=DEFAULT;
|
|
DROP TABLE tab5;
|