mirror of
https://github.com/MariaDB/server.git
synced 2025-07-12 14:28:13 +02:00

including the test case:
520aedfe
INNODB: "DATA DIRECTORY" OPTION OF CREATE TABLE FAILS WITH PWRITE() OS
ERROR 22
Fix for version mysql-5.6
PROBLEM
========
For version mysql-5.6.27 onwards InnoDB fails to create a table
with explicit 'data directory' option when Innodb_flush_method
is set to O_DIRECT.While creating link file we get a a pwrite
error 22 due to the alignment restrictions imposed by O_DIRECT
flag which is being set for the link file created.
FIX
===
Fixed the above issue by making use of file IO functions while
creating the link file that wouldn't let the O_DIRECT flag
restrictions arise.
Reviewed-by: Kevin Lewis <kevin.lewis@oracle.com>
Reviewed-by: Shaohua Wang <shaohua.wang@oracle.com>
RB: 11387
10 lines
328 B
Text
10 lines
328 B
Text
SHOW VARIABLES LIKE 'innodb_flush_method';
|
|
Variable_name Value
|
|
innodb_flush_method O_DIRECT
|
|
CREATE TABLE t1 (x INT) ENGINE=INNODB, DATA DIRECTORY='MYSQL_TMP_DIR';
|
|
# Contents of tmp/test directory containing .ibd file
|
|
t1.ibd
|
|
# Contents of the 'test' database directory containing .isl and .frm files
|
|
t1.frm
|
|
t1.isl
|
|
DROP TABLE t1;
|